php no html yes
Posted by: mckenna.tim (---.hsd1.ma.comcast.net)
Date: December 04, 2011 04:53PM

phpinfo shows php info yet php doesn't work. win7/64 maybe a path issue?

<?
echo "php is working";

?>
yet

<html>
<body>
<p>html works</p>
</body>
</html>

works

Options: ReplyQuote
Re: php no html yes
Posted by: habeebullah (---.bolton.ac.uk)
Date: December 06, 2011 02:45PM

There should be no path issues if you follow the path below:

For PHP file: [localhost]
For HTML file: [localhost]

The above paths are asuming that your file name is 'Index'. If you just type: "[localhost]; then it may pick-up the HTML file as default, but it may notpick-up the php file as default. In which case, a simple fix would be to place a redirection script on the HTML file to redirect to the PHP file.

Now another issue could be that your PHP 4/5 is not working correctly, a simple way to test this would be to install a simple free PHP script like 'OSCommerce' and testing the PHP through a script like that which have many help files/forums.

Or if you are an advanced user, you could go into the core-files of Wamp-Server and fix the PHP if it is corrupt, a even simpler way to fix PHP would be to reinstall WampServer.

I hope this helps, remember, I am no expert...

:-)

Options: ReplyQuote
Re: php no html yes
Posted by: habeebullah (---.bolton.ac.uk)
Date: December 06, 2011 02:46PM

For PHP file: http : // localhost / index . php
For HTML file: http : // localhost / index . html

Options: ReplyQuote
Re: php no html yes
Posted by: habeebullah (---.bolton.ac.uk)
Date: December 06, 2011 03:06PM

Or you could try:

<? php

rather than just <?



:-)

Options: ReplyQuote
Re: php no html yes
Posted by: habeebullah (---.bolton.ac.uk)
Date: December 06, 2011 03:07PM

Also, please do not post the same issue multiple times...

Thanks

Options: ReplyQuote


Sorry, only registered users may post in this forum.