Newbie to php so mind the silli question, but

if a web page comes up index.php but theres no php programming coded into that page, what does this mean?

Are you saying you have code in index.php but nothing is displayed? If so, add the following to lines of code at the top of the script.


error_reporting(-1);
ini_set('display_errors', true);

Hopefully, you’ll see if there are errors occurring. You may need to check your web server and PHP logs too.

:slight_smile:

hi,
you see Im a newbie at making sites and I have come across some websites where I view the source code. The index page is sometimes saved as index.php.
but no php code to be seen,

I was just wondering. :slight_smile:

The web server runs the PHP script (index.php) and displays what it’s instructed by the script. If everything is configured correctly, you’ll never (purposely) see any PHP code with your browser. :slight_smile:

The only way you will actually see the source code is if you have access to the actual file before it is parsed.

What you see in your browser is the output that is generated from the PHP, not the actual code, and as Anthony said you will never see any PHP code in your browser like that.

ahh rite thanks guys, that answers my question :slight_smile: