Welcome Guest, Not a member yet? Register   Sign In
Adding PHP to HTML Code
#1

[eluser]BigJoe[/eluser]
I was told and from what I can see in the video tutorials that CI all so requires php code to be added in the HTML Pages. I was and have been told that this is not a good idea to code in this way. If every one is telling me not to do this. Then why do all the video tutorials I have seen and what I been reading say it's Ok to do this. I have been told that it makes it easy for hackers to hack web sites by doing this. and there or maybe other reasons too.

Please post views and options.

Joe
#2

[eluser]InsiteFX[/eluser]
Really! Put some php code in your html template and then do a view source and I'll bet you do not see any php code at all.

The thing is never never never trust user input!
#3

[eluser]Zurtri[/eluser]
I concur that php in HTML is a relatively standard practice.

The danger comes when you trust user input. So always ensure you clean and escape the user input.

The input class does some of the heavy lifting for you: http://ellislab.com/codeigniter/user-gui...input.html




Theme © iAndrew 2016 - Forum software by © MyBB