mike1313
-
Posts
116 -
Joined
-
Last visited
Posts posted by mike1313
-
-
Through forms and stealing bandwidth. In the form if a user posts something, it gets displayed on the page.
-
Our site is getting hit by hackers, so I'm forced to take the server offline, what is the best form of security? help asap is appreciated.
-
Okay works great, 1 more thing, how would I like I orginally wanted so if I had 3 swords how would I make it put a 3 beside the name?
-
No it outputs
Sword
Sword
as many times as there is item='Sword'
so with that echo and while loop and there where 3 swords it would display
Sword
Sword
Sword
-
If you want the fields they are as such for the db table
id - auto_increment
order (int)
item (varchar)
type(varchar)
effect(int)
equipped(varchar)
req_lvl (int)
Each time someone puts something into the armory it makes a new row.
-
$arm = mysql_query("SELECT * FROM order_arm WHERE `order`='$order[id]' ORDER by effect asc"); while ($armo = mysql_fetch_array($arm)) { if($armo[type] == "Weapon"){ $t = "W";} if($armo[type] == "Armor"){ $t = "A";} echo "<tr><td><li type=square></td><td>[<b>$t</b>]</td><td>$armo[item]</td><td> [<b>E</b>]: $armo[effect]</td></tr>"; }
-
Okay so for my MMORPG, there are player-owned guilds that have an armory where they can store their weps/armor but when it shows what the armory holds if it is more than one of the same item they stack instead of showing
Sword
Sword
I want it to display 2 Sword. How can I do this?
while ($armo = mysql_fetch_array($arm)) { if($armo[type] == "Weapon"){ $t = "W";} if($armo[type] == "Armor"){ $t = "A";} echo "<tr><td><li type=square></td><td>[<b>$t</b>]</td><td>$armo[item]</td><td> [<b>E</b>]: $armo[effect]</td></tr>"; }
-
Well I have a page where the db gets updated, but if they go to a different page then click back, the page updates again.
-
Is there anyway possible to stop a user from hitting the back button?
-
I mean is there a way to find out what a certain part of the timestamp will be for 6 am, then find the current hour subtract the 2 and make it into a % that way?
-
is there a way to divide the time stamp for 6 am? that way I could take the current timestamp - 6amstamp and turn it into a %?
-
well it was returning just aplain ole 44
-
no thats returned negative. I had this....
<? $sixamtime = ((((time() / 60) / 24) / 3600) / 7); $six = 60 * 6; $total_time = 1440; $percentage = round((($total_time / $sixamtime) / 100) * 100); echo "$percentage"; ?>
-
that just returns 0.00.
-
that or how can I find 6 am server time - current time and turn that into mins?
-
Is it possible to stop a user from viewing a certain page if they entered the page by typing the url in the address bar?
-
Percentage based on the time now until 6 am with the % getting higher as it gets closer to 6 am once at 6 am its 100% once it hits 6:01 am it starts over again at 0%
-
bump
-
Ok I want a percent returned. I have a script that executes at roughly 6 am. How can I find out based on the current time how much of a percent it is until 6 am. As it gets closer to 6 am the % gets higher.
-
Anybody?
-
Ok say I have a script that runs every 15 mins, 15, 30,45, 0 .how would I calculate the amount of time left until it has to run again with the percent getting higher as it is getting closer to the 15 mins. Say its 1:20 How would I return the percentage of time from 1:20 to 1:30 etc?
-
OK so I want it to display all the players but for some reason its only displaying one any suggestions?
$url = "images/Eden_ISOtest_VIEW.jpg"; $url_admin = "images/admin_body.png"; $im = @imagecreatefromjpeg($url) or die("Cannot Initialize new GD image stream"); $background_color = imagecolorallocate($im, 255, 255, 255); $text_color = imagecolorallocate($im, 233, 14, 91); $red = imagecolorallocate($im, 255, 0, 0); $yellow = imagecolorallocate($im, 173, 255, 47); $white = imagecolorallocate($im, 255,255,255); $black = imagecolorallocate($im, 0,0,0); imagerectangle($im, 0, 0, 504, 504, $black); $query = mysql_query("select * from players"); while ($pos = mysql_fetch_array($query)){ $coords = "($pos[x], $pos[y])"; imageString($im, 1, ($pos[x]+3), ($pos[y]-6), $pos[username], $black); imageString($im, 1, ($pos[x]+2), ($pos[y]+3), $coords, $black); if ($pos[pos] == "Admin") { $insert32 = imagecreatefrompng("images/devil.png"); $insert_x32 = imagesx($insert32); $insert_y32 = imagesy($insert32); imagecopymerge($im,$insert32,$pos[x],$pos[y],0,0,12,$insert_y32,100); imagepng($im,"",100); } else { $insertx = @imagecreatefrompng("images/devil.png"); $insert_xx = imagesx($insertx); $insert_yx = imagesy($insertx); imagecopymerge($im,$insertx,$pos[x],$pos[y],0,0,12,$insert_yx,100); imagepng($im,"",100); } } imagepng($im); imagedestroy($im);
-
How would I use it header location, I tried using srand it updated part of the page but not what I needed.
-
Yeah, tried that it worked, using meta refresh, but we had rand() on the page making it run twice.
form help
in PHP Coding Help
Posted
Is there any way to stop a user from hitting refresh and sending a form over again after they have done it once? I've tried $_SERVER['HTTP_REFERER']; but nothing any help is appreciated.