<?php 
$statuses = GetStatuses();
foreach ($statuses as $status) {
    echo "<option value=\"{$status['status_id']}\">{$status['name']}</option>";
}
?>
		</select>
		</td></tr>
		<tr><td class="right">Primary MOS:</td><td class="left"><input type="text" name="primmos" value="" /></td></tr>
		<tr>
			<td class="right">Role:</td>
			<td class="left">
			<select name="role">
				<option value="0">---SELECT-POSITION---</option>
<?php 
$groups = GetRoles();
decho($groups);
foreach ($groups as $group) {
    echo "<optgroup label=\"{$group['name']}\">";
    foreach ($group['roles'] as $role) {
        echo "<option value=\"{$role['role_id']}\">{$role['name']}</option>";
    }
    echo "</optgroup>";
}
?>
				</select>
			</td>
		</tr>
		<tr>
			<td class="right" style="font-weight:bold;">Unit:</td>
			<td class="left">
Beispiel #2
0
function GetRolesByOnline($var, $gm)
{
    return GetRoles($var, $gm, "online");
}