Join us at IRC!
Capitalism is an Island of wealth in a sea of poverty
Friday, May 25, 2012
Navigation
Members Online
Total Online: 26
Web Spiders: 13
Guests Online: 23
Members Online: 3

Registered Members: 70208
Newest Member: andresuran
Latest Articles
View Thread

HellBound Hackers | Computer General | Webmasters Lounge

Author

[php] TImed challenges?

PHmaster
Member

Posts: 22
Location: Poland
Joined: 05.08.08
Rank:
God
Posted on 26-08-08 17:37
I want to create new Timed CHallenge and maybe send it (i hear, that Users can send their own task to the service).
But I've got a (big) problem.
In all task I can see "you have x second...". How can I write scblockedript, with I can check time with it? For example, someone will run scblockedript at 17:50:25. He has only 2 sec. to type good answer in the form. If he send the solution at 17:50:28, scblockedript will "say": quick?
Thanks for reply in advance ;)


Author

RE: [php] TImed challenges?

sharpskater80
Member

Posts: 170
Location: Missouri
Joined: 18.09.05
Rank:
God
Warn Level: 10
Posted on 26-08-08 18:02
I would guess they just use microtime() right after the opening tag, then again once you submit, and if the difference between second-first is <= the time limit, you pass the mission. You may have to cast it to a float, some of the examples I see do.


Author

RE: [php] TImed challenges?

PHmaster
Member

Posts: 22
Location: Poland
Joined: 05.08.08
Rank:
God
Posted on 26-08-08 18:07
but how can i check time before add solution, and time after send right answer?
use session?


Guest
Username

Password

Remember Me


Bookmark This Page
Affiliates
Adverts

 

 

Links
By using, viewing or obtaining any information contained on this site, you agree to the disclaimer.

© HellBound Hackers 2008- 2009. Since 3rd December 2004.