What's the point of having hidden input in HTML? What are common uses for this?

后端 未结 12 1162
无人共我
无人共我 2020-12-01 14:51

I don\'t see the benefit of having hidden input? If you set the value of the hidden input why not just use that value at the point where you reference this hidden input?

12条回答
  •  暗喜
    暗喜 (楼主)
    2020-12-01 15:10

    because you have a php while loop with alot of different objects which you can't get the id's of later and you just save them by storing them in the hidden input... also i like them to be a security check to know my users aren't messing with my post variables through tamper data

提交回复
热议问题