How to handle long data when displaying it in html

How to handle long data when displaying it in html
When displaying long data in HTML, you can cut off the data and display the complete data when the mouse moves over it.
For example, consider the following situation.

accomplish:

Copy code
The code is as follows:

<a title="${siteBoardInfoList.boardUrl}">
<c:if test="${fn:length(siteBoardInfoList.boardUrl) >= 40}">
${fn:substring(siteBoardInfoList.boardUrl,0,20)}......${fn:substring(siteBoardInfoList.boardUrl,fn:length(siteBoardInfoList.boardUrl)-21,fn:length(siteBoardInfoList.boardUrl))}
</c:if>
<c:if test="${fn:length(siteBoardInfoList.boardUrl) < 40}">
${siteBoardInfoList.boardUrl}
</c:if>
</a>

<<:  How to implement digital paging effect code and steps in CSS

>>:  Summary of the dockerfile-maven-plugin usage guide

Recommend

How to install Zookeeper service on Linux system

1. Create the /usr/local/services/zookeeper folde...

How to use nginx to intercept specified URL requests through regular expressions

nginx server nginx is an excellent web server tha...

Solution to the problem that Java cannot connect to MySQL 8.0

This article shares a collection of Java problems...

js to implement the snake game with comments

This article example shares the specific code of ...

Detailed explanation of the role of key in React

Table of contents Question: When the button is cl...

A brief discussion on this.$store.state.xx.xx in Vue

Table of contents Vue this.$store.state.xx.xx Get...

Linux yum package management method

Introduction yum (Yellow dog Updater, Modified) i...

How to Rename Multiple Files at Once in Linux

Preface In our daily work, we often need to renam...

Design Theory: Ten Tips for Content Presentation

<br /> Focusing on the three aspects of text...

Div css naming standards css class naming rules (in line with SEO standards)

There are many tasks to be done in search engine o...

Docker setting windows storage path operation

When installing Docker on Windows 10, after selec...