This topic is locked
[SOLVED]

 clickable row

10/18/2011 5:06:30 AM
PHPRunner General questions
author

Hi
Is their a way of making the whole row clickable. For example at the moment a user can click on the magnifying glass icon to go to the view page can I make it that if they click on any section of that row the row automatically redirects to that view page. Sort of make the whole row a href clickable section.
I am using phprunner 6
Thanks
Richard

C
cgphp 10/18/2011

If you have popup enabled:

$("a[id^='viewLink']").bind('click', function() {

return false;

});
$("tr[id^='gridRow']").click(function(e){

$(this).find("a[id^='viewLink']").trigger('click');

});


else

$("a[id^='viewLink']").bind('click', function() {

window.location.href = $(this).attr('href');

return false;

});
$("tr[id^='gridRow']").click(function(e){

$(this).find("a[id^='viewLink']").trigger('click');

});
7542 11/21/2011

Thanks for your help. Great advice
Regards
Richard

C
Cyclones 11/28/2011

I'm looking to try that out myself in my project. Just learning the custom stuff. Can you let me know exactly where I would put that code?
Thanks for your help.

C
cgphp 11/28/2011

In the "Javascript OnLoad" event of the List page.

C
Cyclones 11/28/2011



In the "Javascript OnLoad" event of the List page.


Fantastic. Works perfectly, thanks.