Jump to content

berry05

Members
  • Posts

    204
  • Joined

  • Last visited

    Never

Everything posted by berry05

  1. Hello, I have a php code that shows the field of a table and next to each field is a checkbox...when i check one box the other one checks also..here's a piece of the code.. echo $row['item'] ."<input type='checkbox' name='checkbox' id='checkbox'>" . "<BR />" ; any help would be great! thanks!
  2. here's a script i have for baby math... but now I want someone to click a button and it generates the problem.. I have the problem stored in HTML <style type="text/css"> <!-- .style3 {font-size: 18px} --> </style> <form id="form1" name="form1" method="post" action=""> <span class="style3">1+1 = </span><strong> <label> </label> </strong> <label> <input type="text" name="textfield" id="textfield" /> </label> <label> <input type="submit" name="Go" id="Go" value="Go" /> </label> <?php session_start(); $question1 = (isset($_POST['textfield'])) ? $_POST['textfield'] : FALSE; $answer = "Correct!!"; if($question1 == "2"){ $_SESSION['answer'] = "Correct!!!" ; } elseif($question1 == ""){ echo ""; } elseif($question1 < "2"){ echo "To low of a number!"; }else { echo "To high of a number!"; } echo $_SESSION['answer']; ?> </form> <form id="form2" name="form1" method="post" action=""> <span class="style3">2+2 = </span><strong> <label> </label> </strong> <label> <input type="text" name="textfield2" id="textfield2" /> </label> <label> <input type="submit" name="Go2" id="Go2" value="Go" /> </label> <?php session_start(); $question2 = (isset($_POST['textfield2'])) ? $_POST['textfield2'] : FALSE; $answer1 = "Correct!!"; if($question2 == "4"){ $_SESSION['answer1'] = "Correct!!!" ; } elseif($question2 == ""){ echo ""; } elseif($question2 < "4"){ echo "To low of a number!"; }else { echo "To high of a number!"; } echo $_SESSION['answer1']; ?> </form> <form id="form3" name="form1" method="post" action=""> <span class="style3">3+3 = </span><strong> <label> </label> </strong> <label> <input type="text" name="textfield3" id="textfield3" /> </label> <label> <input type="submit" name="Go3" id="Go3" value="Go" /> </label> <?php session_start(); $question3 = (isset($_POST['textfield3'])) ? $_POST['textfield3'] : FALSE; if($question3 == "6"){ $_SESSION['answer2'] = "Correct!!!" ; } elseif($question3 == ""){ echo ""; } elseif($question3 < "6"){ echo "To low of a number!"; }else { echo "To high of a number!"; } echo $_SESSION['answer2']; ?> </form> <form action="" method="post" name="form4" id="form4"> <strong> Clear? (Yes) (Do it twice)</strong> <label> <input type="text" name="textfield4" id="textfield4" /> </label> <label> <input type="submit" name="button" id="button" value="Clear" /> </label> <?php $clear = (isset($_POST['textfield4'])) ? $_POST['textfield4'] : FALSE; if($clear == "yes"){ session_destroy(); } elseif($clear == "Yes"){ session_destroy(); } ?> </form> <p>
  3. i tried searching phpfreaks and i found a thread that was kind of what i needed but not quite...anyways... I'm trying to make a code so that when someone clicks a generate button a random math problem shows up. a polynomial math problem. I know i have to type the polynomial math problem in my code but how do i make it so that when someone clicks generate problem a problem shows up?
  4. duuude! your the best!! thank you soo much!! wow ur awesome!!
  5. here's a snippet of the code that is the one that probably needs to be fixed... $vbulletin->db->query_write("INSERT INTO ". TABLE_PREFIX ."trackerhistory (`date` , `seeders`, `leechers`, `ulspeed`, `dlspeed`) VALUES (NOW(),".$row1["c"]." , ".$row1["d"].",".$row2["c"]." , ".$row2["d"].") "); could you fix that for me so the last 2 values are 0 ?
  6. i'll fill in the `ulspeed`, `dlspeed` with 0 and see what happens from...i did ask vbulletin for help also and they told me to go to the person that made the modification but there's no help forum for the modification or anything. ill try filling in the values and see what happens
  7. Database error in vBulletin 3.8.1: Invalid SQL: INSERT INTO trackerhistory (`date` , `seeders`, `leechers`, `ulspeed`, `dlspeed`) VALUES (NOW(),0 , 0, , ); MySQL Error : 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 ' )' at line 1 Error Number : 1064 Request Date : Monday, March 2nd 2009 @ 12:41:00 AM Error Date : Monday, March 2nd 2009 @ 12:41:04 AM Script : http://www.thegamingfiles.com/adminc...cron&cronid=89 Referrer : http://www.thegamingfiles.com/adminc....php?do=modify IP Address : ******** Username : Berry05 Classname : vB_Database MySQL Version : 5.0.67-log what does this mean? I have the updated mySQL and everything!!
  8. sell.php code... <?php session_start(); if(isset($_SESSION['otherusername'])){ $db=mysql_connect('localhost', 'root', ''); $res=mysql_select_db('textgame',$db) or die(mysql_error()); $otherusername = $_SESSION['otherusername']; //"SELECT item FROM users_items WHERE username='".$Username."'"; $res=mysql_query($otherusername)or die(mysql_error()); while($row = mysql_fetch_assoc($res)){ echo '<a href="sell.php?item="' . $row['item'] . '">' . $row['item'] . "<BR />"; if ( $row == "hoe" ) { echo "Your name is someguy!<br />"; } } }else{ echo "Sorry your not a member please join us!"; } ?>
  9. ok.. i did this.. if ( $row == "hoe" ) { but i'll try your thing thxs!
  10. i have a script that shows a list of items in my field and echos out onto a webpage..there linkable and when i hover each of them it says /sell.php?item= im trying to make it so when a user clicks on the item it sells the item and updates there gold count... any help.
  11. theres a game script that when you click on the game it should start playing...but theres a link that says.. - Click here to play Power Fox in a new window - and you always have to click that link..
  12. i cant open it...and when i open it in textpad its all jibberish...
  13. theres a folder called swf and inside that folder you put flash games in it..there is two files in the fodlder to start with though..there called.. flvplay.swf and flvskin.swf
  14. my flash games arent showing on my website...im using WAMP server also..
  15. found the problem..the config file was set to that..i had to change it!
  16. no it doesnt..but this is the code on line 32.. $dh = opendir($cfg['instdir']."plugins"); i got rid of the . and got this Parse error: syntax error, unexpected T_CONSTANT_ENCAPSED_STRING in C:\wamp\www\gaming\plugins\language\functions.php on line 32
  17. i see what your saying..i got rid of it and still getting the same error
  18. hello! when i install a game script everything is great until i try loading it and get this... Warning: opendir(/home/username/public_html//plugins) [function.opendir]: failed to open dir: No such file or directory in C:\wamp\www\gaming\plugins\language\functions.php on line 32 Warning: readdir(): supplied argument is not a valid Directory resource in C:\wamp\www\gaming\plugins\language\functions.php on line 33 Warning: sort() expects parameter 1 to be array, null given in C:\wamp\www\gaming\plugins\language\functions.php on line 37 Warning: Invalid argument supplied for foreach() in C:\wamp\www\gaming\plugins\language\functions.php on line 40 Warning: include(/home/username/public_html/plugins/site/themes/awesome/index.php) [function.include]: failed to open stream: No such file or directory in C:\wamp\www\gaming\index.php on line 130 Warning: include() [function.include]: Failed opening '/home/username/public_html/plugins/site/themes/awesome/index.php' for inclusion (include_path='.;C:\php5\pear') in C:\wamp\www\gaming\index.php on line 130 plz help!
  19. i accidentally entered in the wrong database name... thxs !
  20. Warning: mysql_connect() [function.mysql-connect]: Access denied for user 'root'@'localhost' (using password: NO) in /home/a4634623/public_html/index2.php on line 14 Access denied for user 'root'@'localhost' (using password: NO) i fixed a problem before that..and now i get this.. what does that mean... please help! thxs!
  21. when i hover over the items link it has the URL and at the end it has sell.php?item= and that's it..isn't it suppose to show the item name from the field? echo '<a href="sell.php?item="' . $row['item'] . '">' . $row['item'] . "<BR />"; i think it has something to do with that code right there..
×
×
  • 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.