title: Uncaught ReferenceError: function is not defined
body: <p>i have a "a href" tag and when on click this, calling a function but this not working and i receive an error:</p>
  
  <pre><code>Uncaught ReferenceError: Gonder is not defined index.php:10
  onclick 
  </code></pre>
  
  <p>javascript code : </p>
  
  <pre><code>&lt;script type="text/javascript"&gt;  
  $(document).ready(function(){
      function Gonder(nereden, nereye) {
  
         $.ajax({
              type: "POST",
              url: "/ara.php",
              data: '{ "nereden":"' + nereden + '", "nereye":"' + nereye + '" }',
              contentType: 'application/json; charset=utf-8',
              success: function (result) {              
                  $("#sonuc").html(result.d);
  
              },
              error: function (result) {
  
                  $("#sonuc").html(result.d);
  
  
              }
          });
      }
  
  });
  
  
  
  
  &lt;/script&gt;  
  </code></pre>
  
  <p>html code : </p>
  
  <pre><code>&lt;a href="javascript:void(0)" onclick="Gonder(100, 101);" title=""&gt;
  click&lt;/a&gt;
  </code></pre>
  
  <p>not working...</p>