[#] hm X_Shell Backd00r [#]

Current Path : /var/www/clients/client35/web46/web/encuesta/admin/
Upload File :
Current File : /var/www/clients/client35/web46/web/encuesta/admin/encuestas.php

<?php 
      session_start();

  if (empty($_SESSION['id_usu'])) {
     header('Location: index.php');
     }
?>

<!doctype html>
<!--[if lt IE 7]>      <html class="no-js lt-ie9 lt-ie8 lt-ie7" lang=""> <![endif]-->
<!--[if IE 7]>         <html class="no-js lt-ie9 lt-ie8" lang=""> <![endif]-->
<!--[if IE 8]>         <html class="no-js lt-ie9" lang=""> <![endif]-->
<!--[if gt IE 8]><!--> <html class="no-js" lang="" ng-app="APPCBT"> <!--<![endif]-->
    <head>
        <meta charset="utf-8">
        <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
        <title></title>
        <meta name="description" content="">
        <meta name="viewport" content="width=device-width, initial-scale=1">

        <link rel="stylesheet" href="../css/angular-material.min.css">
        <link rel="stylesheet" href="../css/bootstrap.min.css">
        <link rel="stylesheet" href="../css/bootstrap-theme.min.css">
        <link rel="stylesheet" href="../css/main.css">
    
        <script src="../js/vendor/modernizr-2.8.3.min.js"></script>

        <!--- AngularJS -->
        <script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.5.3/angular.min.js"></script>
        <script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.4.5/angular-animate.min.js"></script>  
        <script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.4.5/angular-aria.min.js"></script>  
        <script src="https://ajax.googleapis.com/ajax/libs/angular_material/1.0.7/angular-material.min.js"></script>
        <script src="https://code.angularjs.org/1.5.3/angular-messages.js"></script>  

    </head>
    <body style="background-color:#fff !important; background-image:inherit; ">
        <!--[if lt IE 8]>
            <p class="browserupgrade">You are using an <strong>outdated</strong> browser. Please <a href="http://browsehappy.com/">upgrade your browser</a> to improve your experience.</p>
        <![endif]-->

            <div  ng-controller="CtrlTest" ng-cloak>
                <div class="container-full bg">
                    <div class="container">
                        <img ng-src="../img/banner-aut-her.jpg" alt="Logo" class="img-responsive">
                    </div>
                </div>
                <div class="container-full">

                <div class="dropdown btn-modal color-pink">
                  <button class="btn dropdown-toggle" type="button" id="dropdownMenu1" data-toggle="dropdown" aria-haspopup="true" aria-expanded="true" style="color: #c04375;">
                 <span class="glyphicon glyphicon-user"></span>&nbsp;&nbsp;<span class="caret"></span>&nbsp;&nbsp;usuario: <?php echo $_SESSION['user1'];?>
                    
                  </button>
                  <ul class="dropdown-menu" aria-labelledby="dropdownMenu1">
                    <li><a  class="color-pink" href="../app/controller/cerrar_session.php">Cerrar Sesion</a></li>
                  </ul>
                </div>
                
                <div class="container">
                    <div class="form-group">
                        <div class="input-group">
                            <span class="input-group-addon" id="basic-addon1"><i class="glyphicon glyphicon-search"></i></span>
                            <input type="text" class="form-control" placeholder="Filtrar Busqueda" id="kwd_search">
                        </div>
                    </div>
                </div>

                <?php 
                    require_once '../app/model/SaveTest.model.php';
                    $objTest = new Tests();

                    $tests = $objTest->registrosEncuesta();
                    $i = 0;
                    
                    $o = '';
                    $tdo = '';
                    
                    $tabla .='<div class="table-responsive">';
                    $tabla .= '<table class="table table-striped">';
                        

                    $tabla .= '<thead><tr>';
                        $tabla .= '<th>Nombre</th>';
                        $tabla .= '<th>Correo</th>';
                        $tabla .= '<th>¿Cuántos años tienes?</th>';
                        $tabla .= '<th>¿Con quién vienes?</th>';
                        $tabla .= '<th>¿Te gustaría que en nuestros Eventos de Pista Abierta hubiera un tiempo sólo para las mujeres en el que puedan correr en auto dentro de la pista?</th>';
                        $tabla .= '<th>¿Te gustaría que hubiera actividades para ti en lo que ellos están en pista?</th>';
                        $tabla .= '<th>¿Cuáles de estas actividades te gustaría que hubieran?</th>';
                        $tabla .= '<th>¿Te gustaría pagar una cantidad fija y que puedas participar en todas las actividades o realizar pago individual?</th>';
                    $tabla .= '</tr></thead>';


                    

                    $tabla .= '<tbody>';
                    foreach ($tests as $test) {
                        $tabla .= '<tr>';
                            $tabla .= '<td>'.$test['Nombre'].'</td>';
                            $tabla .= '<td>'.$test['Email'].'</td>';
                        foreach(json_decode($test['Respuestas']) as $r){
                            if(is_array($r->respuesta)){
                                $tabla .= '<td>';
                                    $tabla .= '<ul>';
                                foreach ($r->respuesta as $valor) {
                                    $tabla .= '<li>';
                                        $tabla .= ($valor == 'Otras')? $valor.':&nbsp;'.$r->otro : $valor;
                                    $tabla .= '</li>';
                                }
                                    $tabla .= '</ul>';
                                $tabla .= '</td>';
                            }else{
                                $tabla .=  '<td>'.$r->respuesta.'</td>';
                            }
                        }
                        $tabla .= '</tr>';
                    }
                    $tabla .= '</tbody>';
                    $tabla .= '</table>';
                    $tabla .= '</div>';

                    echo $tabla;                
                ?>
                </div>
                <div class="container-full bg-b">
                    <div class="container">
                        <footer class="footer">
                           <img src="../img/banner-footer-her.jpg" alt="" class="img-responsive">
                        </footer>
                    </div>
                </div>
            </div>

        
        <!-- /container -->        
        <script src="//ajax.googleapis.com/ajax/libs/jquery/1.11.2/jquery.min.js"></script>
        <script>window.jQuery || document.write('<script src="js/vendor/jquery-1.11.2.min.js"><\/script>')</script>
        <script src="../js/vendor/bootstrap.min.js"></script>
        <script src="../js/main.js"></script>
        <script>
            $(document).ready(function(){
                $("#kwd_search").keyup(function(){
                    if( $(this).val() != ""){
                        $("table tbody>tr").hide();
                        $("table td:contains-ci('" + $(this).val() + "')").parent("tr").show();
                    }else{
                        $("table tbody>tr").show();
                    }
                });
            });
            
            $.extend($.expr[":"],{ "contains-ci": function(elem, i, match, array){
                return (elem.textContent || elem.innerText || $(elem).text() || "").toLowerCase().indexOf((match[3] || "").toLowerCase()) >= 0;}
            });

        </script>

    </body>
</html>

Mr.hm X_Shell Backd00r 1.0, Coded By Mr.hm X_Shell Backd00r