Warning: file_get_contents(/data/phpspider/zhask/data//catemap/6/opengl/4.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Javascript jquerymobile+;php post问题_Javascript_Php_Jquery_Html_Jquery Mobile - Fatal编程技术网

Javascript jquerymobile+;php post问题

Javascript jquerymobile+;php post问题,javascript,php,jquery,html,jquery-mobile,Javascript,Php,Jquery,Html,Jquery Mobile,亲爱的,我对jQuery Mobile和PHP有一个非常奇怪的问题,我需要做一些非常简单的事情,我有一个带有两个输入值(name和pass)的表单,表单被提交到“questions.PHP”,但是当我打印帖子(print_r($_post))时,这是空的,但是如果我删除jQuery Mobile的一些脚本,这篇文章附带了我需要的信息,我不知道为什么它不能与3个脚本一起工作 inicio.php <?php include("header.php");?> <?php in

亲爱的,我对jQuery Mobile和PHP有一个非常奇怪的问题,我需要做一些非常简单的事情,我有一个带有两个输入值(name和pass)的表单,表单被提交到“questions.PHP”,但是当我打印帖子(print_r($_post))时,这是空的,但是如果我删除jQuery Mobile的一些脚本,这篇文章附带了我需要的信息,我不知道为什么它不能与3个脚本一起工作

inicio.php

   <?php include("header.php");?>
<?php include("conexion.php");?>
<?php
$query = "select * from usuario, categoria where usuario.id_categoria = categoria.categoria_id";
$result = $conn->query($query);
?>
<body>
    <!-- Pagina Inicio (login) -->
    <div data-role="page" id="home">
      <div data-role="main" class="ui-content">
        <div id="inicio">  
        <div id="logo"><img src="images/logo.png" alt="logo" width="100%" height="" /></div>

        <form method="post" action="preguntas.php" data-ajax="false">
            <label for="user">Selecciona tu usuario <a href="#usuario" data-rel="popup" class="ui-btn ui-btn-inline ui-icon-info ui-btn-icon-notext ui-corner-all ui-shadow ui-nodisc-icon ui-alt-icon" data-transition="flip">Pop Up Info</a></label>

            <!-- Pop Up Usuario-->
                <div data-role="popup" id="usuario">
                    <a href="#" data-rel="back" class="ui-btn ui-corner-all ui-shadow ui-btn ui-icon-delete ui-btn-icon-notext ui-btn-right">Close</a>
                    <p>Seleciona tu nombre e ingresa tu </p>
                    <p>contraseña para registrar tu puntaje</p>
                </div>
            <!-- FIN Pop Up Usuario-->
                <select name="user" id="user">    
                <?php while($row = $result->fetch_assoc()){ ?>    
                <optgroup label="<?=$row['categoria']?>">
                  <option value="<?=$row['id']?>"><?=$row['nombre']?> <?=$row['apellido']?></option>
                </optgroup>
                <?php }?>
                </select>
                <br><br>
            <label for="pswd">Ingresa tu contraseña</label>
            <input type="password" name="passw" id="pswd" data-clear-btn="true">
            <button type="submit" class="ui-btn ui-icon-home ui-btn-icon-left" id="home" data-transition="slide" value="Ingresar">Ingresar</button>
         </form>

        </div>
              </div>

      <div data-role="footer" style="text-align:center; background: transparent; border: 0;" data-position="fixed">
            <div data-role="controlgroup" data-type="horizontal" style="margin:0">
                <a href="#home" class="ui-btn" id="barrabajo">Juego</a>
                <a href="#" class="ui-btn" id="barrabajo">Ranking</a>
                <a href="#" class="ui-btn" id="barrabajo">Videos</a>
            </div>
        </div>
    </div>

乌萨里奥之旅
名称为Seleciona tu nombre e ingresa tu

图蓬塔耶的对峙



安格拉·图康瑟斯·尼娜 安格尔
questions.php

    <?php
include "conexion.php";
$id = $_POST['user'];
$query = "SELECT * FROM categoria, preguntas,usuario where usuario.id_categoria = categoria.categoria_id and categoria.categoria_id = preguntas.id_categoria and usuario.id = '$id' order by rand()";
$result = $conn->query($query); 
?>
<!DOCTYPE html>
<html lang="es">
<head>
    <title>Sky Icargo - El Juego</title>

    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
    <link rel="stylesheet" type="text/css" href="style.css">
    <link rel="stylesheet" type="text/css" href="mobile/addtohomescreen.css">
    <script src="//use.typekit.net/eev7vgf.js"></script>
    <script>try{Typekit.load();}catch(e){}</script>
    <script src="mobile/addtohomescreen.js"></script>
    <script>
        addToHomescreen();
    </script>

    <meta name="apple-mobile-web-app-capable" content="yes" /> 
    <link rel="apple-touch-icon" href="images/custom_icon.png">
    <meta name="apple-mobile-web-app-title" content="Sky iCargo">
    <meta name="apple-mobile-web-app-status-bar-style" content="black">


</head>

<body>
    <div data-role="page" id="pagetwo">
        <div data-role="header">
            <div data-role="header">
              <a href="#home" class="ui-btn ui-icon-home ui-btn-icon-left" id="home" data-transition="slide" data-direction="reverse">Home</a>
              <h1 id="loguito"><img src="images/loguito.png" alt="logo" width="100%" height="" /></h1>
            </div>
        </div>

        <div data-role="main" class="ui-content">
            <?php while($row = $result->fetch_assoc()){ ?> 
            <form method="post" action="puntaje">
                <div>
                        <?php echo $row['pregunta'];?>
                    <?php }?> 
                </div>
            </form>     
        </div>

        <div data-role="footer" style="text-align:center;">
            <div data-role="controlgroup" data-type="horizontal">
                <a href="#" class="ui-btn" data-position="fixed" data-fullscreen="true">Juego</a>
                <a href="#" class="ui-btn" data-position="fixed" data-fullscreen="true">Ranking</a>
                <a href="#" class="ui-btn" data-position="fixed" data-fullscreen="true">Videos</a>
            </div>
        </div>
    </div> 


如果我删除questions.php中的
或这三个文件中的另一个,但如果我离开这三个文件不起作用,请有人帮助我。

你能展示你的php代码的相关部分吗?你能添加你提交的表单部分以及它提交的代码吗?我已经发布了完整的两个.php文件