我将在entworks.in
主持我的网站该网站似乎工作正常,直到我尝试获取404错误,如entworks.in/asdf< - 将给404.之后当我尝试加载其他页面,如entworks.in时,它显示404对于所有页面。
任何人都知道可能是什么问题?我在nginx上运行它。
编辑:
from django.conf.urls import patterns, include, url
from django.contrib import admin
admin.autodiscover()
from haystack.forms import ModelSearchForm
from haystack.query import SearchQuerySet
from haystack.views import search_view_factory
import bootlog.views
from bootlog.views import BSearchView
urlpatterns = patterns('',
url(r'^about/', 'bootlog.views.profile_view', name='about'),
url(r'^e/', 'bootlog.views.engineering_view', name='engineering'),
url(r'^d/', 'bootlog.views.programming_view', name='programming'),
url(r'^s/',search_view_factory(
view_class=BSearchView,
template='bootlog/base.html',
searchqueryset = SearchQuerySet(),
form_class=ModelSearchForm
), name='haystack_search'),
url(r'^ckeditor/',include('ckeditor.urls')),
url(r'^$',bootlog.views.front_page_view),
url(r'^p/b(?P<blog_pk>\d+)p(?P<post_pk>\d+)/', bootlog.views.perma_post, name="blog-post"),
url(r'^rss/$', bootlog.views.LatestEntriesFeed(), ),
url(r'^all/',bootlog.views.html_render),
)
handler404='bootlog.views.view_404'
我正在使用gunicorn
编辑2:我以错误的方式显示404页面。因此错误。它覆盖了主配置。