function themes($colegio_ID) { $class_style = new style(); $style = $class_style->obtenerStyle($colegio_ID); $styles = $class_style->obtenerStyles(); $html = "Seleccione un tema: <br><select id='selectStyle' name='selectStyle'>"; foreach ($styles as $key => $styleFolder) { if ($styleFolder == $style['style_path']) { $selected = "selected"; } else { $selected = ""; } $html .= "<option value='{$styleFolder}' {$selected}>{$styleFolder}</option>"; } $html .= "</select>"; $html .= "<input type='button' name='guardarTheme' id='guardarTheme' value='Guardar Tema' />"; $html .= "<script>\$('#guardarTheme').click(function(){\r var selectStyle = \$('#selectStyle').val();\r \$('#form_super').append(\"<input type='hidden' name='style_path' id='style_path' value='\"+selectStyle+\"'\");\r \$('#_action').val('guardarTheme');\r \$('#form_super').submit();\r });\r </script>"; print $html; }
$bdSIGA->anio = $base_datos['anio']; $bdSIGA->nombrebd = "dorcl_" . $base_datos['bd'] . $base_datos['anio']; // Fin carga BD //Ingreso a logs base de datos $login = $_POST['login']; $tipo = $usuarios['tipo']; require "phpLib/MF_log_Lib.php"; //fin ingreso de logs a la base de datos $smarty->display('MF_ingreso_valido.tpl'); $_SESSION['token'] = $token; $_SESSION['bd_siga'] = "dorcl_siga"; $_SESSION['colegio'] = $colegioSIGA; $_SESSION['usuario'] = $usuarioSIGA; $_SESSION['base_datos'] = $bdSIGA; $class_style = new style(); $style = $class_style->obtenerStyle($_SESSION['colegio']->colegio_ID); $styleSIGA->style_ID = $style['style_ID']; $styleSIGA->FK_colegios_colegio_ID = $style['FK_colegios_colegio_ID']; $styleSIGA->style_css = $style['style_css']; $styleSIGA->style_path = $style['style_path']; $_SESSION['style'] = $styleSIGA; switch ($usuarios["tipo"]) { case "profesor": moveLocation("profesor/profesores.php"); break; case "utp": moveLocation("profesor/profesores.php"); break; case "secretaria": moveLocation("secretaria/SEC-buscas.php"); break;
$tablesRut = $class_siga->getTableWithRut($baseSelected); foreach ($tablesRut as $key => $table) { $datos_set = array($table["field"] => $rut_nuevo); $datos_where = array($table["field"] => $rut_viejo); $class_alumno->cambiarRut($datos_set, $datos_where, $table["name"]); } dpr("El rut se ha cambiado de forma exitosa"); } } break; case "salir": session_destroy(); moveLocation("index-1.html", 0); break; case "guardarTheme": $datosStyle = $class_style->obtenerStyle($_GET['colegio_ID']); $datosStyle["style_path"] = $_GET['style_path']; $style_ID = $class_style->guardarStyle($datosStyle); $_SESSION['style']->style_ID = $style_ID; $_SESSION['style']->style_path = $_GET['style_path']; moveLocationFast("super_usuario.php"); break; case "1": echo "Empesando el script que actualiza datos.."; set_time_limit(9000); mysql_select_db(getBD()); $alumnos = $class_alumno->obtenerAlumnos(); $cursos = $class_curso->obtenerCursos(); $ramos = $class_ramo->obtenerTodosRamos(); $ciclos = $class_curso->obtenerCiclos(); mysql_select_db($bd_siguiente);