[英]Django domain is using example.com even after changing django_site domain and name
I'm using the registration/password_reset.html template which has 我正在使用registration / password_reset.html模板,该模板具有
{{ domain }}
This always returns "example.com". 这总是返回“ example.com”。 I've changed my db django_site domain and name to something like "test.com". 我已将db django_site域和名称更改为“ test.com”之类的名称。 On local testing it works, but in a live environment it doesn't. 在本地测试中,它可以工作,但在实际环境中却不能。
I'm really confused by this, I assume I'm missing something obvious - any suggestions? 我对此感到非常困惑,我想我缺少明显的东西-有什么建议吗?
my problem was this : each user could be assigned to different accounts, so i had to create an instance inside Sites for each account with the correct web address 我的问题是:每个用户都可以分配到不同的帐户,所以我必须在Sites中为每个具有正确网址的帐户创建一个实例
hope this makes sense 希望这有意义
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.