首页 > 解决方案 > 错误:在加载动态页面之前显示 html 内容的几分之一秒

问题描述

我在 Eclipse 中的项目中有问题。我有动态 Web 项目,其中包含 jsp、html 和 javascript 文件。在加载带有 js 和 CSS 广告的实际 html 内容之前,它会在几分之一秒内显示 html 内容。我在代码中找不到问题。有什么我遗漏的吗?这是我包含所有 css 和 js 文件的顺序:

<html>
<head>
<style><%@include file="/WEB-INF/style.css"%></style>
<style><%@include file="/WEB-INF/jquery-ui.css"%></style>
<style><%@include file="/WEB-INF/jqueryui-com.css"%></style>
<script src="https://code.jquery.com/jquery-3.5.1.min.js" integrity="sha256-9/aliU8dGd2tb6OSsuzixeV4y/faTqgFtohetphbbj0=" crossorigin="anonymous"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/jqueryui/1.12.1/jquery-ui.min.js" integrity="sha256-KM512VNnjElC30ehFwehXjx1YCHPiQkOPmqnrWtpccM=" crossorigin="anonymous"></script>
<script type="text/javascript" src="${pageContext.request.contextPath}/js/file.js"></script>
</head>

标签: javahtmlcssjsp

解决方案


推荐阅读