Jump to content

Suzanne M

New Members
  • Posts

    4
  • Joined

  • Last visited

    Never

Everything posted by Suzanne M

  1. I created a mySQL database using XAMP but I don't know what all to put in a database associated with a game that generates random numbers. I have to update user credit though so do I require 3 fields? Username, Credit, Random Value Generated.
  2. Thanx frenz for all your help. @pranshu82202:I have used PHP tags before but what the problem is, now I have only used a table to display the header Jackpot. Remaining things are outside the table. I don't think I need the table but how do I place the remaining things in the table? Everyone: Basically I am developing a mini game. In this game, the gamer has some credit value. The gamer provides some credit for this game. The game generates random positive and negative values. These generated values are added to the gamer's credit. Now my qn is how do I update the gamer's credit? This is a real-time game.
  3. @Eiolon: I am using the Dreamweaver software to execute my PHP code, no output comes. All I see is the PHP symbol. @Maq: My file does have a PHP extension. Can someone tell me how to put multiple things in one PHP program eg. generating a random number, capturing form info etc.
  4. I want to create a Jackpot game where the positive & negative numbers are randomly generated. I have written my code in Dreamweaver but I don't see the output of my PHP code. Instead of code I see the PHP symbol. I also want to know how to combine multiple functionalities in PHP. I want to create a table, store game credit, generate a random number etc. This is my current code. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>Jackpot</title> </head> <body> <?php include "header.php"; ?> <table width="100%" cellpadding="0" cellspacing="0" align="center"> <tr valign="top"> <td width="100%" height="59" align="left" valign="top"><table width="100%" cellpadding="0" cellspacing="0" align="center"> <tr valign="top"> <td align="left" valign="top" bgcolor="#FFFFFF"><?php include "menu.php"; ?></td> <td width="100%" align="left" valign="top"><p align="center">Jackpot</p></td> </tr> </table> <p align="center"> </p></td> </tr> </table> <?php include "footer.php";?> <?php $random_number = rand(-1000,1000); echo "<p> You struck a Jackpot of </p>"; echo $random_number; ?> <form action="Jackpot.php" method="post"> fingerValue: <input type="text" name="fingerValue" /> <input type="submit" /> </form> </body> </html>
×
×
  • 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.