title: How can i add a onchange js event to Select widget in Django?
body: <p>I need to attach a JavaScript <strong>onchange event</strong> to the <strong>receipt dropdown list</strong> in a Django project. When the value of the dropdown list is changed a JavaScript function is to be called. How can it be done? The <strong>form.py</strong> file is given below</p>
  
  <pre><code>from django import forms
  receipt_types=(('option1','Option 1'),('option2','Option 2'),('option3','Option 3'),)
  class accountsInForm(forms.Form):
      receipt=forms.CharField(max_length=100, widget=forms.Select(choices=reciept_types))
  </code></pre>