一个简单的即时通信板——Springboot-java8

项目结构

在这里插入图片描述

前台界面

<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org">
<head>
    <!--放在templates文件夹下-->
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>即时通信板</title>
    <link href="https://cdn.bootcdn.net/ajax/libs/twitter-bootstrap/5.3.3/css/bootstrap.css" rel="stylesheet">
    <style>
        body {
     
            background: linear-gradient(to right, #a8edea, #fed6e3);
            color: #ffffff;
            font-family: Arial, sans-serif;
        }
        .container {
     
            background: rgba(255, 255, 255, 0.2);
            padding: 20px;
            border-radius: 10px;
            box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
        }
        #messages {
     
            height: 400px;
            overflow-y: auto;
            padding: 10px;
            border: 1px solid #ccc;
            border-radius: 5px;
            margin-bottom: 10px;
            background-color: rgba(255, 255, 255, 0.1);
            color: #000;
            border-radius: 5px;
            box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
        }
        .message {
     
            padding: 5px;
            margin-bottom: 5px;
            border-radius: 5px;
        }
        .message-sent {
     
            background-color: #e9f7eb;
            color: #28a745;
            text-align: right;
        }
        .message-received {
     
            background-color: #cce5ff;
            color: #007bff;
            text-align: left;
        }
        #messageInput {
     
            border-color: #ced4da;
            border-radius: 5px;
            color: #000;
        }
        #messageInput:focus {
     
            border-color: #80bdff;
            box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
        }
        .btn-send {
     
            border-radius: 5px;
        }
        .input-group-text {
     
            color: #007bff;
            background-color: rgba(255, 255, 255, 0.2);
            border-color: #ced4da;
            border-radius: 5px;
        }
        .input-group-text::after {
     
            color: #ffffff;
        }
    </style>
</head>
<body>
<div class="container mt-5">
    <div><h3>即时通信板</h3></div>
    <div id="messages" class
  • 2
    点赞
  • 3
    收藏
    觉得还不错? 一键收藏
  • 打赏
    打赏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

_长银_

有用的话给作者打赏个棒棒糖吧

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值