<?php include "../ReglasNegocio/unidad.php"; include "../ReglasNegocio/departamento.php"; include "../ReglasNegocio/direccion.php"; $departamento = new departamento(); $unidad = new unidad(); $direccion = new direccion(); $editar = $_GET["editar"]; $boton = "verifica()"; if (!empty($editar)) { $id_unidad = $unidad->Select($editar); $row = mysql_fetch_array($id_unidad); $id_departamento = $row['ID_DEPARTAMENTO']; $nombre_unidad = $row['NOMBRE_UNIDAD']; //echo $id_departamento; $boton = "VerificaUpdate()"; } ?> <script LANGUAGE="JavaScript"> function verifica() { if (document.form.unidad.value.length==0) { alert("Debe ingresar un Nombre"); return 0; } else if (document.form.departamento.value==0)