added an additional check for magic quotes, REF #597

it will now check if the function "get_magic_quotes_gpc" exists