-
AuthorPosts
-
May 28, 2014 at 3:56 pm #49445
Hi Global,
The code works fine and tested before it is posted and it was given to different threads with same issues like yours, but it was revised to work on your setup.
The code have two purpose,
1. It will link/scroll you to the tab of same page, thus adding “link_to_tab” to a button’s class is a requirement.
2. It will link/scroll to the tab of another page, thus “link_to_tab” should not be added.
It means, “link_to_tab” is only required on same page scrolling.
Could you try this one, a revision to send target object separately.
jQuery(function($){ $(document).ready(function() { x_scroll_to_tab($, $('.x-nav-tabs .x-nav-tabs-item a[href="#' + location.href.split("#").slice(-1)[0] + '"]') ); }); $('.link_to_tab').click(function(e){ e.preventDefault(); x_scroll_to_tab($, $('.x-nav-tabs .x-nav-tabs-item a[href="#' + $(this).attr('href').split("#").slice(-1)[0] + '"]')); }); }); function x_scroll_to_tab($, tab_nav) { $(tab_nav).click(); $('html,body').animate({scrollTop: jQuery(tab_nav).offset().top - jQuery('header.masthead').height() },700 ,'swing'); }
Let us know.
June 4, 2014 at 1:42 am #52059Sorry, but it still does not work. If I click the button, the right link appears in my brwoser, but nothing happens. When I activate the link that appears in my browser by reloading the page, it does work…
June 4, 2014 at 1:36 pm #52378Hi there,
I’m not sure why it wouldn’t be working on your site. Would you mind providing us with login credentials so we can take a closer look? To do this, you can make a post with the following info:
– Link to your site
– WordPress Admin username / password
– FTP credentialsDon’t forget to select Set as private reply to ensure that your data remains hidden
June 5, 2014 at 4:33 am #52744This reply has been marked as private.June 5, 2014 at 2:29 pm #52983Hi there,
You must not add element attribute with quotes or html elements.
Examples, these are wrong :
<hr class="\"x-gap\"" style="\"margin:" 10%="" 0="" 0;\"="">
<a class="x-btn <span x-btn-real x-btn-rounded x-btn-small" href="#tab-4" data-options="thumbnail: ''">Prijzen</a>
And buttons does not have link_to_tab which should have, except if it’s linking to another page’s tab.
Yours is :
<a class="x-btn <span x-btn-real x-btn-rounded x-btn-small" href="#tab-5" data-options="thumbnail: ''">Beschikbaarheid</a>
And should be :
<a class="x-btn x-btn-real x-btn-rounded x-btn-small link_to_tab" href="#tab-5" data-options="thumbnail: ''">Beschikbaarheid</a>
And upon checking, you are using wrong shortcode format :
[button class=<span style="color: #444444;">"link_to_tab"</span> type="real" shape="rounded" size="small" href="#tab-5"]Beschikbaarheid[/button]
I corrected the 3rd button for test. Should be
[button class="link_to_tab" type="real" shape="rounded" size="small" href="#tab-5"]Beschikbaarheid[/button]
And it works.
Paste your shortcode in Text Mode, so you will find if there is any hidden unwanted html markup.
Let us know.
June 10, 2014 at 5:57 am #54466THANKS a lot!!! It whas a hard one, but it feels great to make it finally work!
Have a nice day!
June 10, 2014 at 8:06 pm #54736You’re welcome!
May 3, 2016 at 4:38 am #910411Hi there, after updating the theme I have got the same problems as described above…
Could you please help me out?
Same website by the way… Tnx a lot!
May 3, 2016 at 12:08 pm #911068Please give us access to your WordPress admin so we could check. Tried the previous credentials but couldn’t login.
Thanks.
May 4, 2016 at 2:32 am #912057This reply has been marked as private.May 4, 2016 at 7:14 am #912338Hey there,
Would you mind disabling all third party plugins while we investigate?
Thanks.
May 6, 2016 at 3:19 am #978312No problem, but do it when you investigate. This website is used everyday, and I can not disable them for a long time, not knowing when you are investigating…
May 6, 2016 at 11:17 am #978771Hi there,
In that case, will you be able to setup a staging environment with the same copy of your live site? so that we investigate your issue. As we provide an additional development license, you can do this by creating a sub-domain in your server. You can refer to our guide for more information (https://community.theme.co/kb/cornerstone-migration/).
Let us know.
Thanks! -
AuthorPosts