Jump to content

devang23

Members
  • Posts

    42
  • Joined

  • Last visited

    Never

Profile Information

  • Gender
    Not Telling

devang23's Achievements

Member

Member (2/5)

0

Reputation

  1. Anyone know of a free webhost that has, mysql, ftp....basically something that will let me have my own wordpress on their.
  2. I'm having trouble installing the latest WordPress to 000webhost, i've read that it should let you run it, but I cant make it work for some reason.
  3. anyone know of any free webhost that offer servers, ect? i used 000webhost, but im trying to install Wordpress and it doesnt allow me to. Is there a Free web hosting place that will let me set up WordPress
  4. i'm not sure why, but i'm having trouble installing the new WordPress to 000webhost, If anyone knows about his, and can help, id appreciate it, thank you
  5. resource(5) of type (mysql link)
  6. huh its a mysql error tho <html> <head> <title>Adding a User </title> </head> <body> <?php ini_set('display_errors', '1'); error_reporting(E_ALL); $conn = mysql_connect("mysql4.000webhost.com","a3213677_dolphin","*********")or die("Try Again Punk"); var_dump($conn); $db = mysql_select_db("a3213677_snorre",$conn)or die("NOOPE"); $firstname = isset($_POST['firstname']) ? mysql_real_escape_string($_POST['firstname']) : ''; $lastname = isset($_POST['lastname']) ? mysql_real_escape_string($_POST['lastname']) : ''; $username = isset($_POST['username']) ? mysql_real_escape_string($_POST['username']) : ''; $password = isset($_POST['password']) ? mysql_real_escape_string($_POST['password']) : ''; if( (!$firstname) or (!$lastname) or (!$username) or (!$password) ) { echo <<< EOS Please enter all new user details <form action="{$_SERVER['PHP_SELF']}" method="post"> First Name: <input type="text" name="firstname" value="$firstname"><br /> Last Name: <input type="text" name="lastname" value="$lastname"><br /> UserName: <input type="text" name="username" value="$username"><br /> PassWord: <input type="password" name="password" value="$password"><br /> <input type="submit" value="Submit"> </form> EOS; } else { $sql = "insert into `User Table` (`first name`,`last name`,username,password) values ('$firstname','$lastname','$username','$password')"; if($result) { echo("New User $username added"); } } ?> </body> </html>
  7. i have this script and everytime i load it to see the information that was entered into the first name part doesnt show up, and it says )able at the top. <html><head><title>I'm a GENUIS</title></head> <body> <?php $conn=mysql_connect("mysql4.000webhost.com","a3213677_dolphin","hello23") or die(mysql_error()); $rs = mysql_select_db("a3213677_snorre", $conn) or die("NOOOPE"); $sql="select * from `User Table` Where 1"; $rs=mysql_query($sql,$conn) or die(mysql_error());; $list = "<table border=\"1\" cellpadding=\"2\">"; $list.="<tr><th><First Name</th>"; $list.="<th>Last Name</th>"; $list.="<th>UserName</th>"; $list.="<th>PassWord</th></tr>"; while($row= mysql_fetch_array($rs) ) { $list .= "<tr>"; $list .= "<td>".$row["first_name"]."</td>"; $list .= "<td>".$row["last_name"]."</td>"; $list .= "<td>".$row["username"]."</td>"; $list .= "<td>".$row["password"]."</td>"; $list .= "</tr>"; } $list .= "<\table"; echo($list); ?> </body><html>
  8. the page just refreshes itself...it doesnt reply that the data was submitted, and thanks for the last code and it work, its just that the info didnt show up, and im guessing its cause of the first code?
  9. for some reason this script continues to give me a mysql syntax PHP Error Message Parse error: syntax error, unexpected T_STRING in /home/a3213677/public_html/workpart2.php on line 10 <html><head><title>I'm a GENUIS</title></head> <body> <?php $conn=mysql_connect("mysql4.000webhost.com","a3213677_dolphin","******") or die(mysql_error()); $rs = mysql_select_db("a3213677_snorre", $conn) or die("NOOOPE"); $sql="SELECT * FROM `User Table`; $rs=mysql_query($sql,$conn) or die(mysql_error());; $list = "<table border=\"1\" cellpadding=\"2\">"; $list.="<tr><th><First Name</th>"; $list.="<th>Last Name</th>"; $list.="<th>UserName</th>"; $list.="<th>PassWord</th></tr>"; while($row= mysql_fetch_array($rs) ) { $list .= "<tr>"; $list .= "<td>".$row["first_name"]."</td>"; $list .= "<td>".$row["last_name"]."</td>"; $list .= "<td>".$row["username"]."</td>"; $list .= "<td>".$row["password"]."</td>"; $list .= "</tr>"; } $list .= "<\table"; echo($list); ?> </body><html>
  10. i tried that it didnt do anything, still says i got osmething wrong in line 10(t_variable)
  11. heres what came up when i changed the SELECT Parse error: syntax error, unexpected T_STRING in /home/a3213677/public_html/workpart2.php on line 10 <html><head><title>I'm a GENUIS</title></head> <body> <?php $conn=mysql_connect("mysql4.000webhost.com","a3213677_dolphin","hello23") or die(mysql_error()); $rs = mysql_select_db("a3213677_snorre", $conn) or die("NOOOPE"); $sql="SELECT * FROM `User Table`; $rs=mysql_query($sql,$conn) or die(mysql_error());; $list = "<table border=\"1\" cellpadding=\"2\">"; $list.="<tr><th><First Name</th>"; $list.="<th>Last Name</th>"; $list.="<th>UserName</th>"; $list.="<th>PassWord</th></tr>"; while($row= mysql_fetch_array($rs) ) { $list .= "<tr>"; $list .= "<td>".$row["first_name"]."</td>"; $list .= "<td>".$row["last_name"]."</td>"; $list .= "<td>".$row["username"]."</td>"; $list .= "<td>".$row["password"]."</td>"; $list .= "</tr>"; } $list .= "<\table"; echo($list); ?> </body><html>
  12. Im trying to set this up so ppl can input simple info, fistname,lastnight,username,password.....then i wanna store this info into mysql....and then i want to be able to pull the info that was saved and look at it. im learning php and mysql for my business, and i want to set it up online. im kinda new at this, and a little lost, would you like to see both scripts im working with?
  13. i have 2 scripts and one of them is to send info into mysql and the other one is to display it. the problem with this script is that the page just refreshes, and i believe it doesnt store the information that im trying to store. <html><head><title>Adding a User </title></head> <body> <?php if( (!$firstname) or (!$lastname) or (!$username) or (!$password) ) { $form ="Please enter all new user details"; $form.="<form action=\"$PHP_SELF\""; $form.=" method=\"post\">First Name: "; $form.="<input type=\"text\" name=\firstname\""; $form.=" value=\"$firstname\"><br>Last Name: "; $form.="<input type=\"text\" name=\"lastname\""; $form.=" value=\"$lastname\"><br>UserName: "; $form.="<input type=\"text\" name=\"username\""; $form.=" value=\"$username\"><br>PassWord: "; $form.="<input type=\"text\" name=\"password\""; $form.=" value=\"$password\"><br>"; $form.="<input type=\"submit\" value=\"Submit\">"; $form.="</form>"; echo($form); } else { $conn = mysql_connect("mysql4.000webhost.com","a3213677_dolphin","******")or die("Try Again Punk"); $db = mysql_select_db("a3213677_snorre",$conn)or die("NOOPE"); $sql = "insert into User Table (first_name,last_name,username,password) values (\"$firstname\",\"$lastname\",\"$username\",password(\"$password\") )"; $result = mysql_query($sql,$conn); if($result) { echo("New User $username ADDED DUH"); } } ?> </body></html> and the 2nd one i get this error message "You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ''User Table' Where 1' at line 1" <html><head><title>I'm a GENUIS</title></head> <body> <?php $conn=mysql_connect("mysql4.000webhost.com","a3213677_dolphin","********") or die(mysql_error()); $rs = mysql_select_db("a3213677_snorre", $conn) or die("NOOOPE"); $sql="select * from 'User Table' Where 1"; $rs=mysql_query($sql,$conn) or die(mysql_error());; $list = "<table border=\"1\" cellpadding=\"2\">"; $list.="<tr><th><First Name</th>"; $list.="<th>Last Name</th>"; $list.="<th>UserName</th>"; $list.="<th>PassWord</th></tr>"; while($row= mysql_fetch_array($rs) ) { $list .= "<tr>"; $list .= "<td>".$row["first_name"]."</td>"; $list .= "<td>".$row["last_name"]."</td>"; $list .= "<td>".$row["username"]."</td>"; $list .= "<td>".$row["password"]."</td>"; $list .= "</tr>"; } $list .= "<\table"; echo($list); ?> </body><html>
  14. atleast im making some kind of progress, thanks for that, but now it said this You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ''User Table' Where 1' at line 1 should i post both scripts im working with, so you have a better knowledge of what im doing?
×
×
  • 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.