You are here: Re: stripslashes « All PHP « IT news, forums, messages
Re: stripslashes

Posted by Good Man on 06/18/05 21:49

Good Man <heyho@letsgo.com> wrote in
news:Xns967994EDF1A09sonicyouth@216.196.97.131:

> Again, I'm stumped as to why you want to strip slashes from a posted
> form.

I just came up with a reason!

Your server likely has "magic_quotes_gpc" set to on, which automatically
escapes quotes with slashes upon form submission.

So, stripslashes() from the values rather than from the form.

as an example, your line (which is **bad** code anyways)...

$subject = "$_POST[subject]";

.... should be written as

$subject = stripslashes($_POST['subject']);




see ya

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация