Hi, I am using $_SERVER["DOCUMENT_ROOT"]; to include files but it is it failing my files in a all the page where I used it.
This is the error it's displaying
Warning: include(/home/boardgiv/domains/feedingplus.com.ng/private_html/dbase/dbaseconnection.php): failed to open stream: No such file or directory in /home/boardgiv/domains/feedingplus.com.ng/public_html/mlmpro/login.php on line 13.
This is the example of how I used it:
<?php // sanitize $_GET variables $_GET = filter_input_array(INPUT_GET, FILTER_SANITIZE_STRING); // sanitize $_POST variables $_POST = filter_input_array(INPUT_POST, FILTER_SANITIZE_STRING); session_start(); include $_SERVER['DOCUMENT_ROOT'] . "/dbase/dbaseconnection.php"; include $_SERVER['DOCUMENT_ROOT'] . "/functions/mlmfunctions.php"; //include $_SERVER['DOCUMENT_ROOT'] . "/functions/functions.php"; function testinput($data) { $data = trim($data); $data = stripslashes($data); $data = htmlspecialchars($data); return $data; }
?>
Can someone help? Thanks.
This is the error it's displaying
Warning: include(/home/boardgiv/domains/feedingplus.com.ng/private_html/dbase/dbaseconnection.php): failed to open stream: No such file or directory in /home/boardgiv/domains/feedingplus.com.ng/public_html/mlmpro/login.php on line 13.
This is the example of how I used it:
<?php // sanitize $_GET variables $_GET = filter_input_array(INPUT_GET, FILTER_SANITIZE_STRING); // sanitize $_POST variables $_POST = filter_input_array(INPUT_POST, FILTER_SANITIZE_STRING); session_start(); include $_SERVER['DOCUMENT_ROOT'] . "/dbase/dbaseconnection.php"; include $_SERVER['DOCUMENT_ROOT'] . "/functions/mlmfunctions.php"; //include $_SERVER['DOCUMENT_ROOT'] . "/functions/functions.php"; function testinput($data) { $data = trim($data); $data = stripslashes($data); $data = htmlspecialchars($data); return $data; }
?>
Can someone help? Thanks.