该网页显示的路径没有 CSS:“/articles/int:article_id/”和“/articles/int:article_id/update”。对于所有其他页面,CSS 正在加载。感谢您的帮助
@app.route('/articles/<int:article_id>/')
@login_required
def article(article_id):
article = Article.query.get_or_404(article_id)
return render_template('article.html', title='Artikel', article=article)
---------------------------------------------------------------------------------------------------------
{% extends 'layout.html' %}
{% block content %}
(...)
{% endblock content %}
布局.html
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title></title>
<meta name="keywords" content="" />
<meta name="description" content="" />
<link href='http://fonts.googleapis.com/css?family=Pontano+Sans' rel='stylesheet' type='text/css' />
<link href="../static/css/default.css" rel="stylesheet" type="text/css" media="all" />
<link href="fonts.css" rel="stylesheet" type="text/css" media="all" />
<!--[if IE 6]><link href="default_ie6.css" rel="stylesheet" type="text/css" /><![endif]-->
</head>
<body>
<div id="header-wrapper">
<div id="header" class="container">
<div id="menu">
<ul>
<li class="current_page_item"><a href="{{ url_for('home') }}" accesskey="1" title="">Home</a></li>
<li><a href="{{ url_for('new_article') }}" accesskey="2" title="">Tracken</a></li>
<li><a href="{{ url_for('articles') }}" accesskey="3" title="">Artikel</a></li>
<li><a href="#" accesskey="4" title="">Profil</a></li>
<li><a href="{{ url_for('logout') }}" accesskey="5" title="">Logout</a></li>
</ul>
</div>
</div>
</div>
{% block content %} {% endblock %}
慕无忌1623718
相关分类