Ingo Herz wrote:
> 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;
> }
same as mine, but I don't have the parse error...
> in Asgard/Functions/basic-deprecated: (unchanged)
>
This one is deprecated, and is only here for reference and historical reason.
>> 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)?
yes, I don't see the parse error, but I can reproduce the unwanted conversions (& ->
& and so on...).
Will try to see where it comes.
> regards,
> Ingo Herz
--
Best Regards,
David Guerizec Free Software Developer
Aurora R&D [EMAIL PROTECTED]
Midgard core developer http://www.midgard-project.org/
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]