dropdown element advanced eval options do not evaluate placeholders

p38

Active Member
try as I may, I cannot seem to get the dropdown element advanced eval options to evaluate placeholders?

Do you think this has been omitted?

If so, any chance of having it included?

Paul
 
Code:
$app = JFactory::getApplication();
$x= $app->input->getString('table___element');
should do.
 
thanks troester, tried this but no success

$app = JFactory::getApplication();
$id= $app->input->getString('emaillist___dbconnection');

would getString be available in a form? or element at time of rendering?

I want to populate the dropdown list using advanced php eval populate, but it looks like '{emaillist___dbconnection}' is not supported.
 
Nope, the input array is only set during form submission.

You should be able to do (I think) ...

PHP:
$this->getFormModel->getElementData('emaillist___dbconnection');

Add a second arg, true, to getElementData if you want the raw value.

-- hugh
 
Or, you could try editing ./components/com_fabrik/models/element.php, around line 3563 you'll find:

PHP:
    protected function getPhpOptions()
    {
        $params = $this->getParams();
        $pop = $params->get('dropdown_populate', '');
 
        if ($pop !== '')
        {
            $w = new FabrikWorker;
            $pop = $w->parseMessageForPlaceHolder($pop, $this->getFormModel()->getData());

Well, you won't find those last two lines. Add them. See if that works for enabling placeholder replacement.

If so, I'll commit that change to github.

-- hugh
 
I also see the normal dropdown list element also does not eval(), I just saw it yesterday and noticed it does not work AGAIN with latest build.

Please Rob or Hugh, put it back again, not sure how it got lost.
 
We are in need of some funding.
More details.

Thank you.

Members online

No members online now.
Back
Top