while-do +array



Hiya,

I have the following code ... which only seems to result in one item ...
which is incorrect ... can anyone spot my problem?

if ($armbase != "") {
$options = explode(",", $armbase);
$text .= '<table ><tr>';
$get_endRow = 0;
$get_columns = 8;
$get_hloopRow1 = 0;

do {
if($get_endRow == 0 && $get_hloopRow1++ != 0) {
$text .= '<tr>';
$text .= '<td valign="top" width="60">';
$text .= "<img
src='".e_BASE."images/options/armbase/".$value."'>";
$text .= '</td>';
$get_endRow++;
}
if($get_endRow >= $get_columns) {
$text .= '</tr>';
$get_endRow = 0;
}
} while(list($key,$value) = each($options));

if($get_endRow != 0) {
while ($get_endRow < $get_columns) {
$text .= '<td>&nbsp;</td>';
$get_endRow++;
}
$text .= '</tr>';
}

$text .= '</table>';

}

The purpose of the code is to create 8 colums and populate based on the
total results returned from the while-do check

Thanks in advance

Steven
.



Relevant Pages

  • Re: Using IF, Then with rowsource?
    ... However a guru like yourself can spot these problems without ... The problem was it didn't populate my combobox. ...
    (microsoft.public.excel.programming)
  • Re: Populate an unbound check box
    ... Dylan Moran wrote: ... > I would like to populate an unbound check box based on a if> then> ... > A little help on why my structure is incorrect would be most welcomed. ...
    (microsoft.public.access.formscoding)
  • Re: I access 2007 easy ?
    ... John's comments are spot on. ... of date" couldn't be more incorrect. ... many developers are still using ... Answers/posts based on Access 2000/2003 ...
    (microsoft.public.access.gettingstarted)
  • Re: Populate an unbound check box
    ... > I would like to populate an unbound check box based on a if> then> else ... > A little help on why my structure is incorrect would be most welcomed. ... unless you use the line continuation characters. ...
    (microsoft.public.access.formscoding)
  • Populate an unbound check box
    ... I would like to populate an unbound check box based on a if> then> else ... A little help on why my structure is incorrect would be most welcomed. ... Prev by Date: ...
    (microsoft.public.access.formscoding)