HikaShop Content Module stop scrolling

  • Posts: 232
  • Thank you received: 4
  • Hikaserial Standard Hikashop Business
3 years 10 months ago #332401

-- url of the page with the problem -- : www.thhs.co.uk
-- HikaShop version -- : 4.4.2 Business Edition
-- Joomla version -- : 3.9.26

Hello,
On my client's website we use the HikaShop Content Module in the right sidebar as a category menu. When you click on one of the entries the browser page 'scrolls' to this location on the menu. How can I prevent this scrolling action?

Thanks
Lee

Please Log in or Create an account to join the conversation.

  • Posts: 83403
  • Thank you received: 13497
  • MODERATOR
3 years 10 months ago #332404

Hi,

On this website, I can see that you've activated the use of bootstrap. Thus, HikaShop uses bootstrap system for the accordion.
So a quick look online brought me to this page:
stackoverflow.com/questions/28977499/boo...e-or-expand-elements
So, in the file administrator/components/com_hikashop/helpers/sliders.php you can change the line:

<a class="accordion-toggle" data-toggle="collapse" data-parent="#'.$this->name.'" href="#'.$id.'">
to:
<a class="accordion-toggle" data-toggle="collapse" data-parent="#'.$this->name.'" href="javascript:void(0);">
and that should do it.

Please Log in or Create an account to join the conversation.

  • Posts: 232
  • Thank you received: 4
  • Hikaserial Standard Hikashop Business
3 years 10 months ago #332448

Nicolas,
Thanks for the reply. I tried your change to that file, but it then prevents the menu accordion opening at all. With that href removed it then does not target the child div to open, and you then cannot see the sub items.

Lee

Please Log in or Create an account to join the conversation.

  • Posts: 83403
  • Thank you received: 13497
  • MODERATOR
3 years 10 months ago #332449

Hi,

Well, I'm just proposing following the instructions of that other page I found since the accordion system is not something we developed ourselves but comes from bootstrap.
Then, try to change that same line of code to:

<a class="accordion-toggle" data-toggle="collapse" data-parent="#'.$this->name.'" href="#">
That's what is recommended by the second most up voted answer on that page.

Please Log in or Create an account to join the conversation.

Time to create page: 0.036 seconds
Powered by Kunena Forum