Click here to Skip to main content
15,888,351 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I have a working .html file. The problem is when I change its extension to .php the browser shows no content and a blank page. I am running apache on localhost.

What I have tried:

I have changed file extension from .html to .php and added a small php code <?php echo "hello"; ?> to the file
I have a working apache server at localhost which runs other php files perfectly.
Posted
Comments
Richard MacCutchan 30-Mar-18 7:16am    
Please edit your question, we need to see the content of your file.
Christiaan van Bergen 1-Apr-18 6:11am    
Does any php file work on your apache server? If you haven't tried it yet, create a new file and enter some fool proof code into it (https://www.w3schools.com/php/showphp.asp?filename=demo_syntax) and see if that works. If not, check your apache setup.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900