1๐
โ
I deleted my previous answer, my apologies. You should make your life easy and restructure your url
path('wiki/edit/<str:entry>', views.edit, name="edit")
<button href="{% url 'edit' entry=entryTitle %}"></button>
This should work.
The previous way was:
path('wiki/<str:entry>/edit', views.edit, name="edit')
I get the error message:
Reverse for 'edit' with keyword arguments '{'entry': ''}' not found. 1 pattern(s) tried: ['so/wiki/(?P<entry>[^/]+)/edit$']
Iโm not sure why, but its something to do with it being an object, because passing in a hardcoded string "maggie"
instead of entryTitle
works fine. Sorry for all the confusion.
๐คsin tribu
Source:stackexchange.com