This is html:
& lt Form Action = ". /test . PHP " method = " post " & gt;
What language do you like?
& ltbr & gt
& ltinput type = " checkbox " name = " yuyan[]" value = " PHP " & gt; php & ampnbsp& ampnbsp
& ltinput type = " checkbox " name = " yuyan[]" value = " Java " & gt; Java and. nbsp& ampnbsp
& ltinput type = " checkbox " name = " yuyan[]" value =。 net " >; . Network
& ltinput type = " checkbox " name = " yuyan[]" value = " js " & gt; js & ampnbsp& ampnbsp
& ltbr & gt
& ltinput type = " submit " value = " submit " & gt;
& lt/form & gt;
Front-end effect:
This is php:
& lt? Server-side programming language (abbreviation of professional hypertext preprocessor)
$ yuyan = $ _ POST[' yuyan '];
Echo'< pre>';
var _ dump($ yuyan);
Output effect of php after receiving data: