Generated Table Output:
Generated HTML Code: My Source Code:
Code: Select all
foreach($connectData as $key => $value) {
$k[]=$key;
$v[]=$value;
if($key=='Name_ID') {
continue;
};
printf("<td><label for='%s'>%s</label></td>\n",strtolower($key), preg_replace("/_/"," ",$key));
if($key=="Display_Name") {
printf("<td><input type='text' name='%s' onfocus='showDisplayName($v[1], $v[2]);'
id='%s' value='%s'></input></td></tr>\n", strtolower($key), strtolower($key), $value);
continue;
};
if (contains($key, "Notes")) {
printf("<td><textarea name='%s' id='%s' rows=5 cols=81> '%s' </textarea></td></tr>\n",strtolower($key),
strtolower($key), $value);
continue;
};
printf("<td><input type='text' name='%s' id='%s' value='%s'></input></td></tr>\n", strtolower($key), strtolower($key), $value);
}; // if key
printf("</table></form></fieldset></div>\n");