Is it possible to use quote inside a placeholder?

Status
Not open for further replies.

Borox

Member
Hi,

I use a placeholder in a validation element (in the condition field).
The content of the placeholder can be empty, so I need to use '{myplaceholder}' or "{myplaceholder}"...it works great, but bad luck the content of the placeholder can also contain ' or " :) when that case occurs I have a syntax error ( too many quote...)
Is there a way to avoid that? I tried to use the validation 'SpecialChars' to replace " by ' but it didn't work.

Thanks for your help.

Nicolas
 
You'll have to grab the value yourself. I believe at the point your code runs, the form data will be in either/both of the $data or $formModel->formData arrays. So ...

Code:
$myThing = FArrayHelper::getValue($formModel->formData, 'mytable___mything', '');

-- hugh
 
Last edited:
Status
Not open for further replies.
We are in need of some funding.
More details.

Thank you.

Members online

Back
Top