Jump to content

Error in my welcome.php while running it..


gautamphp

Recommended Posts

Hi,

 

I make a simple login form and save it as:- 1.php

 

Codding is as :--

 

<html>

<body>

 

<h3>Logon Page</h3>

 

<form name="Logon" action="welcome.php" method="post">

  <table border="0">

  <tr>

    <td>Account: </td>

    <td><input type="text" name="Account" size="10"></td>

  </tr>

  <tr>

    <td>Password: </td>

    <td><input type="password" name="Password" size="10"></td>

  </tr>

  </table>

  <input type="submit" name="SubmitButton" value="Submit">

</form>

 

</body>

</html>

 

but when i click on Submit button it gives an erron in welcome.php file which coding is as:--

 

<?php

$a = "$_post['Account']";

$p = "$_post['Password']";

 

echo "Account:", $a;<br>

echo "Password:", $p;

 

?>

 

So, plz tell me why here an error is occure and do't display welcome.php file while clicking on Submit button from 1.php file.

 

 

Thanks.........

 

Jitu

 

 

Link to comment
Share on other sites

full code

<html>
<body>

<h3>Logon Page</h3>

<form name="Logon" action="welcome.php" method="post">
  <table border="0">
  <tr>
    <td>Account: </td>
    <td><input type="text" name="Account" size="10"></td>
  </tr>
  <tr>
    <td>Password: </td>
    <td><input type="password" name="Password" size="10"></td>
  </tr>
  </table>
  <input type="submit" name="SubmitButton" value="Submit">
</form>

</body>
</html>

<?php
$a = $_POST['Account'];
$p = $_POST['Password'];

echo "Account:, $a";
echo "Password:, $p";

?>

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.