You are here: Re: Source Displayed With include_once() « PHP Programming Language « IT news, forums, messages
Re: Source Displayed With include_once()

Posted by Jerry Stuckle on 08/07/06 01:49

Steve wrote:
>
>
> Jerry Stuckle wrote:
>
>> Sounds like you might have a syntax error in your functions.php file.
>> First of all, enable all errors in your php.ini file:
>>
>> error_reporting = E_ALL
>>
>> Then either check your Apache error log file (if you're using the
>> default logging), or set
>>
>> display_errors = On
>>
>> in your php.ini file (not recommended for production systems) to see
>> what error you're getting.
>
>
> That did the trick. The problem was that whenever I started a PHP block
> with "<?", it didn't work, but when I used "<?php", it works fine (I had
> to do that in every place in functions.php).
>
> I did a little more research, and discovered that the reason this was so
> was that I had short_open_tags=Off in php.ini. I changed it to on, and
> tested, and it worked the way I had it (with short tags).
>
> Thanks for everybody's help. You learn something new every day.
>
> Steve

Steve,

It's better to run with short_open_tags off. Having it on will conflict
with other things.

One example is XML tags, which start with <?. With short_open_tags on,
the system will attempt to parse the XML as PHP, with understandably all
kinds of errors. It's one reason why the PHP developers recommend
turning off short tags - and why no one in this thread recommended
turning it on.


--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
jstucklex@attglobal.net
==================

 

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

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