External Link in Menu not working

  • reginac
    Inactive member
  • Topic Author
  • New Member
  • New Member
More
11 years 9 months ago - 11 years 9 months ago #27064 by reginac
Hello I recently bought this nice template, but i´m having some trouble creating a new menu item with an external link tho. I already read the other posts but those solutions didnt solve my problem.

In Main Menu I created an external url. In link css style added "external" but the link doesn´t work. I also replaced the code but still nothing happened.

Can you help me please?

Thanks :)
Last edit: 11 years 9 months ago by reginac. Reason: Just dont want to link to my domain. Thank you

Please Log in to join the conversation.

More
11 years 9 months ago #27069 by ivan.milic
Did you did this:

Open:

/templates/hot_one_page/js/hot_onepage.js

replace:

jQuery(".scroll, .mp_topmenu a").click(function(event){
event.preventDefault();
jQuery('html,body').animate({scrollTop:jQuery(this.hash).offset().top}, 500);
});

with:

jQuery(".scroll, .mp_topmenu a:not(.external)").click(function(event){

jQuery(".active").removeClass("active");
jQuery(this).closest("LI").addClass("active");

event.preventDefault();
try{
jQuery('html,body').animate({scrollTop:jQuery(this.hash).offset().top}, 500);
}catch(e){
jQuery('html,body').animate({scrollTop:0}, 500);
}
});

Please Log in to join the conversation.

  • reginac
    Inactive member
  • Topic Author
  • New Member
  • New Member
More
11 years 9 months ago #27071 by reginac
Yup and did it again, but nothing happened.

Please Log in to join the conversation.

  • reginac
    Inactive member
  • Topic Author
  • New Member
  • New Member
More
11 years 9 months ago #27073 by reginac
Any advice?

Thanks

Please Log in to join the conversation.

More
11 years 9 months ago #27087 by ivan.milic
Maybe you just need to refresh browser so new script loads. Did you put " external" for menu item class ?
The following user(s) said Thank You: reginac

Please Log in to join the conversation.

  • reginac
    Inactive member
  • Topic Author
  • New Member
  • New Member
More
11 years 9 months ago - 11 years 9 months ago #27096 by reginac
Solved. My mistake, I literally typed "external" (with quotes) ,changed it for external (without quotes) and now it works like a charm. thank you for your patience and advice :) Great work.
Last edit: 11 years 9 months ago by reginac. Reason: Solved

Please Log in to join the conversation.

Time to create page: 0.081 seconds
Powered by Kunena Forum