This topic is locked
[SOLVED]

 Custom Copy Button

2/8/2012 10:08:14 PM
PHPRunner General questions
W
wildwally author

I think I'm missing something and need some assistance. I've create a new button on the view page. within the button on the "Client Before" I've included this code.

var regexS = "[\\?&]editid1=([^&#]*)";

var regex = new RegExp( regexS );

var results = regex.exec( window.location.href );

params["edit"] = results[1];
window.location.href ="QuoteRequests__add.php?copyid1="+results[1];


Is there anything else I need to add to the Server and Client after? When clicking the button the href is correct but nothing is happening. I can't tell what the PHPRunner copy buttons are doing to see if more or less is needed.
Thanks,

Sergey Kornilov admin 2/9/2012

Check Firebug for any Javascript errors.
Besides that, how do you verify that URL is correct?

W
wildwally author 2/9/2012



Check Firebug for any Javascript errors.
Besides that, how do you verify that URL is correct?


Thanks Sergey, I went back and looked at URL - mistakingly had two underscores in there. And the firebug was calling error page did not exist. From a glance last night it looked correct. It's working now.