-1

This is the code in question:

url(r'^dreamreals/', ListView.as_view(model = Dreamreal, 
  template_name = "dreamreal_list.html")),
)
Jan
  • 42,290
  • 8
  • 54
  • 79
Rajnish Kumar
  • 75
  • 1
  • 4

1 Answers1

1

url() paths are regular expressions. The ^ character anchors the regular expression to the start of the string. The r prefix to the string literal means that backslashes, etc. are not interpreted (a so-called raw string).

In modern Django, you'd probably want to use path() instead of url() (which is called re_path() these days).

AKX
  • 152,115
  • 15
  • 115
  • 172