Jump to content

Hiding content in source view with PHP - is this possible?


iconicCreator

Recommended Posts

Hello good people!

I am sitting here wondering how can I dynamically add content to an HTML page using PHP so that the content is not visible when users view page source?

Lets say I have a Nav Bar which contains a bunch of links that goes through out the site.

 

Is there any method apart from include that I can use to add the Nav Bar to the html page but not make the Nav Bar visible when some view page source?

 

I have been using include to help me break down my pages, script and separating content from actual layouts, the problem is you can still view the content in source.

 

I'm just curious if there is such method, not that I would want to be hiding content which is not something I strongly care about but just curious.

 

IC

No you can't.

 

In order to view a page a browser downloads the source code so it will always be visible.

you can make a horrible mess of the code so it becomes harder to read.. but really it hardly serves any purpose.

 

Thanks, I thought the same but don't know a lot of PHP, was thinking there was a way there.

 

Have a wonderful day!

 

IC

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.