摘要: 阅读全文
posted @ 2022-04-05 16:34 小白龙白龙马 阅读(90) 评论(0) 推荐(0)
摘要: html网页post方式提交数据: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <title>Title</title> </head> <body> 阅读全文
posted @ 2022-04-05 15:54 小白龙白龙马 阅读(304) 评论(0) 推荐(0)
摘要: web网页post提交数据: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <title>Title</title> </head> <body> <fo 阅读全文
posted @ 2022-04-05 15:28 小白龙白龙马 阅读(243) 评论(0) 推荐(0)
摘要: html中post方式: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <title>Title</title> </head> <body> <form 阅读全文
posted @ 2022-04-05 15:11 小白龙白龙马 阅读(144) 评论(0) 推荐(0)
摘要: html页面中post方式提交数据: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <title>Title</title> </head> <body> 阅读全文
posted @ 2022-04-05 14:40 小白龙白龙马 阅读(386) 评论(0) 推荐(0)
摘要: 创建Bean对象: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 package com.awaimai.web; public class Student { private String fi 阅读全文
posted @ 2022-04-05 13:55 小白龙白龙马 阅读(178) 评论(0) 推荐(0)
摘要: 通过HttpServletRequest来获取前端页面参数,代码见下图 ,简单来说就是通过调用request的getParameter方法来获取参数 这种方式也可以获取表单参数,一般get和post请求都可以。此处只演示get请求。 控制器: 1 2 3 4 5 6 7 8 9 10 11 12 1 阅读全文
posted @ 2022-04-05 13:24 小白龙白龙马 阅读(152) 评论(0) 推荐(0)
摘要: 通过URL传递参数与上面的URL不同,上面的URL中均需写明参数名和对应参数值,这里的URL传递参数,仅需要在地址栏输入参数值,然后后台自动匹配到对应的参数名。 springMVC通过使用处理器映射和@PathVariable注解的组合来获取URL参数。 首先通过处理器映射可以定位参数的位置和名称, 阅读全文
posted @ 2022-04-05 13:00 小白龙白龙马 阅读(1081) 评论(0) 推荐(0)
摘要: package com.bulunzhihao.web; import org.springframework.web.bind.annotation.*; import java.util.HashMap; import java.util.Map; @RestController public 阅读全文
posted @ 2022-04-05 12:28 小白龙白龙马 阅读(242) 评论(0) 推荐(0)