Fingertech
Advanced Member
Canada
318 Posts |
Posted - 02/07/2020 : 22:27:08
Example product: https://www.fingertechrobotics.com/proddetail.php?prod=G-2S-mAh Clicking the stars or text just under the price should open the Reviews spry tab, but doesn't. The script called is this next line, but I don't know enough to diagnose further: In includes.php: $detailreviewstarstext='<a href="#reviews" onclick="TabbedPanels1.showPanel(\'reviewsTab\');">%totrating% stars, based on %numratings% review(s)</a>'; Something is wrong with that? Thanks in advance.
|
Vince
Administrator
42874 Posts |
Posted - 02/09/2020 : 03:29:47
Hi Fingertech I think what you want there is... javascript:TabbedPanels1.showPanel(1); ...instead of... TabbedPanels1.showPanel(\'reviewsTab\'); But also, as you are not returning false from the onclick function the page will also "jump" to the #reviews anchor. To stop this you could do... <a href="#reviews" onclick="TabbedPanels1.showPanel(1);return false"> ...or alternatively... <a href="javascript:TabbedPanels1.showPanel(1);"> ...removing the onclick entirely. Vince Click Here for Shopping Cart SoftwareClick Here to sign up for our newsletterClick Here for the latest updater
|
Fingertech
Advanced Member
Canada
318 Posts |
Posted - 02/09/2020 : 21:30:40
Hi Vince, thanks for the reply. Using those with (1) always opens the second tab instead of the Reviews tab. Replacing with \'reviewsTab\' doesn't work though. What should it be?
|
Vince
Administrator
42874 Posts |
Posted - 02/09/2020 : 23:46:48
|
Fingertech
Advanced Member
Canada
318 Posts |
Posted - 02/10/2020 : 10:53:23
Are you sure it can't open the Reviews tab? That's how the code came when we bought the Responsive design, unless Andy changed it when he was helping with the paid Site Makeover?
|
Sinbad
ECT Moderator
USA
65937 Posts |
Posted - 02/10/2020 : 18:30:59
|
Fingertech
Advanced Member
Canada
318 Posts |
Posted - 02/10/2020 : 18:39:42
Hi Sinbad, Have you been trying it only on products where Reviews is the second tab? Because it always opens the second tab, no matter what it is. Try on a product like https://www.fingertechrobotics.com/proddetail.php?prod=ft-tinyESCv2
|
Sinbad
ECT Moderator
USA
65937 Posts |
Posted - 02/10/2020 : 19:18:24
|
Vince
Administrator
42874 Posts |
Posted - 02/11/2020 : 03:17:13
Hi Fingertech quote: Are you sure it can't open the Reviews tab? That's how the code came when we bought the Responsive design
Well I had a look into this this morning and it seems you can use an ID, if the tab has the ID set, but there isn't currently a way to do that so I'm not sure how Andy set this up. But I've made the changes so that you can set an ID and added it to the forthcoming v7.2 updater if you want to try, and you can get that here... https://www.ecommercetemplates.com/downloads.asp You just need the incproddetail.php script for this (and this is the only change in incproddetail.php since v7.1.8), and once you have the new version you can set say... $ecttabsspecials='<ecttab title="Reviews" id="reviewsTab" special="reviews">'; ...and then linking to that ID will work. Vince Click Here for Shopping Cart SoftwareClick Here to sign up for our newsletterClick Here for the latest updater
|
Fingertech
Advanced Member
Canada
318 Posts |
Posted - 02/12/2020 : 18:09:34
Hi Vince,
I uploaded the newest incproddetail.php
In includes.php,: $ecttabsspecials='<ecttab title="Reviews" id="reviewsTab" special="reviews"><ecttab title="Related" special="related">';
I've tried with each of these (your earlier suggestions): $detailreviewstarstext='<a href="#reviews" onclick="TabbedPanels1.showPanel(\'reviewsTab\');">%totrating% stars, based on %numratings% review(s)</a>'; $detailreviewstarstext='<a href="#reviews" onclick="javascript:TabbedPanels1.showPanel(\'reviewsTab\');">%totrating% stars, based on %numratings% review(s)</a>'; $detailreviewstarstext='<a href="#reviews" onclick="TabbedPanels1.showPanel(\'reviewsTab\');return false">%totrating% stars, based on %numratings% review(s)</a>'; $detailreviewstarstext='<a href="javascript:TabbedPanels1.showPanel(\'reviewsTab\');">%totrating% stars, based on %numratings% review(s)</a>';
I get this error: TypeError: panels[tpIndex] is undefinedSpryTabbedPanels.js:384:2 showPanel https://www.fingertechrobotics.com/SpryAssets/SpryTabbedPanels.js:384 onclick https://www.fingertechrobotics.com/proddetail.php?prod=ft-minisumo-wheels-1125:1

|
Vince
Administrator
42874 Posts |
Posted - 02/13/2020 : 04:16:24
I tried with this ... $detailreviewstarstext='<a href="javascript:TabbedPanels1.showPanel(\'reviewsTab\');">%totrating% stars, based on %numratings% review(s)</a>'; and no problem at all, I get the Reviews tab when I click. Can you double check it was the v7.2 updater you got the incprodetail.php script from? I've re-uploaded the updater again to make sure the changes are there. You need to get the v7.2 updater from here... https://www.ecommercetemplates.com/downloads.asp Vince Click Here for Shopping Cart SoftwareClick Here to sign up for our newsletterClick Here for the latest updater
|
Fingertech
Advanced Member
Canada
318 Posts |
Posted - 02/13/2020 : 12:48:29
Yep uploading the new 7.2 incproddetail.php got it working! Thanks Vince!
Edited by - Fingertech on 02/13/2020 22:36:28
|
|
|