Home › Forums › Arnold WordPress Theme › How to remove ability to click through to posts from Slider 1
- This topic has 3 replies, 2 voices, and was last updated 8 years, 4 months ago by
john.
Viewing 4 posts - 1 through 4 (of 4 total)
-
AuthorPosts
-
January 29, 2018 at 9:06 pm #14388
Hi guys,
Great theme, excited to finish setting up!
I’d like my site to simply be Slider 1 as homepage, with no option to click through to any other pages or posts.
Therefore, I’d like a click on Tab slider text to do nothing. And on tablet/mobile, just the 1 tap changes the image (rather than hover on desktop), but 2nd tap does nothing/the same. No other pages/posts!
Can you advise how I can achieve this? I imagine it’s simple… or is it? Thanks in adv!
January 30, 2018 at 7:08 am #14393Hi,
It needs to change a js file in theme folder: /js/custom.theme.js, line337-389:
update to:
if(Modernizr.touchevents){ $('.bm-tab-slider-trigger-tilte').on('touchstart', function(e) { var _item = jQuery(this), _id = _item.data('id'), _logo_color = _item.data('color'); if(_default_logo != _logo_color) { themeData.body.removeClass(_default_logo).addClass(_logo_color); _default_logo = _logo_color; } if( !_item.parents('.bm-tab-slider-trigger').siblings('.bm-tab-slider-img').find('#'+_id).hasClass('bm-active') ) { _item.parents('.bm-tab-slider-trigger').siblings('.bm-tab-slider-img').find('#'+_id).addClass('bm-active'); _item.parents('.bm-tab-slider-trigger').siblings('.bm-tab-slider-img').find('#'+_id).siblings('.bm-tab-slider-img-item').removeClass('bm-active'); } if(!_item.hasClass('bm-active')) { _item.addClass('bm-active'); _item.parent('.bm-tab-slider-trigger-item').siblings().find('.bm-tab-slider-trigger-tilte').removeClass('bm-active'); e.preventDefault(); return false; } else { return false; } }); } else { $('.bm-tab-slider-trigger-tilte').hover(function(){ var _item = jQuery(this), _id = _item.data('id'), _logo_color = _item.data('color'); if(_default_logo != _logo_color) { themeData.body.removeClass(_default_logo).addClass(_logo_color); _default_logo = _logo_color; } if(!_item.hasClass('bm-active')) { _item.addClass('bm-active'); _item.parent('.bm-tab-slider-trigger-item').siblings().find('.bm-tab-slider-trigger-tilte').removeClass('bm-active'); } if( !_item.parents('.bm-tab-slider-trigger').siblings('.bm-tab-slider-img').find('#'+_id).hasClass('bm-active') ) { _item.parents('.bm-tab-slider-trigger').siblings('.bm-tab-slider-img').find('#'+_id).addClass('bm-active'); _item.parents('.bm-tab-slider-trigger').siblings('.bm-tab-slider-img').find('#'+_id).siblings('.bm-tab-slider-img-item').removeClass('bm-active'); } },function(){ return false; }); $('.bm-tab-slider-trigger-tilte').click(function(){ return false; }); } }Regards!
January 31, 2018 at 4:12 am #14400Amazing. Will try this pronto. Thanks guys!
January 31, 2018 at 6:04 am #14408Update: it works beautifully. Thanks again!
-
AuthorPosts
Viewing 4 posts - 1 through 4 (of 4 total)
- You must be logged in to reply to this topic.
