Django url problem
I'm getting this error
error at /
unknown sp开发者_如何学Goecifier: ?P&
and I suppose it's coming from this line
(r'^(?P<template>\w+)/$', static_page),
I copied this from a tutorial, how do I fix this error ?
You want to use
r'^(?P<template>\w+)/$'
for your regex. You seem to have copied the regex with HTML entities still encoded; the regex engine expects verbatim <
and >
.
精彩评论