第七色在线视频,2021少妇久久久久久久久久,亚洲欧洲精品成人久久av18,亚洲国产精品特色大片观看完整版,孙宇晨将参加特朗普的晚宴

為了賬號(hào)安全,請(qǐng)及時(shí)綁定郵箱和手機(jī)立即綁定
已解決430363個(gè)問(wèn)題,去搜搜看,總會(huì)有你想問(wèn)的

顯示提交的數(shù)據(jù)到日志時(shí)出現(xiàn)問(wèn)題

顯示提交的數(shù)據(jù)到日志時(shí)出現(xiàn)問(wèn)題

PHP
翻過(guò)高山走不出你 2022-12-23 13:05:39
<script>function login() {  var userN = document.getElementById("userN").value;  var pin = document.getElementById("pin").value;  if (userN == "") {    alert("User name not entered");    document.getElementById("userN").focus();    }    else if (pin == "") {      alert("PIN Number not entered");      document.getElementById("pin").focus();      }      else {        var userAccount = "User Name:" + userN + "\n" +          "Pin:" + pin;        alert("userAccount");      }    }  </script></head><body>  <h2>Please enter your User Name and PIN:</h2>  <form name="formLogin" action="">    <action="loginLog.php" method="post">    <p><label for="userN">User Name: </label>      <input type="text" name="userN" id="userN" size="20" maxlength="8" tabindex="1"></p>    <p><label for="pin">PIN Number: </label>      <input type="password" name="pin" id="pin" size="20" maxlength="8" tabindex="2"></p>    <input type="submit" onclick="return login();" />    <input type="reset" onclick="document.formLogin.userN.focus();" />  </form>我在使用 $_Post 捕獲和回顯以顯示在登錄頁(yè)面上提交的數(shù)據(jù)時(shí)遇到問(wèn)題。我不確定在登錄頁(yè)面上獲取此數(shù)據(jù)以推送到 loginLog.php 我缺少什么這是我的 loginLog.php 文件<body>Welcome<?php    echo $_POST["userN"];?><?php    echo $_POST["pin"];?></body>
查看完整描述

1 回答

?
元芳怎么了

TA貢獻(xiàn)1798條經(jīng)驗(yàn) 獲得超7個(gè)贊

不要忘記添加method具有以下值的屬性post:


<form name="formLogin" action="path/to/yourfile/loginLog.php" method="post">

    <action="loginLog.php" method="post">

    <p><label for="userN">User Name: </label>

      <input type="text" name="userN" id="userN" size="20" maxlength="8" tabindex="1"></p>

    <p><label for="pin">PIN Number: </label>

      <input type="password" name="pin" id="pin" size="20" maxlength="8" tabindex="2"></p>


    <input type="submit" onclick="return login();" />

    <input type="reset" onclick="document.formLogin.userN.focus();" />

  </form>


查看完整回答
反對(duì) 回復(fù) 2022-12-23
  • 1 回答
  • 0 關(guān)注
  • 103 瀏覽

添加回答

舉報(bào)

0/150
提交
取消
微信客服

購(gòu)課補(bǔ)貼
聯(lián)系客服咨詢優(yōu)惠詳情

幫助反饋 APP下載

慕課網(wǎng)APP
您的移動(dòng)學(xué)習(xí)伙伴

公眾號(hào)

掃描二維碼
關(guān)注慕課網(wǎng)微信公眾號(hào)