title: jQuery click(function() not working but plain Javascript working just fine
body: <p>THIS IS THE FULL SCRIPT</p>
  
  <p><a href="http://goo.gl/HoCxk" rel="nofollow">http://goo.gl/HoCxk</a></p>
  
  <p>I have a problem with this function:</p>
  
  <pre><code>    $('.message').click(function(){
      alert("it works");
      var clicked_msg=$(this);
      $('#current_message').html(clicked_msg.attr("id"));
  });
  </code></pre>
  
  <p>If instead of the above I add an onclick="msgClicked()", and then do something like this:</p>
  
  <pre><code>function msgClicked(){
  var x=document.getElementById("current_message");alert("it works");x.innerHTML("test");}
  </code></pre>
  
  <p>The jQuery library is obviously imported as literally everything else is done using the jQuery framework and all the other functions implemented on the messaging system are jQuery. Everything works perfect there but for some reason I can't figure out what is wrong with this one.</p>
  
  <p>If any of you are willing to help out and you need to see what is actually going on, please let me know and I will create an account for you on my website. Removing all the protection from the content would take a looong long time.</p>