Page 1 of 1

file not picking values of variables placed in another file

Posted: Wed Apr 21, 2004 1:38 am
by fadi
hi!
i have 2 portions of site as usual others do have.Admin and User.
in the user section. all webpages of php are picking values defined in language files. But in the admin section providing proper path n everything..Values are just not visible even there is no error.
like
i have defined a variable in following way in file abc.php
-------abc.php------
<?php
$opt="Welcome Guest";
?>
-------End of abc.php------
in another file..
----------admn.php-------
<?php
require_once("../abc.php");
echo "{$opt}";
?>
--end of admn.php----
file admn is placed in administration folder and abc.php is placed in the root folder.
how can i do that ? i need immediate help plz....i've a deadline to meet :(...as always :d

Posted: Wed Apr 21, 2004 1:54 am
by feyd
did you try this?
require_once("/abc.php");

Posted: Wed Apr 21, 2004 2:40 am
by fadi
yes. i tried that one also .but it dint work. there was an error that u dont have permission . i did set permissions to each folder n file to 777 ...but still dint work.... it gives no error at ("../abc.php"); but also doesnt get values...