Jump to content

Form problems


blink359

Recommended Posts

Ive been trying to get my PhP for account creation working so i started simple again to make it easier to find problem here it is:

Parse error: syntax error, unexpected T_ENCAPSED_AND_WHITESPACE, expecting T_STRING or T_VARIABLE or T_NUM_STRING in /home2/worldsof/public_html/random/test.php on line 14

<?php
include('config.php');

mysql_connect($dbhost, $dbuser, $dbpass);
mysql_select_db($dbname);

$success = true; 
$problemMessage = ""; 
if (isset($_POST['Submit'])) 

        if ($success) 
        { 
            echo "Valid New Account Entry<br />";
            $result = mysql_query("INSERT INTO `accounts` VALUES ('', '$_POST['user']', '$_POST['pass2']', '', '', '0', '', '', '', '$_POST['flag']', 'enUS', '0', '0', null);") or die("Error: (" . mysql_errno() . ") " . mysql_error());

        } 

	$row = mysql_fetch_array( $result );

} 

?>
<html>
<head>
<title>Account Creation Page</title>
</head>
<body>
<form>
          Account Creation Page<br> 
          Username: 
          <input name="user" type="text"/>
          <br>  
          Password: 
          <input name="pass" type="text"/>
          <br>  
          Repeat Password: 
          <input name="pass2" tpye="text"/>
          <br />
          Pre TBC
          <input type="radio" name="flag" value="0">
            <br>
          TBC Enabled
          <input type="radio" name="flag" value="8">
          <br>
          Wotlk Enabled
          <input type="radio" name="flag" value="24">
          <br>
          
          <input name="Submit" type="submit" value="submit" /> 
            </p>
        <imput name="reset" type="reset" value="reset" /> 


</form>
</body>
</html>

Link to comment
https://forums.phpfreaks.com/topic/155883-form-problems/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • 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.