Jump to content
php.lv forumi

Problēmas ar $_SERVER['HTTP_HOST']


daGrevis

Recommended Posts

Sveiki!

Sasāros ar problēmu, ka saņemu šādu kļūdu atverot lapu.

 

Warning: include() [function.include]: URL file-access is disabled in the server configuration in D:\xampp\htdocs\prototype\includes\core.php on line 48

Warning: include(http://127.0.0.1/prototype/styles/proLite/begin_frame.php) [function.include]: failed to open stream: no suitable wrapper could be found in D:\xampp\htdocs\prototype\includes\core.php on line 48

Warning: include() [function.include]: Failed opening 'http://127.0.0.1/prototype/styles/proLite/begin_frame.php' for inclusion (include_path='.;D:\xampp\php\pear\') in D:\xampp\htdocs\prototype\includes\core.php on line 48

Welcome on my site...

Warning: include() [function.include]: URL file-access is disabled in the server configuration in D:\xampp\htdocs\prototype\includes\core.php on line 55

Warning: include(http://127.0.0.1/prototype/styles/proLite/end_frame.php) [function.include]: failed to open stream: no suitable wrapper could be found in D:\xampp\htdocs\prototype\includes\core.php on line 55

Warning: include() [function.include]: Failed opening 'http://127.0.0.1/prototype/styles/proLite/end_frame.php' for inclusion (include_path='.;D:\xampp\php\pear\') in D:\xampp\htdocs\prototype\includes\core.php on line 55

Warning: include() [function.include]: URL file-access is disabled in the server configuration in D:\xampp\htdocs\prototype\includes\core.php on line 48

Warning: include(http://127.0.0.1/prototype/styles/proLite/begin_frame.php) [function.include]: failed to open stream: no suitable wrapper could be found in D:\xampp\htdocs\prototype\includes\core.php on line 48

Warning: include() [function.include]: Failed opening 'http://127.0.0.1/prototype/styles/proLite/begin_frame.php' for inclusion (include_path='.;D:\xampp\php\pear\') in D:\xampp\htdocs\prototype\includes\core.php on line 48
News system works? (on 2 May)

Hmm, looks like yes! :)
Warning: include() [function.include]: URL file-access is disabled in the server configuration in D:\xampp\htdocs\prototype\includes\core.php on line 55

Warning: include(http://127.0.0.1/prototype/styles/proLite/end_frame.php) [function.include]: failed to open stream: no suitable wrapper could be found in D:\xampp\htdocs\prototype\includes\core.php on line 55

Warning: include() [function.include]: Failed opening 'http://127.0.0.1/prototype/styles/proLite/end_frame.php' for inclusion (include_path='.;D:\xampp\php\pear\') in D:\xampp\htdocs\prototype\includes\core.php on line 55

Warning: include() [function.include]: URL file-access is disabled in the server configuration in D:\xampp\htdocs\prototype\includes\core.php on line 41

Warning: include(http://127.0.0.1/prototype/styles/proLite/overall_footer.php) [function.include]: failed to open stream: no suitable wrapper could be found in D:\xampp\htdocs\prototype\includes\core.php on line 41

Warning: include() [function.include]: Failed opening 'http://127.0.0.1/prototype/styles/proLite/overall_footer.php' for inclusion (include_path='.;D:\xampp\php\pear\') in D:\xampp\htdocs\prototype\includes\core.php on line 41

 

Ok, kļūdām. Tās sāka parādīties, izveidojot multi-language sistēmu, kā arī nomainot...

 

$rootPath = $_SERVER['DOCUMENT_ROOT'] . "/" . $subDirectory . "/";

 

...uz...

 

$rootPath = "http://" . $_SERVER['HTTP_HOST'] . "/" . $subDirectory . "/";

 

Šeit ir mans nepabeigtais freimvorks.

 

http://rapidshare.com/files/233279041/prototype.zip.html

 

Šeit ir core.php...

 

http://codepad.org/hXyHuT75

 

Paldies jau iepriekšs.

Link to comment
Share on other sites

Es nezinu vai izdarīju pareizi, bet...

 

$rootPath = "./";

 

Tad jau sanāk ka nav jēgas taisīt atsevišķu mainīgo, jo tur jau nav kam mainīties, ja? Pareizi saprotu?

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...