Home > Web Front-end > Bootstrap Tutorial > Let's talk about how to import bootstrap into jsp pages

Let's talk about how to import bootstrap into jsp pages

青灯夜游
Release: 2021-02-07 18:24:03
forward
3283 people have browsed it

Let's talk about how to import bootstrap into jsp pages

Related recommendations: "bootstrap Tutorial"

1. First import the following three files into WebContent (go to the official website to download by yourself: bootstrap##,jQuery

2. Create a new .jsp file, such as index.jsp , now import the following files into the tag, be careful not to reverse the order

<script src="${pageContext.request.contextPath }/js/jquery-3.3.1.min.js"></script>
<link href="${pageContext.request.contextPath }/css/bootstrap.min.css"  rel="stylesheet">
<script src="${pageContext.request.contextPath }/js/bootstrap.min.js"></script>
Copy after login

3. Then you can use boostrap, just add "class" to the tag. You can go

here Choose the style you want

<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>




Insert title here
<script src="${pageContext.request.contextPath }/js/jquery-3.3.1.min.js"></script>
<link href="${pageContext.request.contextPath }/css/bootstrap.min.css"  rel="stylesheet">
<script src="${pageContext.request.contextPath }/js/bootstrap.min.js"></script>


    
id username password
1 李疆 111
2 李二 222
3 张三 333
Copy after login

4. Run the results

For more programming-related knowledge, please visit:

Programming Teaching! !

The above is the detailed content of Let's talk about how to import bootstrap into jsp pages. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Latest Issues
There is no bootstrap custom video tutorial
From 1970-01-01 08:00:00
0
0
0
Laravel: Problem using bootstrap locally
From 1970-01-01 08:00:00
0
0
0
html5 - Problem with bootstrap modifying style
From 1970-01-01 08:00:00
0
0
0
Introducing bootstrap is invalid
From 1970-01-01 08:00:00
0
0
0
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template