This topic is locked
[SOLVED]

 Adding a custom Button

12/28/2009 2:24:43 AM
PHPRunner General questions
D
dcrera author

Hi
I am using PHPRunner 4.2.
I want to add a button to a view page that will set a indicator (update) on a table when that button is clicked.
I tried this example http://www.xlinesoft.com/phprunner/docs/update_multiple_records.htm and I managed to get the button on the VE but I get no response when the button is clicked.
Please assist
Thanks

J
Jane 12/28/2009

It's difficult to tell you what's happening without seeing actual files.
Please publish your project on Demo Account and open a ticket at http://support.xlinesoft.com sending a URL to your pages along with instructions on reproducing this error.

D
dcrera author 12/28/2009

Hi Jane,
I am not in a position to email you the project because it is huge.
To simplify, I would explain as clearly as I can :
We have a web page that we capture quotations (costing) for a service. The original quote is done by a junior staff.

The quote must then be approved by a supervisor. The supervisor will view the quote and if he is content, he would approve the quote. This process will update the database with supervisor's user id and current date.
I need a custom button on the view page so that when the supervisor clicks on the 'Approve' button the update will take place.
Hope this helps
Thanks



It's difficult to tell you what's happening without seeing actual files.
Please publish your project on Demo Account and open a ticket at http://support.xlinesoft.com sending a URL to your pages along with instructions on reproducing this error.

J
Jane 12/29/2009

Hi,
here is a sample button:

<input type=button class=button value=Approve onclick="window.location.href='tablename_view.php?editid1={$show_key1}&approve=yes';">


Then update current record in the View page: Before process event:

if (@$_REQUEST["approve"]=="yes")

{

...

}
D
dcrera author 12/29/2009

Jane,
You the best.
Thank you and have a great 2010