Ejemplo n.º 1
0
					<option value='0' disabled selected>Ciudad</option>
					<?php 
foreach ($ciudad->findAll() as $c) {
    ?>
						<option value='<? echo $c['id']; ?>' <? if($c['id']==$_SESSION['id_ciu']) echo "selected"; ?>><? echo $c['nom']; ?></option>
					<?php 
}
?>
					</select>
				<label for='id_ciu'>Ciudad:</label>
			</div>
			<div class="input-field col s6" >
				<select class='tableInput' name='id_dep' id='id_dep' required>
					<option value='0' disabled selected>Departamento</option>
					<?php 
foreach ($departamento->findAll() as $d) {
    ?>
						<option value='<? echo $d['id']; ?>' <? if($d['id']==$_SESSION['id_dep']) echo "selected"; ?>><? echo $d['nom']; ?></option>
					<?php 
}
?>
					</select>
				<label for='id_dep'>Departamento:</label>
			</div>
			<div>
				<input class='btn' type="submit" value="Guardar">
				<input class='btn modal-close' type="button" value="Cancelar">
			</div>
		</form>
		</div>
  	</div>