同一 Django 应用程序中的多个域和多个目录
我试图支持一个相当复杂的架构,在同一个 django 应用程序中混合多个域和多个目录。基本上,我们将拥有这样的网址:
http://www.firstdomains.com/(DJANGO_APP)
http://www.firstdomains.com/de/(DJANGO_APP)
http://www.other.com/esp/best/(DJANGO_APP)
http://www.complex.com/it/(DJANGO_APP)
http://www.last.com/(DJANGO_APP)
.... (lot more)
“组合”域/目录将确定主题网站和语言。您认为实现这一目标的最佳方法是什么?
I am trying to support a quite complex architecture with mixed multiple domains and multiple directory in the same django application. Basically, we'll have urls like this :
http://www.firstdomains.com/(DJANGO_APP)
http://www.firstdomains.com/de/(DJANGO_APP)
http://www.other.com/esp/best/(DJANGO_APP)
http://www.complex.com/it/(DJANGO_APP)
http://www.last.com/(DJANGO_APP)
.... (lot more)
The "combo" domain/directory will determine a theme website and a language. What do you think is the best way to implement this ?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
你很幸运! Carl Meyer 最近发布了适合您的完美应用程序:django-hosts
如果由于某种原因 URL 部分不适合您,请尝试添加执行 URL i18n/l10n 的应用程序之一,例如 < a href="http://pypi.python.org/pypi/transurlvania" rel="nofollow noreferrer">http://pypi.python.org/pypi/transurlvania
You are in luck! Carl Meyer recently released the perfect app for you: django-hosts
If for some reason the URL parts don't work for you try also adding one of the apps that do URL i18n/l10n such as http://pypi.python.org/pypi/transurlvania