dhvani Posted September 23, 2009 Share Posted September 23, 2009 Hi , I have one problem not getting solution for this. In my site i have one file called example.php .... in this file i am including configure.php file. In which i define one constant 'a'. Than I include one file called db_connect.inc.php and using the variable a in that. this works very fine on my webserver but in my local server i am not getting variable a's value in db_connect.inc.php..... I am not getting that where is the problem?? Please help me out in this..... Its really urgent. thanks Quote Link to comment Share on other sites More sharing options...
trq Posted September 23, 2009 Share Posted September 23, 2009 Its likely a path problem, use require instaed of include as it will through an error if the file can't be located. This will help debug the issue. Oh, and make sure you have display errors on. Quote Link to comment Share on other sites More sharing options...
dhvani Posted September 23, 2009 Author Share Posted September 23, 2009 Hi I am using require_once only the error I got is main(DIR_FS_INCxtc_db_error.inc.php) [function.main]: failed to open stream: No such file or directory in /var/www/html/xtc/inc/xtc_db_query.inc.php on line 20 here xtc_db_query.inc.php is included to my main file using require_once and i used the constant DIR_FS_INC in require_once to get the file. But in this file I am not getting this constant's value. !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! So if any one can help please. Thanks Quote Link to comment Share on other sites More sharing options...
trq Posted September 23, 2009 Share Posted September 23, 2009 So if any one can help please. Your going to need to post the relevant code and a description of your directory structure. Quote Link to comment Share on other sites More sharing options...
dhvani Posted September 24, 2009 Author Share Posted September 24, 2009 hi, I don't think that my file is not getting called. Because I get Whatever I echo there. What I am doing is... A is my constant. //code echo A; // Here I get the value of A require_once('include/header.inc.php'); Now in include/header.inc.php i do this. echo A; // Here i Get 'A' not the value of A I cant understand that y i am getting this error..... Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.