Changeset 183 for trunk/forms.php
- Timestamp:
- Mar 26, 2009, 8:51:40 PM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/forms.php
r179 r183 80 80 $Edit = '<select name="'.$Context.$Index.'">'; 81 81 foreach($FormTypes[$Item['Type']]['States'] as $StateIndex => $StateName) 82 $Edit .= '<option value="'.$StateIndex.'">'.$StateName.'</option>'; 82 { 83 if($this->Values[$Index] == $StateIndex) $Selected = 'selected="selected"'; 84 else $Selected = ''; 85 $Edit .= '<option value="'.$StateIndex.'"'.$Selected.'>'.$StateName.'</option>'; 86 } 83 87 $Edit .= '</select>'; 84 88 break; … … 106 110 global $Database; 107 111 108 $DbResult = $Database->query('SELECT * FROM '.$this->Definition['Table'].' WHEREId='.$Id);112 $DbResult = $Database->query('SELECT T.* FROM '.$this->Definition['Table'].' AS T WHERE T.Id='.$Id); 109 113 $DbRow = $DbResult->fetch_array(); 110 114 foreach($this->Definition['Items'] as $Index => $Item)
Note:
See TracChangeset
for help on using the changeset viewer.