You are here: Re: [PHP] mod_rewrite and include paths « PHP « IT news, forums, messages
Re: [PHP] mod_rewrite and include paths

Posted by Marcus Bointon on 11/14/05 01:06

On 13 Nov 2005, at 22:15, Marco Kaiser wrote:

> try to use realpath, dirname and other related funktion to resolv
> the real path.
>
> dirname(__FILE__) ?

Good point (you can tell I've been up too long). I've just had a play
with that - I appended the current path to my include_path, but it
seems it's not inherited, so sub-includes are not found. I also tried
chdir(dirname(__FILE__)) which had the same results and interferes
with the operation of require_once (the same file found by a
different path doesn't get counted as the same file). Incidentally
doing just 'echo getcwd();' seems to fail completely when called via
a rewrite. After all that, smarty still can't find its templates_c
for some reason. I'm sure there must be something simple and elegant
I'm missing. Probably a good night's sleep.

Marcus
--
Marcus Bointon
Synchromedia Limited: Putting you in the picture
marcus@synchromedia.co.uk | http://www.synchromedia.co.uk

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация