Maybe you are not including jquery before $(document)

also try $(function(){
      var nome = "";
      var pos = "";
      var html = document.createElement("div");
      $(html).attr("id", "submenu");
});
  ----- Original Message ----- 
  From: Paulo Henrique 
  To: jquery-en@googlegroups.com 
  Sent: Thursday, July 09, 2009 1:45 PM
  Subject: [jQuery] jQuery on IE


  Hello people...
  I've been working with jQuery for some time now, but mostly on Firefox. But i 
was finishing an old project, and needed javascript, so I decided to use jQuery 
on it too.
  It worked perfectly on Firefox, but on IE it ain't working.
  The code is as it follows:

  <script> 
  $(document).ready(function(){
                               var nome = "";
                               var pos = "";
                               var html = document.createElement("div");
                               $(html).attr("id", "submenu");
                              .....
                              });
  </script>

  But the IE complains about the $ before (document), saying that an object is 
expected (object expected at line X character 1).

  Anyone out there could know what might be the reason?
  Waiting for your help, and thanks in advance for your time.


  Att.
  Paulo Henrique Vieira Neves
  Bsc. Sistemas de Informação
  +55 38 9141 5400
  MSN: paulode...@live.com
  GTALK: paulode...@gmail.com
  SKYPE: paulodemoc

Reply via email to