django: instantiating AdminSite changes not reflected
<p>I am trying to change the templates of admin site, and tried overriding by creating a local template for admin, but failed without knowing why: <a href="http://stackoverflow.com/questions/39132187/django-how-do-i-actually-override-admin-site-template?noredirect=1#comment65613565_39132187">template way</a>. So now I tried to create a instance of AdminSite and make changes from there, but still failed. I have:</p>

<pre><code>urls.py
urlpatterns = [
    url(r'^myadmin/', admin.site.urls),

admin.py
from django.contrib import admin
from .models import Equipment, Calibration, Flag, Tests
from django.contrib.admin import AdminSite

class MyAdminSite(AdminSite):
    site_header = "Equipment Calibration Database"
    site_title = "Equipment Calibration Database"
    index_title = "Equipment Calibration Database"
# Register your models here.
admin_site = MyAdminSite(name = 'myadmin')

admin.site.register(Equipment)
admin.site.register(Calibration)
admin.site.register(Flag)
admin.site.register(Tests)
</code></pre>

<p>Now when I go to <a href="http://127.0.0.1:8000/myadmin/" rel="nofollow">http://127.0.0.1:8000/myadmin/</a>, I still find that none of the text I specified in MyAdminSite is in effect, I still see "Django administration" and "Site administration". </p>

<p>This is all acting really weird and helps are greatly welcome</p>

<p>To change the text in the admin, all you need to add to the <code>admin.py</code> is as follows:</p>

<pre><code>admin.site.site_header = "Equipment Calibration Database"
admin.site.site_title = "Equipment Calibration Database"
admin.site.index_title = "Equipment Calibration Database"
</code></pre>

python django django-admin