+ 1
How do you view an php file?
I thought php was apart of html, but it won't open the file. All it does is open my file in my code editor. I am so confused. What do I do?
3 Answers
+ 2
C91AOP
You can open it in notepad++ editor also.
+ 2
You need to install a server which can execute you php file
For me the easiest is an apche server
You can install xamp/wamp server in your pc and store all you code in htdocs folder
Inside htdocs folder create a new folder with the name of your project and move all your code there
Now you can go to any browser and write an url localhost/<your foldername>/ this will execute your php file
Where can you find the htdocs folder?
When you have completed the installation then type for htdocs after pressing the windows key. Open the first result names htdocs.
Happy coding
~ Krish
+ 1
Via an editor. A browser will not show back end code.