Menu Jquery does not open!

Asked

Viewed 59 times

1

This is the page: http://www.magicforbaby.com.br/sobre.php

Problem: When I’m at a resolution less than 800px (yes, I’m making use of media queries), i make the menu retracts in a default figure, then when clicking it opens the menu. But this giving error:

Uncaught ReferenceError: $ is not defined       sobre.php:69            
Uncaught ReferenceError: urlproduto is not defined   VM127:6

On line 69

  $(document).ready(function(e){

    $(".menuAbrir").click(function() {
      $(".menuNav").show();
      $(".menuAbrir").hide();
    });

    $(".menuFechar").click(function() {
      $(".menuNav").hide();
      $(".menuAbrir").show();
    });
  });

I have this JQuery to open the menu as it is included on all pages. But this is giving this error;

More precisely line 69:

$(document).ready(function(e){

What to do?

  • Maybe it could be the order in which the <script src="jquery.js"> was placed, see if it is being referenced before that script Voce posted.

  • Ex: <script src="jquery.js"> just below <script type="text/javascript"> ...your </script code>

1 answer

2


Looking at the source code of the page I did not find the link to Jquery. Do the following:

Before your code <script type="text/javascript"> ...sua função </script> add reference to your jquery.js file, <script src="jquery.js">.

  • Sorry, really forgot to put. Tiredness does it! kkk. Taking this opportunity, you can explain to me why this page, http://www.magicforbaby.com.br/contact.php?form, in the form fields, are locally stylized correctly Texts inputs but on the web are not stylized correctly and the css are correctly posted?

  • Open a new question for css, otherwise it will get too much comment here

  • OK, I’ll do it! Thank you!

  • If I may close the question.

  • can close yes

Browser other questions tagged

You are not signed in. Login or sign up in order to post.