title: Django prevent page caching
body: <p><strong>strong text</strong>I am trying to prevent a page being cached as I dont want the user to be able to resubmit a form which has already been saved to the db.</p>
  
  <p>I tried the following in views.py</p>
  
  <pre><code>class ServiceCreate(LoginRequiredMixin, CreateView):
      model = Service
      form_class = ServiceCreateForm
  
      @method_decorator(never_cache)
      def dispatch(self, request, *args, **kwargs):
          return super(ServiceCreate, self).dispatch(request, *args, **kwargs)
  </code></pre>
  
  <p>However, this has no effect as the entire page is shown instantly when the user hits the back button. How can I prevent caching please?</p>
  
  <p><strong>Update</strong>
  I'm new to Django so thought that the decorator would instruct the browser not to cache - I did not appreciate that there was server caching as well.</p>