Thorsten Sanders
unread,Jan 29, 2015, 3:25:32 PM1/29/15Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Sign in to report message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to django...@googlegroups.com
Hello,
writing currently an app which should show different things based on
namespace which is working already, but I do have problems with
generating the right url inside the templates of that app.
I tried to use:
{% url 'myaddons:index' %}
but that always shows the same namespace url the last one attached.
Currently have defined inside that app:
urlpatterns = patterns('',
url(r'^$', 'myaddons.views.index', name='index'),
)
Then have 2 other apps in one I define:
urlpatterns = patterns('',
url(r'^addons/', include('myaddons.urls',
namespace='wow-myaddons', app_name='myaddons')),
)
in the other one:
urlpatterns = patterns('',
url(r'^addons/', include('myaddons.urls', namespace='ws-myaddons',
app_name='myaddons')),
)
The base one is:
url(r'^wow/', include('warcraft.urls')),
url(r'^ws/', include('wildstar.urls')),
With what I tried it always resolve to:
/ws/addons/
I want it to resolve to:
/wow/addons/ if called with /wow/
and
/ws/addons/ if called with /ws/
Greetings,
Thorsten