+ 1

problemes page php

I have a problem when I work with php page The codes appear as they are in the browser Possible solution ex this link https://www4.0zz0.com/2019/08/11/04/997698169.png

11th Aug 2019, 1:41 AM
bandooadz
1 Answer
0
You access the PHP document as you would when you access an HTML document, but that's not how you should do it. I see you have installed AppServ, IIRC that application bundles web server, PHP and MySQL (or MariaDb probably). By installing that application you have a local server where you can practice PHP & SQL, just as if you have hosted your files on a hosting service. Try accessing the PHP document by address 'http://localhost/test1.php', if all is well, you'll get the output of PHP document as you expect. Furthermore, in future, try to make a subfolder in the 'www' folder, and the subfolder can be used to organize your projects. For example a subfolder 'practice' can be accessed by address 'http://localhost/practice/<your_php_filename>'. If you create an 'index.php' in that subfolder, you can view the output of 'index.php' just by accessing 'http://localhost/practice' because a file 'index.php' is automatically loaded when a filename isn't specified in the URL. Hth, cmiiw
11th Aug 2019, 3:37 AM
Ipang