using inline edit disables forms php plugin

p38

Active Member
I use form php plugins quite extensively to update fields etc after a form is submitted.

The form plugin is attached to the "on before submission" event.

I have always assumed that when using inline edits, the php plugin will be called when the edit is saved, but I notice this is not the case.

What must be configured in order to ensure form php plugins are executed when the inline edit elemnt value is saved?

Paul
 
I just checked and for me the PHP plugin events are called. I created a form php plugin with this code:

Code:
echo "here";
exit;

that updates the cell with the text "here".
What specifically are you trying to do in the php plugin?

-Rob
 
Your test works, however, if I run my code (updates other tables) it does not run using inline edit, BUT it does run when I edit the record via a form.

So I know my code is working.

The only grey area is the updateFormData, which might not be availbale when using inline edit. If not, how do I get around this?

Paul

include_once('cdslib/cds.mysql.class.php');

// connect to implayer
$dbconnect = new MySQL(true, "implayer_db", "xxxxx", "yyyyy", "zzzzzzz");
if ($dbconnect->Error()) {
//echo $dbconnect->Error();
}
else
{
//where criteria
$display = "'{im_slideshow___display}'";

// get config dataset
$autoupload = $dbconnect->QuerySingleValue("select auto_upload from im_clients where display = ".$display);

//echo $autoupload;

if ($autoupload == 'yes')
{
$formModel->updateFormData('im_slideshow___download','yes', true);
}

$dbconnect->Close();

}
 
I'm not sure that placeholders will be available here. Could you try replacing '{im_slideshow___display}'with a test value to see if that works?
what out put did you get for the query? what was $autoupload set to?

-Rob
 
We are in need of some funding.
More details.

Thank you.

Members online

Back
Top