Search results

  1. S

    Error

    Im getting this error from a page im building: Parse error: syntax error, unexpected T_VARIABLE in C:\xampp\htdocs\llot.php on line 133 Line 133 = $db = "INSERT INTO `lottery` (`id`, `username`, `num`) VALUES ('$uid','$id','$finalnum');" so what could be causing this? and a...
  2. S

    SQL query

    uhm im getting this error now: Parse error: syntax error, unexpected T_VARIABLE in C:\xampp\htdocs\llot.php on line 133 Line 133 = $db = ("INSERT INTO `lottery` (`id`, `username`, `num`) VALUES ('$uid','$id','$finalnum');");
  3. S

    SQL query

    thanks alot :)
  4. S

    SQL query

    so i could do this: if(isset($_POST['buttonname']) { $db = "INSERT INTO `lottery` (`id`, `username`, `num`) VALUES ('$uid','$id','$finalnum');" $db2 = "UPDATE `users` SET `lotto_points`='0' WHERE (`id`='$uid');" } else
  5. S

    SQL query

    so do i replace $query with $db? and im guessing this isnt for multi query's? likesend multiply at the same time?
  6. S

    SQL query

    Im making a lotto system, and I have made most of the code but I just cant figure out how to send the SQL query into the DB to record the number that user choose/and to remove the appropriate number of lotto points(made a currency as well). The query codes are: <?php $db =...
  7. S

    how do I execute an SQL query in PHP

    no im trying to create a lotto system, i got everything but how to send the 2 query's (1 for username id and number) and (to deduct the coins)
  8. S

    how do I execute an SQL query in PHP

    ok, and do you know how i could execute the sql querys when the users press's the button?
  9. S

    how do I execute an SQL query in PHP

    but how would i choose a specific user when they enter a page?
  10. S

    how do I execute an SQL query in PHP

    so i was wondering if someone could make a php code to run an SQL query when the user clicks a button. I have written the sql query in php already i just have no clue how to excute it, also could someone tell me if this php code works? : $Suser = ('"/userme.php"'); ^^^^^^^^^ this code is to...
  11. S

    Is There anyway to stop Dos Attacks?

    block the ip thats dosing
  12. S

    SQL error... agian

    Im getting this SQL error: Warning: mysql_fetch_object(): supplied argument is not a valid MySQL result resource Notice: Trying to get property of non-object in $row = mysql_fetch_object($credits); $credits = $row->credits; Im coding a simple lottery system if your...
  13. S

    SQL error

    ill try that thanks :) (hopefully it works) whoooo thanks sooo much :)
  14. S

    SQL error

    it wasnt the " ' ", and by giving $id a value did you mean like in the db or.....?
  15. S

    SQL error

    im making a lottery system and im getting this error: mysql_fetch_object(): supplied argument is not a valid MySQL result resource the line thats causing it is: $credits = mysql_query("SELECT * FROM users WHERE `id` = '$id'"); $row = mysql_fetch_object($credits); << this...
Top