Skip to main content
BANNER INTERNO

Zona inscritos


Acceso login

{source}<?php
header("Cache-Control: no-store, no-cache, must-revalidate, max-age=0");
header("Cache-Control: post-check=0, pre-check=0", false);
header("Pragma: no-cache");
set_include_path('clave/seclib');
include("Crypt/RSA.php");

$tipoMiembro = 2;
function getGescoData(){
$url = 'https://149.13.16.198/WebServicesCongresos/rest/webServiceSessionGesco/getWebinarsRegistro';
$timeout = 4;
$error_report = FALSE;
$curl = curl_init($url);
$dummy= 'dummy='.rand();
curl_setopt($curl, CURLOPT_HTTPHEADER, $headers);
curl_setopt($curl, CURLOPT_FRESH_CONNECT, TRUE);
curl_setopt($curl, CURLOPT_HEADER, 0);
curl_setopt($curl, CURLINFO_HEADER_OUT, 0);
curl_setopt($curl, CURLOPT_POST, 1);
curl_setopt($curl, CURLOPT_POSTFIELDS, $dummy);
curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($curl, CURLOPT_COOKIEJAR, COOKIE_FILE);
curl_setopt($curl, CURLOPT_COOKIEFILE, COOKIE_FILE);
curl_setopt($curl, CURLOPT_ENCODING, "UTF-8");
curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, 0);
curl_setopt($curl, CURLOPT_SSL_VERIFYHOST, 0);
curl_setopt($curl, CURLOPT_FRESH_CONNECT, true);
curl_setopt($curl, CURLOPT_FORBID_REUSE, true);

$return = curl_exec($curl);
$httpCode = curl_getinfo($curl, CURLINFO_HTTP_CODE);
curl_close($curl);
if ($httpCode == 200) {
return json_decode($return);
} else {
return false;
}
}



$user = JFactory::getUser();
if($user->id){
echo "<br/><br/> <div align='center' style='color:#262626; font-weight:bold;'> Bienvenido/a,<br/> $user->name";
echo "<br><br>";
echo "<a class='uk-button uk-button-primary' href='/index.php/acceso-inscritos/documentacion'>ENTRAR</a><br/><br/>";
echo "<a class='uk-button uk-button-primary' href='/index.php/cerrar-sesion'>DESCONECTAR</a></div>";
}else{

if ($_POST["user"]) {
function curl_post() {
include_once('/clave/seclib/Crypt/RSA.php');
$pubkey = file_get_contents("https://congresoseedo.es/clave/publicKeyWS_new");
$rsa = new Crypt_RSA();
$rsa->loadKey($pubkey);

$rsa->setEncryptionMode(CRYPT_RSA_ENCRYPTION_PKCS1);

$post_string = '';
$post_string .= urlencode('authenticationType') . '=' . urlencode('register') . '&';
$post_string .= urlencode('timestamp') . '=' . urlencode(round(microtime(true) * 1000)) . '&';
$post_string .= urlencode('congId') . '=' . urlencode('2407') . '&';
$post_string .= urlencode('user') . '=' . $_POST["user"] . '&';
$post_string .= urlencode('password') . '=' . urlencode(utf8_encode($_POST["pass"])) . '&';
/*$post_string .= urlencode('ip') . '=' . urlencode('') . '&';*/
$post_string .= urlencode('sess') . '=' . urlencode('no') . '&';
$post_string = rtrim($post_string, '&');

$token = base64_encode($rsa->encrypt($post_string));

$headers = array();

$headers[] = "Content-type: text/json;charset=\"utf-8\"";

$headers[] = "Authorization: Basic " . $token;
$_SESSION["header"] = $headers;
//echo($post_string);
//idSociedad=5&usuario=user&pass...
//authenticationType=register&timestamp=" . round(microtime(true) * 1000) . "&congId=?&user=?&password=?&ip=?&sess=?
$url = 'https://149.13.16.198/WebServicesCongresos/rest/authentication';
$timeout = 4;
$error_report = FALSE;
// PREPARE THE CURL CALL
$curl = curl_init($url);
curl_setopt($curl, CURLOPT_HTTPHEADER, $headers);
curl_setopt($curl, CURLOPT_FRESH_CONNECT, TRUE);
curl_setopt($curl, CURLOPT_HEADER, 0);
curl_setopt($curl, CURLINFO_HEADER_OUT, 0);
curl_setopt($curl, CURLOPT_POST, 1);
curl_setopt($curl, CURLOPT_POSTFIELDS, "");
curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($curl, CURLOPT_COOKIEJAR, COOKIE_FILE);
curl_setopt($curl, CURLOPT_COOKIEFILE, COOKIE_FILE);
curl_setopt($curl, CURLOPT_ENCODING, "UTF-8");
curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, 0);
curl_setopt($curl, CURLOPT_SSL_VERIFYHOST, 0);
curl_setopt($curl, CURLOPT_FRESH_CONNECT, true);
curl_setopt($curl, CURLOPT_FORBID_REUSE, true);
// EXECUTE THE CURL CALL
$return = curl_exec($curl);
$httpCode = curl_getinfo($curl, CURLINFO_HTTP_CODE);
curl_close($curl);

// ON SUCCESS
if ($httpCode == 200) {
return true;
} else {
return false;
}
}



$htm = curl_post();
if ($htm == true ) {
error_log("comprobacion usuario " . $_POST["user"], 0);
$bd_host = "localhost";
$bd_usuario = "ugsaagr58dp1t";
$bd_password = "ubtcedegfpjm";
$bd_base = "dbhqsod3fngxkh";
$con = mysqli_connect($bd_host, $bd_usuario, $bd_password, $bd_base);
if ($con == false) {
error_log("no conectado a la base de datos $bd_host $bd_base $bd_password $bd_usuario");
} else {
error_log("conectado a la base de datos $bd_host $bd_base $bd_password $bd_usuario");
}
// mysql_select_db($bd_base, $con);
$sql = mysqli_query($con,"SELECT * FROM seedo2024_users WHERE username = '" . $_POST["user"] . "'");

if (mysqli_fetch_array($sql)) {
//echo "ha encontrado user ";
// LOGIN EN JOOMLA
$mainframe = & JFactory::getApplication('site');
jimport('joomla.plugin.helper');
$credentials = array();
$credentials['username'] = $_POST["user"];
$credentials['password'] = 'Pacifico2014';
$user = JFactory::getUser();
$error = $mainframe->login($credentials);
$gescoData = getGescoData();
if($gescoData != false){
$_SESSION["nombre"] = $gescoData->nombre;
$_SESSION["apellidos"] = $gescoData->apellidos;
$_SESSION["email"] = $gescoData->email;
$_SESSION["idRegistro"] = $gescoData->idRegistro;
$_SESSION["idCuotaInscripcion"] = $gescoData->idCuotaInscripcion;
$_SESSION["listWebinars"] = $gescoData->listWebinars;
$_SESSION["nombreUsuarioJoomla"] = $user->username;
$_SESSION["nombreUsuario"] = $gescoData ->userName;
}
$tipoMiembro = 2;
//if($gescoData->idCuotaInscripcion == 10985) {
//$tipoMiembro = 10; //medico
//} else if($gescoData->idCuotaInscripcion == 10988) {
//$tipoMiembro = 11; //auxiliares
//}else if($gescoData->idCuotaInscripcion == 10987) {
//$tipoMiembro = 12; //gestores
//}
} else {
$gescoData = getGescoData();
if($gescoData != false){
$_SESSION["nombre"] = $gescoData->nombre;
$_SESSION["apellidos"] = $gescoData->apellidos;
$_SESSION["email"] = $gescoData->email;
$_SESSION["idRegistro"] = $gescoData->idRegistro;
$_SESSION["idCuotaInscripcion"] = $gescoData->idCuotaInscripcion;
$_SESSION["listWebinars"] = $gescoData->listWebinars;
$_SESSION["nombreUsuarioJoomla"] = $user->username;
$_SESSION["nombreUsuario"] = $gescoData ->userName;
}
$tipoMiembro = 2;
//if($gescoData->idCuotaInscripcion == 10985) {
//$tipoMiembro = 10; //medico
//} else if($gescoData->idCuotaInscripcion == 10988) {
//$tipoMiembro = 11; //auxiliares
//}else if($gescoData->idCuotaInscripcion == 10987) {
//$tipoMiembro = 12; //gestores
//}
error_log("hacemos el insert " . $_POST["user"], 0);
//mysql_select_db($bd_base, $con);
$ok = mysqli_query($con,"INSERT INTO seedo2024_users(name,username,email,password,block,sendEmail,registerDate,params) VALUES('".($_POST["user"])."','".($_POST["user"])."','".($_POST["user"])."','".md5('Pacifico2014')."',0,0,'".date("Y/m/d h:i:sa")."','{}')");
if ($ok) {
error_log("insert correcto");
} else {
error_log("insert incorrecto");
//error_log(mysql_error());
}
$sql20 = mysqli_query($con,"SELECT id from seedo2024_users where username = '" . ($_POST["user"]) . "'");
$sql21 = mysqli_fetch_array($sql20);
mysqli_query($con,"INSERT INTO seedo2024_user_usergroup_map (user_id,group_id) VALUES(" . $sql21["id"] . ",".$tipoMiembro.")");

// LOGIN EN JOOMLA
$mainframe = & JFactory::getApplication('site');
jimport('joomla.plugin.helper');
$credentials = array();
$credentials['username'] = $_POST["user"];
$credentials['password'] = 'Pacifico2014';
$user = JFactory::getUser();
$error = $mainframe->login($credentials);
}
//echo "<p>Accediendo al área privada...</p>";
//if ($tipoMiembro == 10) {
// echo "<script>window.location='/index.php/medicos';</script>";
//} else if ($tipoMiembro == 11) {
// echo "<script>window.location='/index.php/auxiliares';</script>";
//} else if ($tipoMiembro == 12) {
// echo "<script>window.location='/index.php/gestores';</script>";
//}
echo "<script>window.location='/index.php/acceso-inscritos/documentacion';</script>";
} else {
echo "<div style='padding:10px;background-color: white;border:3px solid #BE1D15;color:#BE1D15;'><span style='font-weight:bold;font-size: 16px;'>Usuario o contraseña inválida</span></div>";
echo "<script>window.location='/index.php/acceso-inscritos/zona-inscritos';</script>";


echo "
<form name='login' method='POST' action='' accept-charset='UTF-8'>
<div align='center' style='background: transparent; width: 100%; '>
<table width='75%' >
<tr>
<td align='center'> <strong>USUARIO</strong> <br/><input type='text' name='user' size='10' placeholder='Usuario'><br/><br/></td>
</tr>
<tr>
<td align='center'><strong> CONTRASEÑA</strong> <br/><input type='password' name='pass' size='10' placeholder='Contraseña'><br/><br/>
<div align='center' style='font-size:10px; color:black;'>Al pulsar ENTRAR, <br/>está aceptando la <a href='#politicarestricciones' uk-toggle>política de restricciones</a> <br/>sobre el uso del contenido audiovisual.</div>
<div id='politicarestricciones' class='uk-flex-top' uk-modal>
<div class='uk-modal-dialog uk-modal-body uk-margin-auto-vertical'>
<h1 class='uk-h3 uk-text-primary uk-text-center'>POLÍTICA DE RESTRICCIONES</h1>
<hr class='uk-divider-small uk-text-center uk-margin-small'><br/>
<div align='justify'>La información facilitada en este espacio está dirigida exclusivamente a profesional sanitario.
Queda prohibida la descarga y/o grabación de las sesiones (total o parcial) así como su reproducción o difusión posterior sea cual sea el medio o dispositivo utilizado.</div>
<p class='uk-text-right'>
<button type='button' class='uk-button uk-button-primary uk-modal-close'>CERRAR</button>
</div>
</div>
<br/>
</td>
</tr>
<tr>
<td align='center'> <button class='uk-width-1-1 uk-button uk-button-primary' type='submit' value='' >ENTRAR</button><br/><br/></td>
</tr></table>
</div>
</form>
<div align='center' style='font-size:12px;' > < a class='home' href='https://congresoseedo.es/index.php/acceso-inscritos/recordar-contrasena' target='_blank'><strong>¿Has olvidado tu contraseña?</strong></a>
</div>";

}
}else{
echo "
<form name='login' method='POST' action='' accept-charset='UTF-8'>
<div align='center' style='background: transparent; width: 100%; '>
<table width='75%' >
<tr>
<td align='center'> <strong>USUARIO </strong><br/><input type='text' name='user' size='30' placeholder='Usuario'><br/><br/></td>
</tr>
<tr>
<td align='center'> <strong>CONTRASEÑA</strong> <br/><input type='password' name='pass' size='30' placeholder='Contraseña'><br/><br/>
<div align='center' style='font-size:10px; color:black;'>Al pulsar ENTRAR, <br/>está aceptando la <a href='#politicarestricciones' uk-toggle>política de restricciones</a> <br/>sobre el uso del contenido audiovisual.</div>
<div id='politicarestricciones' class='uk-flex-top' uk-modal>
<div class='uk-modal-dialog uk-modal-body uk-margin-auto-vertical'>
<h1 class='uk-h3 uk-text-primary uk-text-center'>POLÍTICA DE RESTRICCIONES</h1>
<hr class='uk-divider-small uk-text-center uk-margin-small'><br/>
<div align='justify'>La información facilitada en este espacio está dirigida exclusivamente a profesional sanitario.
Queda prohibida la descarga y/o grabación de las sesiones (total o parcial) así como su reproducción o difusión posterior sea cual sea el medio o dispositivo utilizado.</div>
<p class='uk-text-right'>
<button type='button' class='uk-button uk-button-primary uk-modal-close'>CERRAR</button>
</div>
</div>
<br/>
</td>
</tr>
<tr>
<td align='center'> <button class='uk-width-1-1 uk-button uk-button-primary' type='submit' value='' >ENTRAR</button><br/><br/></td>
</tr></table>
</div>
</form>
<div align='center' style='font-size:12px;' > < a class='home' href='https://congresoseedo.es/index.php/acceso-inscritos/recordar-contrasena' target='_blank'><strong>¿Has olvidado tu contraseña?</strong></a>
</div>

";
}
}

?>
{/source}

Fechas Importantes


  • Apertura comunicaciones
    1 de Junio de 2024
  • Fin envío comunicaciones
    24 de Septiembre de 2024
  • Notificación comunicaciones
    A partir del 15 de Octubre de 2024
  • Fin cuota reducida
    9 de Octubre 2024
  • Inicio Congreso
    27 de Noviembre 2024

logo renfe
Solicita el código de descuente RENFE por email a la Secretaría Técnica

Esta dirección de correo electrónico está siendo protegida contra los robots de spam. Necesita tener JavaScript habilitado para poder verlo.