@RequestParam 同名参数的处理

spring中的注解@RequestParam,在接收参数的时候,如果有多个参数名相同,则会保留第一个参数的值,后面的会忽略。例如

http://localhost:8080/test.do?a=1&a=2

上面的参数,只会接收a=1.

猜你喜欢

转载自blog.csdn.net/whbing1471/article/details/52782003