Y
|
YCH 10/27/2017 |
When using the 'Additional WHERE tabs' feature, in phprunner9.8, i would like to obtain the active tab and then perform some actions (e.g. show/hide buttons) depending on which tab the user has clicked. In the help file i can see the ability to addTab(), deleteTab(), setTabTitle() but i cannot see anything about retrieving the current Tab id. Thanks Chris
|
![]() |
Admin 10/30/2017 |
Here is the Javascript code that returns the ID of the active WHERE tab: $("li[class=active]").find("a").attr("data-tabid") |
![]() |
chris.cleary author 11/2/2017 |
Here is the Javascript code that returns the ID of the active WHERE tab: $("li[class=active]").find("a").attr("data-tabid")
|
![]() |
Admin 11/2/2017 |
Your code works here. |
![]() |
chris.cleary author 11/3/2017 |
Your code works here.
|
![]() |
Admin 11/3/2017 |
As an alternative you can read "tab" parameter from the URL. This article can help: |
![]() |
chris.cleary author 11/6/2017 |
I am using this currently to determine the current tab, but i came across a few issues with this which resulted in me asking my original question. |
![]() |
Admin 11/6/2017 |
After you read tab id from the URL save it in session variable and use it in subsequent page calls till new one appears in the URL. |