芝麻web文件管理V1.00
编辑当前文件:/home/p/r/i/prismawe/clients/canaldegap.fr_old/lib/adodb_lite/generic_modules/menu_module.inc
'; if($blank1stItem) if(is_string($blank1stItem)) { $barr = explode(':',$blank1stItem); if(sizeof($barr) == 1) $barr[] = ''; $s .= "\n
".$barr[1]."
"; } else $s .= "\n
"; if($this->FieldCount() > 1) $hasvalue=true; else $compareFields0 = true; $value = ''; $optgroup = null; $firstgroup = true; $fieldsize = $this->FieldCount(); while(!$this->EOF) { $zval = rtrim(reset($this->fields)); if($blank1stItem && $zval=="") { $this->MoveNext(); continue; } if($fieldsize > 1) { if(isset($this->fields[1])) $zval2 = rtrim($this->fields[1]); else $zval2 = rtrim(next($this->fields)); } $selected = ($compareFields0) ? $zval : $zval2; $group = ''; if($fieldsize > 2) { $group = rtrim($this->fields[2]); } if($optgroup != $group) { $optgroup = $group; if($firstgroup) { $firstgroup = false; $s .="\n
"; } else { $s .="\n
"; $s .="\n
"; } } if($hasvalue) $value = " value='".htmlspecialchars($zval2)."'"; if(is_array($defstr)) { if(in_array($selected,$defstr)) $s .= "\n
".htmlspecialchars($zval).'
'; else $s .= "\n
'.htmlspecialchars($zval).'
'; } else { if(strcasecmp($selected,$defstr)==0) $s .= "\n
".htmlspecialchars($zval).'
'; else $s .= "\n
'.htmlspecialchars($zval).'
'; } $this->MoveNext(); } // while // closing last optgroup if($optgroup != null) { $s .= "\n
"; } return $s ."\n\n"; } function GetMenu2($name,$defstr='',$blank1stItem=true,$multiple=false,$size=0, $selectAttr='') { return $this->GetMenu($name, $defstr, $blank1stItem, $multiple, $size, $selectAttr, false); } function GetMenu3($name, $defstr='', $blank1stItem=true, $multiple=false, $size=0, $selectAttr='') { $hasvalue = false; if($multiple or is_array($defstr)) { if($size==0) $size=5; $attr = ' multiple size="'.$size.'"'; if(!strpos($name,'[]')) $name .= '[]'; } else if($size) $attr = ' size="'.$size.'"'; else $attr =''; $s = '
'; if($blank1stItem) if(is_string($blank1stItem)) { $barr = explode(':',$blank1stItem); if(sizeof($barr) == 1) $barr[] = ''; $s .= "\n
".$barr[1]."
"; } else $s .= "\n
"; if($this->FieldCount() > 1) $hasvalue=true; else $compareFields0 = true; $value = ''; $optgroup = null; $firstgroup = true; $fieldsize = sizeof($this->fields); while(!$this->EOF) { $zval = rtrim(reset($this->fields)); if($blank1stItem && $zval=="") { $this->MoveNext(); continue; } if($fieldsize > 1) { if(isset($this->fields[1])) $zval2 = rtrim($this->fields[1]); else $zval2 = rtrim(next($this->fields)); } $selected = ($compareFields0) ? $zval : $zval2; $group = ''; if(isset($this->fields[2])) { $group = rtrim($this->fields[2]); } if($optgroup != $group) { $optgroup = $group; if($firstgroup) { $firstgroup = false; $s .="\n
"; } else { $s .="\n
"; $s .="\n
"; } } if($hasvalue) $value = " value='".htmlspecialchars($zval2)."'"; if(is_array($defstr)) { if(in_array($selected,$defstr)) $s .= "\n
".htmlspecialchars($zval).'
'; else $s .= "\n
'.htmlspecialchars($zval).'
'; } else { if(strcasecmp($selected,$defstr)==0) $s .= "\n
".htmlspecialchars($zval).'
'; else $s .= "\n
'.htmlspecialchars($zval).'
'; } $this->MoveNext(); } // while // closing last optgroup if($optgroup != null) { $s .= "\n
"; } return $s ."\n
\n"; } } ?>