Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6695453
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T06:13:25+00:00 2026-05-26T06:13:25+00:00

These urls work: /admin /admin/appname But this does not work for any model, including

  • 0

These urls work:

/admin
/admin/appname

But this does not work for any model, including users, groups, or sites:

/admin/appname/modelname

For example, /admin/auth works and shows the Groups, and Users models, but if I click on either model, navigating to admin/auth/user, I receive a 404 not found error.

I first assumed that it was probably a problem in urls.py so I commented out everything out besides the admin. It made no difference. Here’s my urls.py file:

from django.conf.urls.defaults import *
from django.contrib import admin

urlpatterns = patterns('',
    # main admin
    (r'^admin/', include(admin.site.urls)),
)
admin.autodiscover()

Here’s my installed apps, in settings.py:

INSTALLED_APPS = (
    'django.contrib.auth',
    'django.contrib.contenttypes',
    'django.contrib.sessions',
    'django.contrib.sites',
    'django.contrib.messages',
    'django.contrib.staticfiles',
    'django.contrib.admin',
    'south',
)

I have of course already tried shutting down the server, running syncdb, (as well as running south migrations for apps that were using south), and using runserver again. It makes no difference.

I also tried uninstalling and reinstalling django (same version, 1.3).

Django tried these URL patterns, in this order:

  1. ^admin/ ^$ [name='index']
  2. ^admin/ ^logout/$ [name='logout']
  3. ^admin/ ^password_change/$ [name='password_change']
  4. ^admin/ ^password_change/done/$ [name='password_change_done']
  5. ^admin/ ^jsi18n/$ [name='jsi18n']
  6. ^admin/ ^r/(?P<content_type_id>\d+)/(?P<object_id>.+)/$
  7. ^admin/ ^(?P<app_label>\w+)/$ [name='app_list']

The current URL, admin/auth/user/, didn’t match any of these.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-26T06:13:25+00:00Added an answer on May 26, 2026 at 6:13 am

    As I mentioned in my comment, you apparently need to have the admin.autodiscover() line before the place where you include it in the urlpatterns tuple.

    This seems to be because the code that calculates the urls for each app/model – admin.sites.AdminSite.get_urls – depends on the models already being registered for the admin before it runs. If not, the relevant URLs are not created.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I've been getting this error: The requested admin page does not exist. I've got
I have already have this code to force these URLs to HTTPS: RewriteCond %{HTTPS}
I have read several tutorials, but I just can't this to work. My apache
I am sure this is a basic answer, but my search powers are not
I'm trying to write a python regular expression that will match both these URLs:
Is there any difference in using login_required decorator in urls.py and in views.py ?
I work on two sites hosted on the same server, using the same CMS
I want to redirect these URLs: http://example.com/search to http://example.com/?page=search http://example.com/search?q=keyword to http://example.com/?page=search&q=keyword I am
I have these types of urls: /city/ /city/category/ /city/category/subcategory/ All of the urls are
I must be missing something obvious, but I can't make it work I want

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.