Portal Home > Knowledgebase > Articles Database > PHP


PHP




Posted by folsom, 08-08-2008, 11:38 PM
I decided that I should learn PHP, so I ordered "Programming PHP". As I am reading through, I think to myself that there are a lot of functions that should have been left out of the language, but I am ok with that, it just makes the language a little messy. I got really excited reading chapter six on objects. But then early in chapter seven I read: I am beginning to wonder what type of mentality went into designing this stupid magic_quotes_gpc feature and even worse, why did they make it enabled by default. If they did this, then my guess is that there are a lot more "features" that I had better keep an eye out for. So what other gotchas are there in PHP that someone learning the language should be aware of.

Posted by pharmacyclone, 08-08-2008, 11:52 PM
HAHAHAHA come on do not learn it are you out of your mind? ;x

Posted by Steve_Arm, 08-08-2008, 11:59 PM
You are looking it from the wrong side. Magic quotes was always there and on, because it helps to safe escape malicious user input, because people coming to PHP don't know much about security until they are hacked.

Posted by etogre, 08-09-2008, 12:26 AM
You can disable them easily. Shamelessly taken from php.net Another gotcha of PHP is Register Globals.

Posted by Tom P, 08-09-2008, 12:30 AM
PHP is always evolving, and what might have been a good idea when it was introduced may be a bad idea now. PHP 6 will see that magic_quotes and register_globals are removed.

Posted by folsom, 08-09-2008, 09:43 AM
Nice work around. Oh my you are right I did not think about register globals as being a problem since it is not a default, but just the fact that it is an option could be a problem.



Was this answer helpful?

Add to Favourites Add to Favourites    Print this Article Print this Article

Also Read
JVM problem ? (Views: 588)
Bulk Mail Server (Views: 598)
xilo.net (Views: 634)