Jump to content

Page Not Found (404) Error On Django


sgjava

Recommended Posts

I've created a DJango Project named "djangotest" and 2 DJango Apps named "admin_tools" and "test" (following HelioHost instructions). My "test" app is working but "admin_tools" app is showing the following error:

Page not found (404)

Request Method:

GET

Request URL: http://sgjava.tk/djangotest/dispatch.wsgi/

Using the URLconf defined in urls, Django tried these URL patterns, in this order:

1. ^admin_tools/

The current URL, djangotest/dispatch.wsgi/, didn't match any of these. You're seeing this error because you have DEBUG = True in your Django settings file. Change that to False, and Django will display a standard 404 page.

Directories

I've the following directories:

+ djangotest (projects dir)

- admin_tools (app dir)

- test (app dir)

- __init__.py

- dispatch.wsgi

- settings.py

- urls.py

- .htaccess

Contents of urls.py

from django.conf.urls.defaults import *

urlpatterns = patterns('',
(r'^admin_tools/', include('admin_tools.urls')),
)

Please help me to solve the problem

Link to comment
Share on other sites

I've created a DJango Project named "djangotest" and 2 DJango Apps named "admin_tools" and "test" (following HelioHost instructions). My "test" app is working but "admin_tools" app is showing the following error:

Page not found (404)

Request Method:

GET

Request URL: http://sgjava.tk/djangotest/dispatch.wsgi/

Using the URLconf defined in urls, Django tried these URL patterns, in this order:

1. ^admin_tools/

The current URL, djangotest/dispatch.wsgi/, didn't match any of these. You're seeing this error because you have DEBUG = True in your Django settings file. Change that to False, and Django will display a standard 404 page.

The URL of the DJango app: http://www.sgjava.tk/djangotest/

Directories

I've the following directories:

+ djangotest (projects dir)

- admin_tools (app dir)

- test (app dir)

- __init__.py

- dispatch.wsgi

- settings.py

- urls.py

- .htaccess

Contents of urls.py

from django.conf.urls.defaults import *

urlpatterns = patterns('',
(r'^admin_tools/', include('admin_tools.urls')),
)

Please help me to solve the problem

Link to comment
Share on other sites

I've created a DJango Project named "djangotest" and 2 DJango Apps named "admin_tools" and "test" (following HelioHost instructions). My "test" app is working but "admin_tools" app is showing the following error:

Page not found (404)

Request Method:

GET

Request URL: http://sgjava.tk/djangotest/dispatch.wsgi/

Using the URLconf defined in urls, Django tried these URL patterns, in this order:

1. ^admin_tools/

The current URL, djangotest/dispatch.wsgi/, didn't match any of these. You're seeing this error because you have DEBUG = True in your Django settings file. Change that to False, and Django will display a standard 404 page.

The URL of the DJango app: http://www.sgjava.tk/djangotest/

Directories

I've the following directories:

+ djangotest (projects dir)

- admin_tools (app dir)

- test (app dir)

- __init__.py

- dispatch.wsgi

- settings.py

- urls.py

- .htaccess

Contents of urls.py

from django.conf.urls.defaults import *

urlpatterns = patterns('',
(r'^admin_tools/', include('admin_tools.urls')),
)

Please help me to solve the problem

Link to comment
Share on other sites

I've created a DJango Project named "djangotest" and 2 DJango Apps named "admin_tools" and "test" (following HelioHost instructions). My "test" app is working but "admin_tools" app is showing the following error:

Page not found (404)

Request Method:

GET

Request URL: http://sgjava.tk/djangotest/dispatch.wsgi/

Using the URLconf defined in urls, Django tried these URL patterns, in this order:

1. ^admin_tools/

The current URL, djangotest/dispatch.wsgi/, didn't match any of these. You're seeing this error because you have DEBUG = True in your Django settings file. Change that to False, and Django will display a standard 404 page.

The URL of the App: http://www.sgjava.tk/djangotest/

Directories

I've the following directories:

+ djangotest (projects dir)

- admin_tools (app dir)

- test (app dir)

- __init__.py

- dispatch.wsgi

- settings.py

- urls.py

- .htaccess

Contents of urls.py

from django.conf.urls.defaults import *

urlpatterns = patterns('',
(r'^admin_tools/', include('admin_tools.urls')),
)

Please help me to solve the problem

Link to comment
Share on other sites

  • 2 weeks later...

Here is my .htaccess contents:

RewriteEngine On

RewriteBase /

RewriteRule ^(test/media/.*)$ - [L]

RewriteRule ^(test/admin_media/.*)$ - [L]

RewriteRule ^(dispatch\.wsgi/.*)$ - [L]

RewriteRule ^(.*)$ djangotest/dispatch.wsgi/$1 [QSA,PT,L]

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...