This topic is locked

Countdown inline edit

12/7/2012 4:22:47 PM
PHPRunner General questions
W
wildwally author

Wondering if there is a way to to count how many records were selected for the inline edit - or tell when the last inline edit has been executed so that I can redirect the user.

C
cgphp 12/10/2012

You can count in the "Javascript onload" event how many checkbox were selected.

W
wildwally author 12/10/2012

Could you point to an example of this for me to use and modify accordingly? In particular how to read the value of the checkbox since it doesn't have specific ID.

C
cgphp 12/10/2012
var howMany = $("input[type='checkbox'][id^='check1_'] :checked").length;
W
wildwally author 12/10/2012


var howMany = $("input[type='checkbox'][id^='check1_'] :checked").length;



Ok so this will get the number on load - but I'm not so sure that I can achieve what I need with the on load as you suggest. Problem lies with the js taking place on the client, I can't pass the variable over to PHP to use in the inline edit code. I'm thinking this is what needs to happen as it's the only code that is being executed to evaluate, right?

W
wildwally author 12/13/2012

Ok so I've almost got this working as I would like.
One last step - how can i get the new button I've created to trigger the edit selected button code. I'm assuming there is more going on than just the normal before edit after edit triggers since that code doesn't bring up the edit fields.