Maximenu mobile and preventDefault
- johnoatwork
- Offline Topic Author
- New Member
- Posts: 19
- Thanks: 0
Hi Ced,
I have a number of menus items that call functions on a click event on the menu class. The menu items are actually pointing to an article and I preventDefault on the class click event to stop the article from loading then perform the function.
The functions work fine with maximenu when the menu is in full screen but when it is responsive mode the javascript is ignored and the article is loaded.
My subscription to maximenu mobile expired a few days ago. Happy to renew it if I can get this to work but this is the only application I have for the product at this time.
Do you think there may be an easy fix for this?
Thanks,
John
I have a number of menus items that call functions on a click event on the menu class. The menu items are actually pointing to an article and I preventDefault on the class click event to stop the article from loading then perform the function.
The functions work fine with maximenu when the menu is in full screen but when it is responsive mode the javascript is ignored and the article is loaded.
My subscription to maximenu mobile expired a few days ago. Happy to renew it if I can get this to work but this is the only application I have for the product at this time.
Do you think there may be an easy fix for this?
Thanks,
John
by johnoatwork
Please Log in or Create an account to join the conversation.
Hi
I think that the problem comes from the fact that the mobile menu is loaded by javascript. May be that
- your script does not call the items from the mobile menu as they have a different structure
or
- your script is called before the mobile menu is rendered, and then has no impact on it
CEd
I think that the problem comes from the fact that the mobile menu is loaded by javascript. May be that
- your script does not call the items from the mobile menu as they have a different structure
or
- your script is called before the mobile menu is rendered, and then has no impact on it
CEd
Joomlack Webmaster and Developer
by ced1870
Please Log in or Create an account to join the conversation.
- johnoatwork
- Offline Topic Author
- New Member
- Posts: 19
- Thanks: 0
Replied by johnoatwork on topic Maximenu mobile and preventDefault
Posted 8 years 8 months ago #29223
Hi Ced,
I've found the problem but I'm not sure yet how to fix it. If I look at the menu items in Firefox, none of Link CSS Style classes are present in the mobile menu.
There are no console errors.
Anyway, I decided to work through it. Yours is still the best thing out there for Joomla.
Any thoughts on why this might be happening?
Cheers
John
I've found the problem but I'm not sure yet how to fix it. If I look at the menu items in Firefox, none of Link CSS Style classes are present in the mobile menu.
There are no console errors.
Anyway, I decided to work through it. Yours is still the best thing out there for Joomla.
Any thoughts on why this might be happening?
Cheers
John
by johnoatwork
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.
- johnoatwork
- Offline Topic Author
- New Member
- Posts: 19
- Thanks: 0
Replied by johnoatwork on topic Maximenu mobile and preventDefault
Posted 8 years 8 months ago #29239
I've stood up an instance on a VM you can have a look at. I'd rather PM you the URL because the site isn't ready for public access yet. But I can find a PM option in Kunena! Is there a way to contact you that is not public? Report to moderator?
Sorry if its obvious, I just can't see it :blush:
Thanks
John
Sorry if its obvious, I just can't see it :blush:
Thanks
John
by johnoatwork
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.
Time to create page: 0.686 seconds