php not working correctly

Problems with the Windows version of XAMPP, questions, comments, and anything related.

php not working correctly

Postby donaldfoo » 13. October 2009 17:28

Hi all,
Something very strange in my new installed xampp.
I found that all my php nor working anymore without "<?php"
I used to use "<?" instead of "<?php" my html code.
it will only show blank without excute the code.

i.e.
Working one
Code: Select all
<?php
    phpinfo();
?>


Not working
Code: Select all
<?
    phpinfo();
?>


Anyone has any idea?

Regards,
Donald
donaldfoo
 
Posts: 2
Joined: 13. October 2009 17:22

Re: php not working correctly

Postby Wiedmann » 13. October 2009 17:31

Anyone has any idea?

The PHP manual knows everything about basic PHP behavior ;-)
(and which PHP ini setting is involved)

I found that all my php nor working anymore without "<?php"
I used to use "<?" instead of "<?php" my html code.

http://de.php.net/manual/en/language.basic-syntax.phpmode.php
Wiedmann
AF Moderator
 
Posts: 17106
Joined: 01. February 2004 12:38
Location: Stuttgart / Germany

Re: php not working correctly

Postby denebgarza » 13. October 2009 17:33

PHP's newest version 5.3.0 (which comes with XAMPP's newest release 1.7.2) removed the <? tag. It's now always <?php, I believe it was due to some complications when working with XML.
denebgarza
 
Posts: 4
Joined: 13. October 2009 17:20

Re: php not working correctly

Postby donaldfoo » 13. October 2009 17:50

Dear Wiedmann and denebgarza,
Thanks for your quick respone and the useful information.
It works now.

Regards,
Donald
donaldfoo
 
Posts: 2
Joined: 13. October 2009 17:22


Return to XAMPP for Windows

Who is online

Users browsing this forum: No registered users and 55 guests