The Daily Static
  The Daily Static
UF Archives
Register
UF Membership
Ad Free Site
Postcards
Community

Geekfinder
UFie Gear
Advertise on UF

Forum Rules
& FAQ


Username

Password


Create a New Account

 
 

Back to UserFriendly Strip Comments Index

I need some help for my procrastination project by Spisefisken2007-07-10 04:32:43
  2 ways of doing it: by Talchas 2007-07-10 04:40:39
  1. Don't have Refresh actually refresh - have it reroll the unchecked dice and then update the src for the images of the rolled dice in javascript.
  2. Change the Refresh to be a form submission, then make the page into a php page or whatever your favorite server side language is. You'll also need to make the value for each checkbox be the value of the die above it. Then make that web page output the randomization javascript only for the unselected dice and insert plain html for the selected ones. You may have to live with the selected ones being first. Alternatively, you could instead insert most of the normal javascript for all of them, and if say die 1 is selected, instead of having var dice1 = Math.round((Math.random()* 6)+0.5);, have var dice1 = {the server side code to insert whatever number it got from the form};
[ Reply ]

 

[Todays Cartoon Discussion] [News Index]

Come get yer ARS (Account Registration System) Source Code here!
All images, characters, content and text are copyrighted and trademarks of J.D. Frazer except where other ownership applies. Don't do bad things, we have lawyers.
UserFriendly.Org and its operators are not liable for comments or content posted by its visitors, and will cheerfully assist the lawful authorities in hunting down script-kiddies, spammers and other net scum. And if you're really bad, we'll call your mom. (We're not kidding, we've done it before.)