title: Run javascript function instead of posting form laravel
body: <p>I'm trying to run a javascript function when the submit-button on a form is pressed, however instead of running the actual function, the form get posted and the javascript is never executed. I've made sure that the javascript is working by alerting stuff, however this particular function is broken. instead i am redirected to page saying notFoundHttpException. 
  and for a short second, just before redirection, a message is written in the console saying:
  uncaught typeerror: object is not a function</p>
  
  <pre><code>{{ Form::open(array(null, null, 'onsubmit' =&gt; 'comment(this); return false;')); }}
  
  {{ Form::hidden('codesnippet_id', $codesnippet[0]-&gt;id) }}
  {{ Form::textarea('comment', null, array('placeholder'=&gt;'comment')) }}
  {{ Form::submit('comment', null, array('class'=&gt;'comment-knapp'))}}
  {{ Form::close() }}
  </code></pre>