At 15:04 11.03.01 +0100, you wrote:
>Emiliano wrote:
>
>>Ingo Herz wrote:
>>
>>>Hi,
>>>after creating some articles with attachments I have this problem:
>>>if the title of an article contains quotes (") and I create an
>>>attachment, asgard gives
>>>Parse error: parse error in snippet:///Asgard/Functions/basic on line 11
>>>I fixed it by replacing $str with addslashes($str) in the line mentioned
>>>above. Is this ok or will there be any side effects? Are there other parts
>>>of asgard where this could be necessary, too?
>>
>>Odd, midgard-lib is supposed to handle this. David? What do you think?
>
>I just tested it but I didn't see that behavior...
>Ingo, can you send the function asgard_localized_name($str) ?
I found _2_ versions of asgard_localized_name():
in Asgard/Functions/basic: (with addslashes added)
function asgard_localized_name($str)
{
global $AsgMsg;
/*
if($AsgMsg->Common_LocalizedNameFunction_String)
$msg=stripslashes( $AsgMsg->Common_LocalizedNameFunction_String);
else
*/
$msg="\"%s\"";
eval( sprintf("\$retval= ($msg);", addslashes($str)));
return $retval;
}
in Asgard/Functions/basic-deprecated: (unchanged)
function asgard_localized_name($str)
{
global $AsgardMessages_LocalizedNameFunction;
if($AsgardMessages_LocalizedNameFunction)
$msg=stripslashes( $AsgardMessages_LocalizedNameFunction);
else
$msg="%s";
eval( sprintf("return($msg);", $str));
}
>What version of Midgard/Asgard are you using ?
I currently use a 1.4 lib/mod with asgard 1.4.1 from CVS. But the problem
occured also with a fresh install of the 1.4 packages. David, can you duplicate
the behavior with umlauts or quotes in article titles and names (mailed
01/03/09)?
regards,
Ingo Herz
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]