title: Django: How to make buttons disappear/disabled after pushed?
body: <p>I want to create a like/dislike button system in Django, but don’t know how to do the final part of it, namely, making the button disappear/change to the compliment of the button that was pushed. 
  Basically, I want to have a "like" button on my template and once it is pushed, then I want the like button to disappear/switch to an “unlike” button so that the user can undo their like if they wish, similar to facebook. How can I go about doing this? </p>
  
  <p>Here’s my template code for the button (the hidden part is used to figure out which post the like button belongs to):</p>
  
  <pre><code>&lt;form action="#" method="get"&gt;
   &lt;input type="hidden" value="{{postset.id}}" name="postset_id" size="1"/&gt;
   &lt;input type="submit" class="btn" value="+1" name="postlikebtn"&gt;
   &lt;/form&gt;
  </code></pre>
  
  <p>Here’s my simple views.py for this button (I’m using the djangoratings app for managing the votes so that’s what my code is referencing on the last line):</p>
  
  <pre><code>if (request.GET.get('postlikebtn')):
          postid = request.POST['postset_id'] #get the ID of the post that was liked
         c = newpost.objects.get(id=postid) #getting the post
         c.rating.add(score=1, user=request.user, ip_address=request.META['REMOTE_ADDR']) #add a vote
  </code></pre>
  
  <p>So what can I add to basically make the button disappear when pushed? And then ideally replace it with another button, the “unlike” button?
  Thanks in advance! </p>