[pmwiki-users] PHP slashes (was ZAP Permissions and Includes)
Crisses
crisses at kinhost.org
Fri Oct 13 07:33:52 CDT 2006
It check whether or not the server already "addslash"ed the $_POST
variables before stripping them.
This would make it so you could port the code between any server
without worrying about stripping slashes people added on-purpose.
Crisses
--
No man is an island, entire of itself; every man is a piece of the
continent, a part of the main. If a clod be washed away by the sea,
Europe is the less, as well as if a promontory were, as well as if a
manor of thy friends or of thine own were: any man's death diminishes
me, because I am involved in mankind, and therefore never send to
know for whom the bell tolls; it tolls for thee.
-- John Donne, 1624.
On Oct 13, 2006, at 8:24 AM, The Editor wrote:
> On 10/13/06, Crisses <crisses at kinhost.org> wrote:
>>
>> Try something like this, when you receive the $_POST from the web
>> form:
>>
>> if (get_magic_quotes_gpc()) {
>> foreach ($_POST as $key=>$value) {
>> $_POST[$key]= stripslashes($value);
>> } }
>
>
> What is the purpose of this line
>
> if (get_magic_quotes_gpc()) {
>
> Couldn't I just stripslashes on the values?
>
> Cheers,
> Caveman
>
> _______________________________________________
> pmwiki-users mailing list
> pmwiki-users at pmichaud.com
> http://www.pmichaud.com/mailman/listinfo/pmwiki-users
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: /pipermail/pmwiki-users/attachments/20061013/3d2cdd0e/attachment.html
More information about the pmwiki-users
mailing list