PHP not running correctly or not at all.
Posted by: Fergus (---.dsl.bell.ca)
Date: December 11, 2013 05:34PM

Configurtion: Windows XP + Firefox browser.
WAMP 2.4 + What to do after installing fixes.
Apache 2.4.4, MySql 5.6.12, PHP 5.4.6
Notepad ++
WAMP ICON is "Green"
Everything was working fine until what appeared to be a crash happened.
Uninstalled and reinstalled WAMP resulted in no change or improvement.
Also reinstalled Windows C++ SP1 & got a "file repaired" message.

When running a simple script opening the .php file in Firefox or IE get a blank screen or parts of the .php text.

Tried other simple php files such as echo Hello, even downloaded files from reliable sources - blank

I have tried everything I know of to get back to the original state. But nothing works.

Any ideas on what to try next.



Edited 1 time(s). Last edit at 12/11/2013 05:46PM by Fergus.

Options: ReplyQuote
Re: PHP not running correctly or not at all.
Posted by: stevenmartin99 (Moderator)
Date: December 11, 2013 05:50PM

How are u making the file?

How are u opening the file in browser?

Steven Martin
stevenmartin99@gmail.com
stevenmartin99@hotmail.com
PampServer.com - [pampserver.com]

Options: ReplyQuote
Re: PHP not running correctly or not at all.
Posted by: Fergus (---.dsl.bell.ca)
Date: December 11, 2013 09:01PM

From Windows explorer I click on the file and select "Open With" then "Firefox"

Options: ReplyQuote
Re: PHP not running correctly or not at all.
Posted by: stevenmartin99 (Moderator)
Date: December 11, 2013 09:25PM

Well that's the problem.

Php is a sever side parsed language.

It has to run through the server unlike HTML.


You will need to access it using http ://Localhost/file.php

This would open a file.php in c:/wamp/www


Localhost/folder/file2.php. Will open a file in c:/wamp/www/folder/file2.php

Steven Martin
stevenmartin99@gmail.com
stevenmartin99@hotmail.com
PampServer.com - [pampserver.com]



Edited 1 time(s). Last edit at 12/12/2013 07:33AM by stevenmartin99.

Options: ReplyQuote
Re: PHP not running correctly or not at all.
Posted by: Fergus (---.dsl.bell.ca)
Date: December 11, 2013 10:55PM

Thanks, going through the WAMP server works great. With your explanation it all makes sense.

Now I can finish my Sitepoint course.

smiling smiley

Options: ReplyQuote


Sorry, only registered users may post in this forum.