Jump to content
Larry Ullman's Book Forums

Config.Inc.Php


Recommended Posts

define ('BASE_URI', '/c:/xampp/htdocs/');----------I am Window 7 user and is this the right path ?

 

define ('BASE_URL', 'www.example.com/');

 

define ('PDFS_DIR', BASE_URI . 'pdfs/'); // Added in Chapter 5.

 

define ('MYSQL', BASE_URI . 'mysql.inc.php');

 

Hi (Larry)all, thanks for helping me

Link to comment
Share on other sites

If you want your root to be your localhost then

 

define ('BASE_URI', 'C:\xampp\htdocs\\');

 

Your BASE_URL needs to be the actual location you plan this site to be visible and work. If that's locally then it's this

 

most likely

define ('BASE_URL', 'http://localhost/')

Link to comment
Share on other sites

Only for docs, I'll ammend the code, good spot Josee :lol:

 

define ('BASE_URI', '/c:/xampp/htdocs/');

 

define ('BASE_URL', 'http://localhost/');

 

define ('PDFS_DIR', BASE_URI . 'pdfs/'); // Added in Chapter 5.

 

define ('MYSQL', BASE_URI . 'mysql.inc.php');----------- I thought this should be located outside the htdocs ?

 

Thanks for reply

Link to comment
Share on other sites

Well its up to you. Your initial code suggested your BASE_URI was the root. Please note that you are not referencing your base_uri correctly, note the slashes are the wrong way and you need to end with a double \\ like I have. If you want the root to be the xamp folder then

define ('BASE_URI', 'C:\xampp\\');

Link to comment
Share on other sites

 Share

×
×
  • Create New...