Logo
Remember me Forgot password?
Businessgame news
By KingIsulgard, Sat 8 Oct 2011 13:31
JavaScript threading

I found a way to do threading in JavaScript. This opens a lot of possibilities for AJAX implementation to the site. Refreshing the shoutbox every 3 seconds, checking if the online users have changed every 30 seconds and see if you got any new messages each minute... Without the need of refreshing the page!

The fact that JavaScript can't thread made it very hard to implement such things with different timers. If you want to know how I made threading possible just check the source code for "threading.js".

View all 8 comments
Mister_Cash
Mister_Cash  11 October at 20:27
tech news would be interesting for some people including me maybe a section on home page?
Wildjap
Wildjap  12 October at 9:07
Can we please have time stamps for shoutbox message! It's not cool going to the shout box and not knowing if the last message was send two seconds ago or 2 days ago...
KingIsulgard
KingIsulgard  12 October at 9:54
You can see who is online, but I'll try to work something out. I just wanted to keep it as compact as possible since it is on such a small place.
Wildjap
Wildjap  12 October at 16:32
Could you not just have a label next to the stream that has the date of the last update?

20:31

Our Wikia

Our Discord

Assistant

Top 10

1 algreeno
2 herbie2000
3 Kaibaman
4 Yoda
5 Mettez
6 alphonse
7 Mistermini
8 Mikkelmoes
9 Agag99
10 BondJames

Hall of Fame

Donate

Enjoy the game? Why not make a donation?

Donators receive:

  • No more ads
  • Game coins
  • A tax cut
  • Faster XP
  • And more...

Become a donator!

Follow us

Follow Businessgamebe on Facebook Follow Businessgamebe on Twitter