Page 1 of 1

hiding code in php and php includes

Posted: Thu Aug 26, 2004 6:24 pm
by chuck_samsonite
hello.

I have a php question. I'm fairly new to php, but I used a php include to include my header info and when i checked the page source I could see the html code from the include. In coldfusion, all info between <cf> tags are not visible. I like this about coldfusion.

My question is....why is all the meta tags, head tags, etc showing when I include it. I dont want to (want to keep code clean in page source). Also, if there is a way to hide code in php I'd like to know, have had trouble finding it on the net.

thanks

chuck_samsonite
____________________________________
Lloyd: Oh yeah! It's right here, Samsonite! I was way off! I knew it started with an S though!

Posted: Thu Aug 26, 2004 6:33 pm
by markl999
You can't hide code from 'view source', if it's sent to the browser then you can see it. If you don't want it sent to the browser then just comment the code out, but why would you comment out meta/head tags etc ?

Posted: Thu Aug 26, 2004 7:58 pm
by andre_c
I'm curious, can you post an example page where cold fusion is hiding the header information?