我想用这个主题替换 Pinax 的默认主题:https ://github.com/pinax/pinax-theme-bootstrap但我不确定我是否理解快速启动说明。你能给我一些提示吗?
Include "pinax-theme-bootstrap" in your requirements file and "pinax_theme_bootstrap" in your INSTALLED APPS.
这里的需求文件是什么?
Make sure both template loaders and staticfiles finders includes app directories.
我不明白他们的意思。我在文件 settings.py 中看到 STATICFILES_DIRS 和 TEMPLATE_LOADERS,它们意味着我必须将 pinax_theme_bootstrap 目录放在应用程序文件夹中,并包含指向该目录的链接。像这样:
STATICFILES_DIRS = [
os.path.join(PROJECT_ROOT, "media"),
os.path.join(PINAX_ROOT, "media", PINAX_THEME),
os.path.join(PINAX_ROOT, "apps", pinax-theme-bootstrap),
]
TEMPLATE_LOADERS = [
"django.template.loaders.filesystem.load_template_source",
"django.template.loaders.app_directories.load_template_source",
"apps.pinax-theme-bootstrap",
]
Site name comes from Sites fixture.
我完全不明白他们的意思。
Your "site_base.html" should extend "theme_base.html" and should provide "footer" and "nav" blocks (the latter should just be a ul of li of a links).
所以我必须将扩展“theme_base.html”放在“site_base.html”中。如果以前没有的话,应该在“site_base.html”中包含“footer”和“nav”块吗?
Your pages should have blocks "head_title" and "body" and should extend "site_base.html".
所以在我想使用这个主题的任何页面中,我必须有块“head_title”和“body”,并且应该扩展“site_base.html”。如果我有一个已经扩展了“site_base.html”的“base.html”,我是否必须再扩展一次?
The url name "home" should be defined as the homepage.
没有把握。
请给我一些建议,谢谢!