Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums Back End [Solved] Need Help with PHP code for using an array checkbox Re: [Solved] Need Help with PHP code for using an array checkbox

#63780
holyhttp
Member

$rooms=$_POST;
$roomchoice=”;
foreach($rooms as $key=>$value){
if($roomchoice!=”){ $roomchoice.=’, ‘; }
$roomchoice.=$value;
}

That will display all the selected values in a string separated by a comma.