Reputation: 559
Im learning how to write a Sign Up page using Php and Mysql (XAMPP).
Now, I downloaded the source code in this website:
http://net.tutsplus.com/tutorials/php/create-a-signup-form-with-email-confirmation/
and tried to make sure it works. But when openning:
http://localhost/source/index.php
I got the following warnings:
Warning: include_once(C:\xampp\htdocs\source\inc\php\config.php) [function.include-once]: failed to open stream: Permission denied in C:\xampp\htdocs\source\index.php on line 3
Warning: include_once() [function.include]: Failed opening 'inc/php/config.php' for inclusion (include_path='.;C:\xampp\php\PEAR') in C:\xampp\htdocs\source\index.php on line 3
Warning: include_once(C:\xampp\htdocs\source\inc\php\functions.php) [function.include-once]: failed to open stream: Permission denied in C:\xampp\htdocs\source\index.php on line 4
Warning: include_once() [function.include]: Failed opening 'inc/php/functions.php' for inclusion (include_path='.;C:\xampp\php\PEAR') in C:\xampp\htdocs\source\index.php on line 4
Here are the lines where I got the warnings:
<?php
include_once 'inc/php/config.php';
include_once 'inc/php/functions.php';
.
.
Any Help?
Upvotes: 2
Views: 37701
Reputation: 468
Try to set the folder permission to '754'. Only the folder permission.
Upvotes: 0
Reputation: 8711
Replace this:
include_once 'inc/php/config.php';
include_once 'inc/php/functions.php';
with
include_once dirname(__FILE__) . '/inc/php/config.php';
include_once dirname(__FILE__) . '/inc/php/functions.php';
Upvotes: 6
Reputation: 15616
Much of the time using full paths like that is disabled in PHP for security reasons, try changing the paths in your include statements to being relative.
Upvotes: 0