Forum OpenACS Development: How to fix this?

Collapse
Posted by Daniël Mantione on
Hi,

Can somebody advise how to fix this issue properly?

See: http://cvs.openacs.org/cvs/openacs-4/packages/acs-subsite/www/user/email-privacy-level.tcl?rev=1.1&view=auto

{options {{"[_ acs-subsite.email_as_text]" 4} {"[_ acs-subsite.email_as_image]" 3} \
{"[_ acs-subsite.email_as_a_form]" 2} {"[_ acs-subsite.email_dont_show]" 1}}}
The problem is that a string is expanded between "". This means that if the translated string contains a ", things will break. If have a user on my site who translates into Hebrew, and needs the " character in the translation, so the translated pages break like hell.

I tried converting it into lists, but it doesn't give the desired result. Anybody an idea what to do here?

Collapse
2: Re: How to fix this? (response to 1)
Posted by Dave Bauer on
Try removing the quotes around the calls to the _ procedure. I don't think you need them there, it should be substituting the results of the procedure call at the correct level from what I can see.
Collapse
3: Re: How to fix this? (response to 2)
Posted by Daniël Mantione on
The doesn't work, because the form generator does a [lindex $string 1] on the string; removing the quotes will make that return the second word instead of the number.

This why I tried to convert it into [list ... ], but it doesn't work either :/

Collapse
4: Re: How to fix this? (response to 1)
Posted by Dave Bauer on
Do this

{options {{"#acs-subsite.email_as_text#" 4} {"#acs-subsite.email_as_image#" 3} \
{"#acs-subsite.email_as_a_form#" 2} {"#acs-subsite.email_dont_show#" 1}}}
Then the message keys will be substituted in the adp.