function sync($id, $frm_id, $message_threshold, $perm) { if (!db_locked()) { db_lock('phpgw_fud_poll_opt WRITE, phpgw_fud_forum WRITE, phpgw_fud_msg WRITE, phpgw_fud_thread WRITE, phpgw_fud_thread_view WRITE'); $ll = 1; } $file_id = write_body($this->body, $length, $offset); /* determine if preview needs building */ if ($message_threshold && $message_threshold < strlen($this->body)) { $thres_body = trim_html($this->body, $message_threshold); $file_id_preview = write_body($thres_body, $length_preview, $offset_preview); } else { $file_id_preview = $offset_preview = $length_preview = 0; } poll_cache_rebuild($this->poll_id, $poll_cache); $poll_cache = $poll_cache ? @serialize($poll_cache) : null; q("UPDATE phpgw_fud_msg SET\n\t\t\tfile_id=" . $file_id . ",\n\t\t\tfoff=" . (int) $offset . ",\n\t\t\tlength=" . (int) $length . ",\n\t\t\tmlist_msg_id=" . strnull(addslashes($this->mlist_msg_id)) . ",\n\t\t\tfile_id_preview=" . $file_id_preview . ",\n\t\t\toffset_preview=" . $offset_preview . ",\n\t\t\tlength_preview=" . $length_preview . ",\n\t\t\tupdated_by=" . $id . ",\n\t\t\tmsg_opt=" . $this->msg_opt . ",\n\t\t\tattach_cnt=" . (int) $this->attach_cnt . ",\n\t\t\tpoll_id=" . (int) $this->poll_id . ",\n\t\t\tupdate_stamp=" . __request_timestamp__ . ",\n\t\t\ticon=" . strnull(addslashes($this->icon)) . " ,\n\t\t\tpoll_cache=" . strnull(addslashes($poll_cache)) . ",\n\t\t\tsubject=" . strnull(addslashes($this->subject)) . "\n\t\tWHERE id=" . $this->id); /* determine wether or not we should deal with locked & sticky stuff * current approach may seem a little redundant, but for (most) users who * do not have access to locking & sticky this eliminated a query. */ $th_data = db_saq('SELECT orderexpiry, thread_opt, root_msg_id FROM phpgw_fud_thread WHERE id=' . $this->thread_id); $locked = (int) isset($_POST['thr_locked']); if (isset($_POST['thr_ordertype'], $_POST['thr_orderexpiry']) || ($th_data[1] ^ $locked) & 1) { $thread_opt = (int) $th_data[1]; $orderexpiry = isset($_POST['thr_orderexpiry']) ? (int) $_POST['thr_orderexpiry'] : 0; /* confirm that user has ability to change lock status of the thread */ if ($perm & 4096) { if ($locked && !($thread_opt & $locked)) { $thread_opt |= 1; } else { if (!$locked && $thread_opt & 1) { $thread_opt &= ~1; } } } /* confirm that user has ability to change sticky status of the thread */ if ($th_data[2] == $this->id && isset($_POST['thr_ordertype'], $_POST['thr_orderexpiry']) && $perm & 64) { if (!$_POST['thr_ordertype'] && $thread_opt > 1) { $orderexpiry = 0; $thread_opt &= ~6; } else { if ($thread_opt < 2 && (int) $_POST['thr_ordertype']) { $thread_opt |= $_POST['thr_ordertype']; } else { if (!($thread_opt & (int) $_POST['thr_ordertype'])) { $thread_opt = $_POST['thr_ordertype'] | $thread_opt & 1; } } } } /* Determine if any work needs to be done */ if ($thread_opt != $th_data[1] || $orderexpiry != $th_data[0]) { q("UPDATE phpgw_fud_thread SET thread_opt=" . $thread_opt . ", orderexpiry=" . $orderexpiry . " WHERE id=" . $this->thread_id); /* Avoid rebuilding the forum view whenever possible, since it's a rather slow process * Only rebuild if expiry time has changed or message gained/lost sticky status */ $diff = $thread_opt ^ $th_data[1]; if ($diff > 1 && !($diff & 6) || $orderexpiry != $th_data[0]) { rebuild_forum_view($frm_id); } } } if (isset($ll)) { db_unlock(); } if ($GLOBALS['FUD_OPT_1'] & 16777216) { delete_msg_index($this->id); index_text(preg_match('!^Re: !i', $this->subject) ? '' : $this->subject, $this->body, $this->id); } }
<?php session_start(); $user = $_SESSION['userblanco']; $departmen = $_SESSION['departmen']; $manager = $_SESSION['manager']; include "encabezado.php"; write_header('Servicio de vacaciones'); write_body('Servicio de vacaciones', $user); write_notificacion(); $username = "******"; $password = "******"; $hostname = "localhost"; //connection to the database $dbhandle = mysql_connect($hostname, $username, $password) or die("Unable to connect to MySQL+++" . mysql_error()); $selected = mysql_select_db("registroVacaciones", $dbhandle) or die("Could not select examples"); $sql = "SELECT Saldo,idEmpleado,nombre\n\t\t\tFROM Empleados\n\t\t\tWHERE user = '******'"; $result = mysql_query($sql); $row = mysql_fetch_array($result); $_SESSION['saldo'] = $row[0]; $_SESSION['idEmpleado'] = $row[1]; $_SESSION['nombre_empleado'] = $row[2]; $departmen = $_SESSION['departmen']; $manager = $_SESSION['manager']; ?> <div id="main" role="main" class="blanco"> <div id="movimiento_tamano" class="mov_tam"> <form class="dashboard" id="index_extendido_vacaciones"> <fieldset>
<?php session_start(); $user = $_SESSION['userblanco']; include 'encabezado.php'; write_header('busqueda_servicios'); write_body('busqueda_servicios', $user); write_notificacion(); include 'groups.php'; ?> <div id="main" role="main" style="margin-bottom:10px; height:auto;"> <div id="body_principal" class="body_menu"><!--BODY PRINCIPAL--> <div id="navegador" class="navegador_bloque"> <div id="texto_busqueda" class="textos_busqueda"> <span>Elija el método de búsqueda : </span> </div> <div id="menu_accesos_directos" class="accesos_directos"> <ul> <li><a href="clientes.php">Razón Social</a></li> <li class="center_menu"><a href="tarjeta.php">Serie Fabricante</a></li> <li><a href="contratos.php">Código Contrato</a></li> </ul> </div> </div> </div><!--FIN //BODY PRINCIPAL--> <?php include 'footer.php';
<?php //Scott Kinder, Index page for NBA Search PA#1 //Landing page require_once 'presentation.php'; //writes the page header write_header(); //writes page body write_body();
<?php session_start(); $user = $_SESSION['userblanco']; $departmen = $_SESSION['departmen']; $manager = $_SESSION['manager']; include "encabezado.php"; write_header('Mantenimiento empleados'); write_body('Mantenimiento empleados', $user); write_notificacion(); ?> <div id="main" role="main" class="blanco"> <div id="movimiento_tamano" class="mov_tam"> <form class="dashboard" id="index_extendido_manager"> <fieldset> <legend style="text-align: center; font-size:12px"> Mantenimiento empleados </legend> <ol> <li> <label for="lista_empleados">Lista de empleados : </label> <select id="lista_empleados"></select> <br /> </li> <li> <label for="fecha_ingreso">Fecha de Ingreso : </label>
<?php session_start(); $user = $_SESSION['userblanco']; include "encabezado.php"; write_header('Blog de solicitudes'); write_body('Blog de solicitudes', $user); write_notificacion(); //ESPACIO PARA OBTENER TODOS LOS DEPARTAMENTOS Y DESPUES AGREGAR METODOS EN EL JQUERY PARA PONER EL MANAGER DEL GRUPO ?> <div id="main" role="main"> <form class="dashboard"> <fieldset> <legend>Ingresar Solicitud al blog</legend> <ol> <li> <label for="cliente_label">Cliente</label> <input type="text" autofocus="" required="" placeholder="Cliente" name="Cliente" id="cliente"> <img src="img/lupa.png" href="#" id="link_clientes" width="15" height="20" /> <br/> </li> <li> <label for="departamento">Departamento</label> <select name="departamentos" id="departamentos">
<?php session_start(); if (isset($_SESSION['ultimo_id'])) { $id = $_SESSION['ultimo_id']; } else { header('Location: post_pendientes.php'); } $user = $_SESSION['userblanco']; include "encabezado.php"; write_header('Peticion'); write_body('Peticicion', $user); write_notificacion(); //FUNCION PARA OBTENER TODA LA INFO ACTUAL DEL POST PRINCIPAL, RESTO DE LA CONSULTA EN UN POST DE JQUERY CON UN SET INTERVAR $username = "******"; $password = "******"; $hostname = "localhost"; //connection to the database $dbhandle = mysql_connect($hostname, $username, $password) or die("Unable to connect to MySQL+++" . mysql_error()); $selected = mysql_select_db("Blog", $dbhandle) or die("Could not select examples"); $sql = 'select * from Solicitud where id_solicitud = ' . $id; $result = mysql_query($sql, $dbhandle); $datos_principal = array(); while ($row = mysql_fetch_array($result)) { $datos_principal = $row; } function calcular_tiempo($date) { date_default_timezone_set('America/Costa_Rica'); $fecha_actual = strtotime(date("Y-m-d H:i:s")); $date = strtotime($date);
<?php session_start(); $user = $_SESSION['userblanco']; $departmen = $_SESSION['departmen']; $manager = $_SESSION['manager']; include "encabezado.php"; write_header('Mantenimiento feriados'); write_body('Mantenimiento feriados', $user); write_notificacion(); ?> <div id="main" role="main" class="blanco"> <div id="movimiento_tamano" class="mov_tam"> <form class="dashboard" id="index_extendido_manager"> <fieldset> <legend style="text-align: center; font-size:12px"> Mantenimiento de dias festivos </legend> <ol> <li> <label for="lista_feriados">Dias festivos : </label> <div id="dias"> <table id="tabla_feriados" border="0" cellspacing="0"> <thead> <tr> <th></th> <th>Nombre</th> <th>Dia</th>
<?php include "encabezado.php"; write_header('login'); write_body('Login', 'login'); write_notificacion(); ?> <div id="main" role="main" class="blanco"> <div id="movimiento_tamano" class="mov_tam"> <form class="dashboard" id="index_extendido" method="post" action="index.php"> <fieldset> <legend class="letra_12">Iniciar sesión</legend> <ol class="mover_izquierda_ol" > <li> <label for="name">Usuario</label> <br/> <input type="text" autofocus="" required="" placeholder="" name="name" id="name"> <br/> </li> <li> <label for="email">Contraseña</label> <br/> <input type="password" required="" name="password" id="password"> </li> </ol>
<?php session_start(); $user = $_SESSION['userblanco']; include 'encabezado.php'; write_header('Grupo Electrotécnica'); write_body('Grupo Electrotecnica', $user); write_notificacion(); include 'groups.php'; $grupos = array(); $grupos = generar_lista_grupos(); ?> <div id="main" role="main" class="blanco espacio_superior"> <div class="rows"> <div class="row even"><h2>General</h2> <a href="blog_request.php"><img src="img/icons/blog-de-ideas.png" alt="Blog" width="70" height="70"/><span>Crear solicitud</span></a> <a href="requests.php"><img src="img/icons/blog-de-ideas.png" alt="Blog" width="70" height="70"/><span>Solicitudes pendientes</span></a> </div> <?php if (in_array('comercial', $grupos) || in_array('portalmanager', $grupos)) { echo "<div class=\"rows\">\n<div class=\"row even\"><h2>Comercial</h2>\n\t\t\t\t\t<a href=\"menu_servicios.php\"><img src=\"img/icons/busqueda-de-equipos-en-garantia.png\" alt=\"Servicios\" width=\"70\" height=\"70\"/><span>Servicios</span></a>\n\t\t\t\t\t</div> \n"; } ?> <div class="row even"><h2>Gestion Humana</h2> <a href="request_vacation.php"><img src="img/icons/vacaciones.png" alt="Solicitud" width="70" height="70"/><span>Solicitud de vacaciones</span></a> <?php if (in_array('portalvacacionesmanager', $grupos)) {
<?php session_start(); $user = $_SESSION['userblanco']; include 'encabezado.php'; write_header('Contrato de servicio'); write_body('Contrato de servicio', $user); write_notificacion(); if (isset($_GET['par'])) { $parametro_oculto = $_GET['par']; } else { $parametro_oculto = ''; } ?> <div id="main" role="main" style="margin-bottom:20px;"> <div id="body_principal" class="bloque_principal"><!--BODY PRINCIPAL--> <div id="buscador" class="bloque_buscador"><!--BODY DEL BUSCADOR PARA CADA PAGINA--> <form class="menu_busqueda"> <ol class="replace"> <li class="filas_problema"> <input type="hidden" id="parametro_oculto" style="width:0px; height:0px;" value="<?php echo $parametro_oculto; ?> "/> <label class="menu_label" for="busqueda";>Codigo de contrato :</label> <input class="menu_input" type="text" id="busqueda"> <img class="menu_imagen" src="img/lupa2.png" id="busqueda_link" width="23" height="20"/> </li>
<?php session_start(); $user = $_SESSION['userblanco']; include "encabezado.php"; write_header('Solicitudes Pendientes'); write_body('Solicitudes Pendientes', $user); write_notificacion(); ////////////////////////////////////////////////////////ESPACIO PARA EL CODIGO CONSULTOR DE LA INFORMACION, FORMAR TODOS LOS ARRAY AQUI Y SOLO PINTAR EN MAS ADELANTE $tofind = "ÀÁÂÃÄÅàáâãäåÒÓÔÕÖØòóôõöøÈÉÊËèéêëÇçÌÍÎÏìíîïÙÚÛÜùúûüÿÑñ"; $replac = "abcdeeghijklaaoiqosuunwxyzabcdeeghijklmaoiqosuunwxyza"; $user = $_SESSION['userblanco']; $ldappass = $_SESSION['pass']; $ldaprdn = "electrotecnica\\" . $user; $adServer = "pegasus.electrotecnica.local"; #replace with your AD server ip/hostname $ldapconn = ldap_connect($adServer) or die("Couldn't connect to AD!"); // Bind to the directory server. $ldapbind = ldap_bind($ldapconn, $ldaprdn, $ldappass) or die("Couldn't bind to AD!"); $dn = 'OU=Electrotecnica,dc=electrotecnica,dc=local'; $filter = '(samaccountname=' . $user . ')'; $result = ldap_search($ldapconn, $dn, $filter); $entries = ldap_get_entries($ldapconn, $result); try { $nombre_completo = strtr($entries[0]['displayname'][0], $tofind, $replac); $departemt_propio = strtr($entries[0]['department'][0], $tofind, $replac); } catch (Exception $e) { } $username = "******"; $password = "******"; $hostname = "localhost";
<?php session_start(); $user = $_SESSION['userblanco']; include 'encabezado.php'; write_header('Tarjeta de equipo'); write_body('Tarjeta de equipo', $user); write_notificacion(); if (isset($_GET['par'])) { $parametro_oculto = $_GET['par']; } else { $parametro_oculto = ''; } ?> <div id="main" role="main" style="margin-bottom:20px;"> <div id="body_principal" class="bloque_principal"><!--BODY PRINCIPAL--> <div id="buscador" class="bloque_buscador"><!--BODY DEL BUSCADOR PARA CADA PAGINA--> <form class="menu_busqueda"> <ol class="replace"> <li class="filas_problema"> <input type="hidden" id="parametro_oculto" style="width:0px; height:0px;" value="<?php echo $parametro_oculto; ?> " /> <label class="menu_label" for="busqueda">Numero de serie:</label> <input class="menu_input" type="text" id="busqueda"> <img src="img/lupa2.png" class="menu_imagen" id="busqueda_link" width="23" height="20"/> </li>
<?php session_start(); $user = $_SESSION['userblanco']; include 'encabezado.php'; write_header('Cliente'); write_body('Cliente', $user); write_notificacion(); if (isset($_GET['par'])) { $parametro_oculto = $_GET['par']; } else { $parametro_oculto = ''; } ?> <div id="main" role="main" style="margin-bottom:25px;"> <div id="body_principal" class="bloque_principal"><!--BODY PRINCIPAL--> <div id="buscador" class="bloque_buscador"><!--BODY DEL BUSCADOR PARA CADA PAGINA--> <form class="menu_busqueda"> <ol class="replace"> <li class="filas_problema"> <input type="hidden" id="parametro_oculto" value="<?php echo $parametro_oculto; ?> " /> <label class="menu_label" for="nombre";>Nombre cliente:</label> <input class="menu_input" type="text" id="nombre"> <img class="menu_imagen" src="img/lupa2.png" id="busqueda_link" width="23" height="20"/>