title: little bit confuse in dgetting absolute url in django
body: <pre><code>#project url
  
  from django.conf import settings
  from django.conf.urls import url
  from django.conf.urls.static import static
  from django.contrib import admin
  from django.urls import path, include
  
  import products
  
  urlpatterns = [
      path('admin/', admin.site.urls),
      path('', include('products.urls')),
      url(r'^product/(?P&lt;title&gt;[\w-]+)/$', products.views.single,name='single')
  
  
  
  ]
  
  # app url
  from django.urls import path, include
  
  import products
  from . import views
  
  urlpatterns = [
      path('', views.home, name='home'),
  
  ]
   #model
  class products(models.Model):
      title = models.CharField(max_length=120)
      desc = models.TextField()
      price = models.DecimalField(max_digits=10, decimal_places=2, default=29.99)
      sales_price = models.DecimalField(max_digits=10, decimal_places=2, blank=False, null=False, default=0)
      slug = models.SlugField(unique=True)
      timestamp = models.DateTimeField(auto_now_add=True, auto_now=False)
      update = models.DateTimeField(auto_now_add=False, auto_now=True)
      active = models.BooleanField(default=True)
  
      def __str__(self):
          return self.title
  
      def get_price(self):
          return self.price
  
      def get_absolute_url(self):
          return reverse("single", kwargs={"title": self.title})
  #views
  def home(request):
      product = products.objects.all()
      template = 'home.html'
  
      context = {'product': product}
  
      return render(request, template, context)
  
  def single(request,title):
      try:
          product = products.objects.get(title=title)
          template = 'products.html'
          context = {'product': product}
          return render(request, template, context)
      except:
          raise Http404
  </code></pre>
  
  <p>plz view my code .. i m littlebit confuse in absolute url.. it returns title of the product after clicking some link but it doesnt give me the title if i change produc to other. for eg:http:/127.0.0.1:8000/product/T-shirt/ gives title but wheni hit http:/127.0.0.1:8000/productS/T-shirtgives eroror</p>