をロードジャンゴません。(127.0.0.1:8000/catalog/)は、なぜ私はサイトをロードしようとしたとき、私は「ページが見つかりません」というエラーを取得する私の見解
をここに私urls.pyは
ですurlpatterns = patterns('',
(r'^catalog/$', 'preview.views.home'),
# Example:
# (r'^ecomstore/', include('ecomstore.foo.urls')),
# Uncomment the admin/doc line below to enable admin documentation:
# (r'^admin/doc/', include('django.contrib.admindocs.urls')),
# Uncomment the next line to enable the admin:
# (r'^admin/', include(admin.site.urls)),
)
とパッケージプレビューに私のviews.py
from django.shortcuts import render_to_response
# Create your views here.
def home(request):
return render_to_response("index.html")
"index.htmlには、" フォルダecomstore /テンプレートである、変数TEMPLATE_DIRSがこのディレクトリに設定されています。
奇妙なことに私はデバッグトレースを取得していませんが、DEBUG変数がtrueに設定されています 何が間違っているのか分かりますか?
あなたの設定に 'debug'が有効になっている場合は、あなたのエラーページにトレースバックが必要です。 –
Django開発サーバーはどのように起動しましたか?起動時に出力されたものは何ですか? –
あなたの 'hosts'ファイルが表示しているものを投稿できますか? linux/macの場合は '/ etc/hosts'、Windowsの場合は' C:\ Windows \ system32 \ drivers \ etc \ hosts'です –