Open yotpo reviews link in a custom tab

Solved
New Member
7 0 0

Hello there,

 

In my product page, I'm trying to find out how to open yotpo review link in my  tab "review". I have found my tab id which is called #tab_review.

 

I'm using the following script in the /head section:

<script> $( document ).ready(function(){ jQuery('.yotpo.bottomLine').on('click' , function(){jQuery('a[href=”#$( document ).ready(function(){ jQuery('.yotpo.bottomLine').on('click' , function(){jQuery('a[href=”#tab_review”]').trigger('click');});});”]').trigger('click');});});</script>

Unfortunately, it's not working and I can't find out why. I would appreciate someone point me what I am doing wrong...

0 Likes

Hi @BL2,

 

if you could post a link to the preview of the theme you are trying this on, perhaps I can help you.

Alex Dereveanco | CMO @ visely.io
- Was my reply helpful? Click Like to let me know!
- Was your question answered? Mark it as an Accepted Solution!
- To learn more about the awesome stuff we do head over to visely.io or our blog
0 Likes
New Member
7 0 0

Hello Alexandru,

 

Thanks for your time. You can take a look at the product page here: https://bit.ly/2VyWNKc

 

I followed this step by step from yotpo here: https://support.yotpo.com/en/article/setting-up-the-star-rating-to-open-the-reviews-widget-in-a-tab

0 Likes
New Member
7 0 0

Hi @Alexandru_Derev 

 

Did you have any minute to take a look at my message?

0 Likes

Hi @BL2 ,

 

thanks for reminding me about this.

 

This is the code you currently have for this functionality:

 

  <script>
$( document ).ready(function(){ jQuery('.yotpo.bottomLine').on('click' , function(){jQuery('a[href=”#$( document ).ready(function(){ jQuery('.yotpo.bottomLine').on('click' , function(){jQuery('a[href=”#tab_review_tabbed”]').trigger('click');});});”]').trigger('click');});});</script>

It's clearly broken.

 

It should look like this:

 

<script>
jQuery('.standalone-bottomline').on('click' , function(){jQuery('div#tab_review').addClass('active');jQuery('ul[role=tablist] li.active').removeClass('active');jQuery('li#tab_review_tabbed').addClass('active')});</script>

The way the tabs are implemented on your site unfortunately make the yotpo guide quite useless.

 

Let me know if this works for you.

 

Regards

Alex Dereveanco | CMO @ visely.io
- Was my reply helpful? Click Like to let me know!
- Was your question answered? Mark it as an Accepted Solution!
- To learn more about the awesome stuff we do head over to visely.io or our blog
0 Likes

Hello 

 

<a class="text-m">2 Reviews</a>

 

 

<a href="#tab_review_tabbed" class="text-m">2 Reviews</a>

img-2.jpg

 

Want to modify or incorporate custom changes on store, Hire us.
If helpful then please Like and Accept Solution .
Email: pallavi@oscprofessionals.com
Skype : oscprofessionals-87
Free Review and advice for sale on store | Shopify Private App | Custom Theme Development | Custom Modifications In To Shopify Theme | SEO & Digital Marketing | Site Speed Optimization | Performance Site Audit
0 Likes
New Member
7 0 0

Once again Thanks @Alexandru_Derev for your time,

 

Unfortunately It doesn't work. Any ideas?

0 Likes
New Member
7 0 0

Thanks @oscprofessional for your reply,

 

Yotpo generate a js you cannot modify. I tried your solution by using the console, the onclick bring you to the 1st tab but doesn't open the review tab.

 

Thanks for your help

0 Likes

Hi @BL2,

 

yes.

 

Try this :

<script>$(document).ready(function(){jQuery('.standalone-bottomline').on('click' , function(){jQuery('div#tab_review').addClass('active');jQuery('ul[role=tablist] li.active').removeClass('active');jQuery('li#tab_review_tabbed').addClass('active')})});</script>

 

Forgot to init this script on document ready

Alex Dereveanco | CMO @ visely.io
- Was my reply helpful? Click Like to let me know!
- Was your question answered? Mark it as an Accepted Solution!
- To learn more about the awesome stuff we do head over to visely.io or our blog
0 Likes

Ok looks like your jquery is not initialized before the script runs, hold on

Alex Dereveanco | CMO @ visely.io
- Was my reply helpful? Click Like to let me know!
- Was your question answered? Mark it as an Accepted Solution!
- To learn more about the awesome stuff we do head over to visely.io or our blog
0 Likes