PHP checkbox problem - How to handle value with white spaces in between?

parixit

New member
<input type="checkbox" name="checkbox[]" value=Graphics Design>
<span class="style2">Graphics Design</span>
<input type="checkbox" name="checkbox[]" value=Digital 2D>
<span class="style2">Digital 2D</span>
<input type="checkbox" name="checkbox[]" value=Architectural 3D>
<span class="style2">Architectural 3D </span>
<input type="checkbox" name="checkbox[]" value=Maya With Specialization>
<span class="style2">Maya With Specialization</span>



php script
<?php
$interestedin=$_POST['checkbox'];
if(empty($interestedin))
{
print("What are you interested in?");
}
else
{
$N = count($interestedin);

echo("You selected $N : ");
for($i=0; $i < $N; $i++)
{
echo(($interestedin[$i].value). " ");
}
}
?>

When chekboxes are checked, and i print array, only content before white space appears.. i.e. Graphis Digital Architectural Maya..
How can i modify code to print complete value with spaces in between ??
or any alternative ??
 
Back
Top