On Tue, 13 Mar 2001 14:17, Kenneth R Zink II wrote:
> Ok, I'm pretty sure I need to use the "addslashes" function, but I'm
> not sure how to implement it.
>
> The 2 variables that I would need to addslashes are $sire and $dam.
>
> can someone please help me, this is new to me.
>
> Thanks.

It's like any other PHP function - you assign the result of the function 
to a variable. So:

$variable = addslashes($variable_to_add_slashes_to)

and those variables can be the same; so

$sire = addslashes($sire);
$dam = addslashes($dam);

would work in your case. Note that you are going to have to strip the 
slashes when displaying data from the DB - the command is not 
surprisingly called stripslashes.

What has possibly happened is that you have different settings in the ini 
file on your current server for one of the magic-quotes settings.

-- 
David Robley                        | WEBMASTER & Mail List Admin
RESEARCH CENTRE FOR INJURY STUDIES  | http://www.nisu.flinders.edu.au/
AusEinet                            | http://auseinet.flinders.edu.au/
            Flinders University, ADELAIDE, SOUTH AUSTRALIA

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to