stacklens / dusai-blog

杜赛的博客的评论区。详情见 Issue。
2 stars 0 forks source link

article/42/ #19

Open stacklens opened 4 years ago

stacklens commented 4 years ago

https://www.dusaiphoto.com/article/42/

heyblood commented 4 years ago

博主,我遇到个问题,不知道什么时候错,

当我手动添加文章的在文章列表也显示是正常的,但当我换成网页中复制过来的内容或是用 Faker自动生成内容。

/article/article-list/ 中就会显示很乱,每个文章的卡片都是竖着的(卡片全部在页面的左边,形成一列),而且很长很长,自己找了很久也没发现是哪里的问题。

stacklens commented 4 years ago

博主,我遇到个问题,不知道什么时候错,

当我手动添加文章的在文章列表也显示是正常的,但当我换成网页中复制过来的内容或是用 Faker自动生成内容。

/article/article-list/ 中就会显示很乱,每个文章的卡片都是竖着的(卡片全部在页面的左边,形成一列),而且很长很长,自己找了很久也没发现是哪里的问题。

排版问题吧。去bootstrap官网看布局主题,排查问题

aqqwvfbukn commented 3 years ago

博主,我从后往前点页码会出现 Request URL: http://127.0.0.1:8000/article/article-list/page%3D2 Using the URLconf defined in my_blog.urls, Django tried these URL patterns, in this order:

admin/ article/ article-list/ [name='article_list'] article/ article-detail// [name='article_detail'] article/ article-create/ [name='article_create'] article/ article-delete// [name='article_delete'] article/ article-safe-delete// [name='article_safe_delete'] article/ article-update// [name='article_update'] userprofile/ password-reset/ ^media/(?P.*)$ The current path, article/article-list/page=2, 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.

从前往后点页码就不会出现 ,求指教

stacklens commented 3 years ago

博主,我从后往前点页码会出现 Request URL: http://127.0.0.1:8000/article/article-list/page%3D2 Using the URLconf defined in my_blog.urls, Django tried these URL patterns, in this order:

admin/ article/ article-list/ [name='article_list'] article/ article-detail/int:id/ [name='article_detail'] article/ article-create/ [name='article_create'] article/ article-delete/int:id/ [name='article_delete'] article/ article-safe-delete/int:id/ [name='article_safe_delete'] article/ article-update/int:id/ [name='article_update'] userprofile/ password-reset/ ^media/(?P.*)$ The current path, article/article-list/page=2, 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.

从前往后点页码就不会出现 ,求指教

你看你的 URL 都不对

aqqwvfbukn commented 3 years ago

解决了,是list.html 中 <a href="?page={{ articles.previous_page_number }}" 少了个 “?”,点击上一页时url出错