当前位置:网站首页>thymeleaf如何取url中请求参数值?
thymeleaf如何取url中请求参数值?
2022-06-23 09:48:00 【Roc-xb】
需求:例如请求url链接为:http://localhost:8080/community/service?cid=1
如何取到url中的cid参数值呢?
一、HTML取值
<span th:text="${param.cid}"></san>或者
<span>[[${param.cid}]]</span>二、 JS取值
<script>
let cid=[[${param.cid}]];
console.log(cid);
</script>边栏推荐
猜你喜欢

Pet Feeder Based on stm32

Pizza ordering design - simple factory model

Lu Qi invests in quantum computing for the first time

J. Med. Chem. | Release: a new drug design model for deep learning based on target structure

Typora set up image upload service

UEFI learning 3.6 - ACPI table on ARM QEMU

Build a security video monitoring platform using Huawei cloud ECS server

ICLR 2022 | 视频中的动态卷积TAdaConv以及高效的卷积视频理解模型TAdaConvNeXt
![[SUCTF 2019]CheckIn](/img/0e/75bb14e7a3e55ddc5126581a663bfb.png)
[SUCTF 2019]CheckIn

基于STM32设计的宠物投喂器
随机推荐
[SUCTF 2019]CheckIn
xml相关面试题
高性能算力中心 — InfiniBand — Overview
UEFI learning 3.6 - ACPI table on ARM QEMU
Go语言JSON 处理
UEFI 学习3.6 - ARM QEMU上的ACPI表
High performance computing center nvme / nvme of nvme of overview
多线程习题
CVPR大会现场纪念孙剑博士,最佳学生论文授予同济阿里,李飞飞获黄煦涛纪念奖...
A 32KB cache with direct mapping Memory exercises after class
陆奇首次出手投资量子计算
汇编语言中断及外部设备操作篇--06
[网鼎杯 2020 青龙组]AreUSerialz
我被提拔了,怎么和原来平级的同事相处?
天龙八部TLBB系列 - 网单服务端各目录文件说明【超详细】
Learn SCI thesis drawing skills (f)
快速排序的简单理解
135,137,138,445禁用导致无法远程连接数据库
Thin film interference data processing
[MRCTF2020]Ez_ bypass