This topic is locked

Update button on Add Page and Edit same record?

10/9/2008 2:01:01 PM
PHPRunner General questions
S
swanside author

Is it possible to add an extra button onto the add page called Update.
WHen pressed it will save the record and re-open the same record so you can add more details?.
Ta

Paul.

J
Jane 10/10/2008

Paul,
to create new button on the add page:

  1. In Visual Editorcreate a copy of the Save button

    Switch to HTML mode and modify new button label and ID:

    <INPUT class=button id=submit2 type=submit value="Update" [b]name=submit2>[/b]
  2. Implement AfterAdd event:
    if (postvalue("submit2")=="Update")

    {

    header("Location: TableName_edit.php?editid1=".$keys["RecordID"]);

    exit();

    }

S
swanside author 10/10/2008

Thanks Jane.