inicio

parent 190f3a22
# Default ignored files
/workspace.xml
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="JavaScriptSettings">
<option name="languageLevel" value="ES6" />
</component>
</project>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="ProjectModuleManager">
<modules>
<module fileurl="file://$PROJECT_DIR$/.idea/untitled.iml" filepath="$PROJECT_DIR$/.idea/untitled.iml" />
</modules>
</component>
</project>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<module type="WEB_MODULE" version="4">
<component name="NewModuleRootManager">
<content url="file://$MODULE_DIR$" />
<orderEntry type="inheritedJdk" />
<orderEntry type="sourceFolder" forTests="false" />
</component>
</module>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="VcsDirectoryMappings">
<mapping directory="$PROJECT_DIR$" vcs="Git" />
</component>
</project>
\ No newline at end of file
<?php
$servername = "localhost";
$username = "root";
$password = "PkJXPQFykKLmS3cWhqmZKNYE";
$dbname = "Escuelas";
// Create connection
$conn = new mysqli($servername, $username, $password, $dbname);
// Check connection
if ($conn->connect_error) {
die("Connection failed: " . $conn->connect_error);
}
?>
\ No newline at end of file
<!--
/* Coded by Ing. Ulises Morales Ramirez */
-->
<?php
session_start();
?>
<!DOCTYPE html>
<html>
<head>
<title>Sin titulo</title>
<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.1.3/css/bootstrap.min.css"
integrity="sha384-MCw98/SFnGE8fJT3GXwEOngsV7Zt27NXFoaoApmYm81iuXoPkFOJwJ8ERdknLPMO" crossorigin="anonymous">
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>
<link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.6.1/css/all.css"
integrity="sha384-gfdkjb5BdAXd+lj+gudLWI+BXq4IuLW5IT+brZEZsLFm++aCMlF1V92rMkPaX4PP" crossorigin="anonymous">
<link rel="stylesheet" type="text/css" href="ownStyle.css" media="screen"/>
</head>
<!--Coded with love by Mutiullah Samim-->
<body>
<div class="container h-100">
<!--div class="text-center" style="z-index: -1"><img src="images/header.png" width="800px"></div-->
<div class="d-flex justify-content-center h-100">
<div class="user_card">
<div class="d-flex justify-content-center">
<div class="brand_logo_container">
<img src="images/logo_geo.png" class="brand_logo" alt="Logo">
</div>
</div>
<div class="d-flex justify-content-center form_container">
<form action="insertar.php" method="post">
<input type="hidden" name="escuela" value="<?= $_SESSION["escuela"] ?>">
<input type="hidden" name="idioma" value="<?= $_POST['idioma']; ?>">
<div class="input-group mb-3">
<div class="input-group-append">
<span class="input-group-text"><i class="fas fa-user"></i></span>
</div>
<input type="text" name="nombre" class="form-control input_user" value="" placeholder="<?php
if ($_POST['idioma']=='Maya')
{
echo "Tuláakal a k'aaba'";
}
else{
echo "Nombre Completo ";
}
?>" required>
</div>
<div class="input-group mb-3">
<div class="input-group-append">
<span class="input-group-text"><i class="fas fa-user"></i></span>
</div>
<input type="number" pattern="\d*" min="1" max="99" name="edad" class="form-control input_user" value="" placeholder="<?php
if ($_POST['idioma']=='Maya')
{
echo "Ja'ab";
}
else{
echo "Edad ";
}
?>" required>
</div>
<div class="mt-4">
<div class="d-flex justify-content-center links">
<?php
if ($_POST['idioma']=='Maya')
{
echo "¿Ti' teeche' ba'ax le jets' óolalo'?";
}
else{
echo "¿Qué es para ti la paz?";
}
?>
</div>
</div>
<div class="form-group">
<textarea required class="form-control" rows="8" cols="50" name="comentario" style="resize: none" maxlength="200" onKeyDown="valida_longitud()" onKeyUp="valida_longitud()"></textarea>
<?php
if ($_POST['idioma']=='Maya')
{
echo "Cantidad u caracteres:.";
}
else{
echo "Cantidad de caracteres: ";
}
?>
<input type="text" value="0" name=caracteres size=4 style="background: transparent; border: none;">
</div>
<div class="d-flex justify-content-center mt-3 login_container">
<div class="col-md-6"><button type="submit" class="btn login_btn"><?php
if ($_POST['idioma']=='Maya')
{
echo "Túuxt a meyaj";
}
else{
echo "Enviar";
}
?></button></div>
</div>
</form>
</div>
</div>
</div>
</div>
<script>
contenido_textarea = ""
num_caracteres_permitidos = 200
function valida_longitud(){
num_caracteres = document.forms[0].comentario.value.length
if (num_caracteres > num_caracteres_permitidos){
document.forms[0].comentario.value = contenido_textarea
}else{
contenido_textarea = document.forms[0].comentario.value
}
if (num_caracteres >= num_caracteres_permitidos){
document.forms[0].caracteres.style.color="#ff0000";
}else{
document.forms[0].caracteres.style.color="#000000";
}
cuenta()
}
function cuenta(){
document.forms[0].caracteres.value=document.forms[0].comentario.value.length;
}
</script>
</body>
</html>
<!--
/* Coded by Ing. Ulises Morales Ramirez */
-->
<?php
include 'conexion.php';
$sql = "SELECT * FROM Preescolar";
$result1 = $conn->query($sql);
$sql = "SELECT * FROM Primaria";
$result2 = $conn->query($sql);
$sql = "SELECT * FROM Secundaria";
$result3 = $conn->query($sql);
$sql = "SELECT * FROM Media";
$result4 = $conn->query($sql);
$sql = "SELECT * FROM Superior";
$result5 = $conn->query($sql);
/*
if ($result->num_rows > 0) {
// output data of each row
while($row = $result->fetch_assoc()) {
echo "id: " . $row["id"]. " - Name: " . $row["firstname"]. " " . $row["lastname"]. "<br>";
}
} else {
echo "0 results";
}
$conn->close();*/
?>
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>Sin titulo</title>
<link rel="shortcut icon" href="images/cgeo.ico">
<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.1.3/css/bootstrap.min.css"
integrity="sha384-MCw98/SFnGE8fJT3GXwEOngsV7Zt27NXFoaoApmYm81iuXoPkFOJwJ8ERdknLPMO" crossorigin="anonymous">
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>
<link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.6.1/css/all.css"
integrity="sha384-gfdkjb5BdAXd+lj+gudLWI+BXq4IuLW5IT+brZEZsLFm++aCMlF1V92rMkPaX4PP" crossorigin="anonymous">
<link rel="stylesheet" type="text/css" href="ownStyle.css" media="screen"/>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script>
</head>
<body>
<!--div class="text-center" style="z-index: -1"><img src="images/header.png" width="800px"></div-->
<div class="container h-100">
<div class="d-flex justify-content-center h-100">
<div class="user_card">
<div class="d-flex justify-content-center">
<div class="brand_logo_container">
<img src="images/logo_geo.png" class="brand_logo" alt="Logo">
</div>
</div>
<div class=" justify-content-center container form_container">
<form method="post" action="lenguaje.php">
<div class="input-group">
<div class="input-group-append">
<span class="input-group-text"><i class="fas fa-search"></i></span>
</div>
<input type="text" autocomplete="on" list="Escuelas" name="escuela" id="input_escuela" class="form-control " value="" placeholder="Seleccione la clave o nombre de su escuela" required ">
<input type="hidden" name="clave_escuela" id="clave_escuela">
</div>
<datalist id="Escuelas">
<?php
while($row = $result1->fetch_assoc()) {
echo '<option value="'.utf8_encode($row["CV_CCT"]).'">'.utf8_encode($row["NOMBRECT"]).' <br>de '.utf8_encode($row["C_NOM_LOC"]).'</option>';
//echo '<option value="'.utf8_encode($row["NOMBRECT"]).'">de '.utf8_encode($row["C_NOM_LOC"]).' <br>clave: '.utf8_encode($row["CV_CCT"]).'</option>';
}
while($row = $result2->fetch_assoc()) {
echo '<option value="'.utf8_encode($row["CV_CCT"]).'">'.utf8_encode($row["NOMBRECT"]).' <br>de '.utf8_encode($row["C_NOM_LOC"]).'</option>';
}
while($row = $result3->fetch_assoc()) {
echo '<option value="'.utf8_encode($row["CV_CCT"]).'">'.utf8_encode($row["NOMBRECT"]).' <br>de '.utf8_encode($row["C_NOM_LOC"]).'</option>';
}
while($row = $result4->fetch_assoc()) {
echo '<option value="'.utf8_encode($row["CV_CCT"]).'">'.utf8_encode($row["NOMBRECT"]).' <br>de '.utf8_encode($row["C_NOM_LOC"]).'</option>';
}
while($row = $result5->fetch_assoc()) {
echo '<option value="'.utf8_encode($row["CV_CCT"]).'">'.utf8_encode($row["NOMBRECT"]).' <br>de '.utf8_encode($row["C_NOM_LOC"]).'</option>';
}
?>
</datalist>
<div class="mt-4">
<div class="d-flex text-center justify-content-center links">
<h1 id="nombre_escuela"></h1>
</div>
</div>
<div class="d-flex justify-content-center mt-3 login_container">
<button type="submit"class="btn login_btn">Siguiente</button>
</div>
</form>
</div>
</div>
</div>
</div>
<script>
$("#input_escuela").bind('input', function () {
$('#clave_escuela').val($('#input_escuela').val());
document.getElementById('clave_escuela').value=$('#input_escuela').val();
var valor = checkExists( $('#input_escuela').val());
//alert(valor);
var lastword = valor.split(" ").pop();
document.getElementById('input_escuela').value=valor;
$('#nombre_escuela').empty();
$('#nombre_escuela').append(valor);
});
function checkExists(inputValue) {
var x = document.getElementById("Escuelas");
var i;
var flag;
for (i = 0; i < x.options.length; i++) {
if(inputValue == x.options[i].value){
flag = x.options[i].text;
}
}
return flag;
}
</script>
</body>
</html>
<!--
/* Coded by Ing. Ulises Morales Ramirez */
-->
<?php
session_start();
include 'conexion.php';
echo $_SESSION['clave_escuela'];
echo $_POST['idioma'];
echo $_POST['nombre'];
echo $_POST['edad'];
echo $_POST['comentario'];
//$sql = "INSERT INTO `respuesta`(`id_respuesta`, `clave_escuela`, `idioma`, `nombre`, `edad`, `comentario`) VALUES (null ,".$_SESSION['clave_escuela'].",,,,)";
$sql = "INSERT INTO `respuesta`(`id_respuesta`, `clave_escuela`, `idioma`, `nombre`, `edad`, `comentario`) VALUES (null ,'".$_SESSION['clave_escuela']."','".$_POST['idioma']."','".$_POST['nombre']."',".$_POST['edad'].",'".$_POST['comentario']."')";
if ($conn->query($sql) === TRUE) {
echo "New record created successfully";
} else {
echo "Error: " . $sql . "<br>" . $conn->error;
}
$conn->close();
/* Esto producirá un error. Fíjese en el html
* que se muestra antes que la llamada a header() */
header('Location: salida.php?idioma='.$_POST['idioma']);
exit;
?>
\ No newline at end of file
<!--
/* Coded by Ing. Ulises Morales Ramirez */
-->
<?php
session_start();
if (isset($_POST['escuela'])) {
$_SESSION["escuela"] = $_POST['escuela'];
$_SESSION["clave_escuela"] = $_POST['clave_escuela'];
}
?>
<!DOCTYPE html>
<html>
<head>
<title>Sin titulo</title>
<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.1.3/css/bootstrap.min.css"
integrity="sha384-MCw98/SFnGE8fJT3GXwEOngsV7Zt27NXFoaoApmYm81iuXoPkFOJwJ8ERdknLPMO" crossorigin="anonymous">
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>
<link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.6.1/css/all.css"
integrity="sha384-gfdkjb5BdAXd+lj+gudLWI+BXq4IuLW5IT+brZEZsLFm++aCMlF1V92rMkPaX4PP" crossorigin="anonymous">
<link rel="stylesheet" type="text/css" href="ownStyle.css" media="screen"/>
</head>
<body>
<div class="container h-100">
<!--div class="text-center" style="z-index: -1"><img src="images/header.png" width="800px"></div-->
<div class="d-flex justify-content-center h-100">
<div class="user_card">
<div class="d-flex justify-content-center">
<div class="brand_logo_container">
<img src="images/logo_geo.png" class="brand_logo" alt="Logo">
</div>
</div>
<div class="d-flex justify-content-center form_container">
<form action="encuesta.php" method="post">
<input type="hidden" name="escuela" value="<?= $_SESSION["escuela"] ?>">
<div class="mt-4 text-center" style="margin-top: -20px!important;">
<h1>Escuela:</h1>
<h2><?= $_SESSION["escuela"] ?></h2>
<h4>Clave:</h4>
<h4><?= $_SESSION["clave_escuela"] ?></h4>
<div class="d-flex justify-content-center links" style="margin-top: 100px!important;">
¿EN QUÉ LENGUAJE DESEA CONTESTAR?
<br>
¿BA'AX TI T'AANIL A K'AAT A NÚUKTIK?
</div>
</div>
<div class="d-flex justify-content-center mt-3 login_container">
<div class="col-md-6">
<button type="submit" name="idioma" value="Español" class="btn login_btn">Español</button>
</div>
<div class="col-md-6">
<button type="submit" name="idioma" value="Maya" class="btn login_btn">Maya</button>
</div>
</div>
</form>
</div>
</div>
</div>
</div>
</body>
</html>
/* Coded by Ing. Ulises Morales Ramirez */
body,
html{
background-image: url("images/background.jpg");
margin: 0;
height: 100%;
border: 30px solid transparent;
padding: 20px;
-webkit-border-image: url("images/background2.png") 40 round; /* Safari 3.1-5 */
-o-border-image: url("images/background2.png") 40 round; /* Opera 11-12.1 */
border-image: url("images/background2.png") 40 round;
}
.user_card {
height: 600px;
width: 550px;
margin-top: auto;
margin-bottom: auto;
background: #f39c12;
position: relative;
display: flex;
justify-content: center;
flex-direction: column;
padding: 10px;
box-shadow: 0 4px 8px 0 rgba(0, 0, 0, 0.2), 0 6px 20px 0 rgba(0, 0, 0, 0.19);
-webkit-box-shadow: 0 4px 8px 0 rgba(0, 0, 0, 0.2), 0 6px 20px 0 rgba(0, 0, 0, 0.19);
-moz-box-shadow: 0 4px 8px 0 rgba(0, 0, 0, 0.2), 0 6px 20px 0 rgba(0, 0, 0, 0.19);
border-radius: 5px;
}
.brand_logo_container {
position: absolute;
height: 170px;
width: 170px;
top: -75px;
border-radius: 50%;
background: #fff;
padding: 10px;
text-align: center;
}
.brand_logo {
height: 150px;
width: 150px;
border-radius: 50%;
border: 2px solid white;
}
.form_container {
margin-top: 60px;
}
.login_btn {
width: 100%;
background: #c0392b !important;
color: white !important;
}
.login_btn:focus {
box-shadow: none !important;
outline: 0px !important;
}
.login_container {
padding: 0 2rem;
}
.input-group-text {
background: #c0392b !important;
color: white !important;
border: 0 !important;
border-radius: 0.25rem 0 0 0.25rem !important;
}
.input_user,
.input_pass:focus {
box-shadow: none !important;
outline: 0px !important;
}
.custom-checkbox .custom-control-input:checked~.custom-control-label::before {
background-color: #c0392b !important;
}
input[type=number]::-webkit-inner-spin-button,
input[type=number]::-webkit-outer-spin-button {
-webkit-appearance: none;
margin: 0;
}
\ No newline at end of file
<!--
/* Coded by Ing. Ulises Morales Ramirez */
-->
<!DOCTYPE html>
<html>
<head>
<title>Sin titulo</title>
<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.1.3/css/bootstrap.min.css"
integrity="sha384-MCw98/SFnGE8fJT3GXwEOngsV7Zt27NXFoaoApmYm81iuXoPkFOJwJ8ERdknLPMO" crossorigin="anonymous">
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>
<link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.6.1/css/all.css"
integrity="sha384-gfdkjb5BdAXd+lj+gudLWI+BXq4IuLW5IT+brZEZsLFm++aCMlF1V92rMkPaX4PP" crossorigin="anonymous">
<link rel="stylesheet" type="text/css" href="ownStyle.css" media="screen"/>
</head>
<body onload="redireccion();">
<div class="container h-100">
<!--div class="text-center" style="z-index: -1"><img src="images/header.png" width="800px"></div-->
<div class="d-flex justify-content-center h-100">
<div class="user_card">
<div class="d-flex justify-content-center">
<div class="brand_logo_container">
<img src="images/logo_geo.png" class="brand_logo" alt="Logo">
</div>
</div>
<div class="d-flex justify-content-center links" style="margin-top: 100px!important;">
<?php
if ($_GET['idioma']=='Maya')
{
echo "<h2>Yuum bo'otik a núuk t'aan</h2>";
}
else{
echo "<h2>Gracias por contestar</h2>";
}
?>
</div>
<div class="d-flex justify-content-center links" style="margin-top: 100px!important;">
<?php
if ($_GET['idioma']=='Maya')
{
echo "tun líik'esik respuestas...";
}
else{
echo "guardando respuestas...";
}
?>
</div>
<div class="d-flex justify-content-center links" style="margin-top: 100px!important;">
<img src="images/wait.gif" width="40px">
</div>
</div>
</div>
</div>
<script>
function redireccion() {
setTimeout(function () {
window.location.replace("lenguaje.php");
}, 4000);
}
</script>
</body>
</html>
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment