This topic is locked

Control rows, possibility

11/28/2006 4:21:08 AM
PHPRunner General questions
M
maxcolo author

Buongiorno to all, sorry for my english, I am italian,

use phprunner 3.1 I would want that a customer can select one series of rows in list.php with one control case in order to visualize only those rows. Possible E' this operation? And like eventually

J
Jane 11/28/2006

Hi,
you can do the following:

  1. proceed to the Visual editor tab, open your LIST page in the HTML mode, find this line:
    <!-- delete form -->



and add your code just before:

<A onclick="if (!confirm('Do you really want to update these records?')) return false; frmAdmin.a.value='update'; frmAdmin.submit(); return false;" href="orders_list.htm#">update selected</A>


2. remove delete icon on the LIST page on the Visual Editor tab.
3. proceed to the Events tab and add BeforeDelete event.

Here is a sample code:

function BeforeDelete($where)

{

//delete records

if(@$_POST["a"]=="delete")

return true;
//update records
//add your code here

//...

return false;

}