vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 Programming Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=15)
-   -   Check out this absolutely excellent use of AJAX (https://vborg.vbsupport.ru/showthread.php?t=121639)

Guest210212002 07-19-2006 11:57 PM

Check out this absolutely excellent use of AJAX
 
<a href="http://www.fohguild.org/forumspy/forumspy.php" target="_blank">http://www.fohguild.org/forumspy/forumspy.php</a>

I don't believe you need an account there to see it in action. Basically that page auto-updates dynamically every time there's a post in one of the forums. There's also a great looking mouseover window that pops up at the bottom of the screen with thread preview in it.

It's hooked into every forum in the network of sites, not just the FoH site, so any time any of the uberguilds network sites gets a post, it updates that list.

(Before anyone asks, it's hand-coded by them, and they aren't sharing. I'd LOVE to have that on my site.)

Very, very slick.

Code Monkey 07-20-2006 12:13 AM

I consider that a horrible missuse of AJAX. It's doing the same thing as the dreadful AJAX chat script does. Polling the server every 5000 ms. That would bring a lot of sites down. If they have the server power then that's fine. But it is still not what ajax is designed to do. You could do the same thing with php and a header refresh.

Trana 07-20-2006 01:09 AM

As Jump said, this is not what AJAX is for.

Kirk Y 07-20-2006 01:36 AM

Still looks pretty nifty though. :classic:

Smiry Kin's 07-20-2006 06:31 AM

could look better i think..

Guest210212002 07-20-2006 06:52 PM

/me still thinks it's nifty. :P

Paul M 07-20-2006 09:35 PM

Woah, way to kill your server. Not getting anywher near any of mine .....

SaintDog 07-21-2006 03:51 PM

Digg and quite a few other websites use such a script as well. It either is not as resource intensive as it may seem or they all have powerful enough servers to not have to worry about it :).

If you're on a cluster or a load balanced setup, you probably wouldn't have anything to worry about.

Code Monkey 07-21-2006 04:52 PM

Quote:

Originally Posted by SaintDog
Digg and quite a few other websites use such a script as well. It either is not as resource intensive as it may seem or they all have powerful enough servers to not have to worry about it :).

If you're on a cluster or a load balanced setup, you probably wouldn't have anything to worry about.

Which leaves the other 99.9% who's sites would come to a crawl.

This kind of thing is what gives AJAX a bad rap. The purpose of AJAX is to give the end user interactive feedback as close to realtime as possible. To simulate the look and responce of a desktop application.

It is not designed as a non interactive page refresher. It's a good thing they don't release it.

Guest210212002 07-21-2006 06:02 PM

Quote:

Originally Posted by Trana
As Jump said, this is not what AJAX is for.

The beauty of coding is that it can be "for" whatever you want it to be.

Those guys (and myself) obviously think that's a pretty good use of AJAX. ;)

Trana 07-21-2006 06:28 PM

All it is is a fancy site integrated RSS reader, not what AJAX is for.

Yes, you CAN use AJAX for this purpose, but I think you are looking at it from the coding perspective and not the network/system utilization point of view. This isn't much different than the vbshout hack, which causes a pretty big hit on your system resources.

IMO, there are other tools to do this function.

Code Monkey 07-21-2006 09:09 PM

Quote:

Originally Posted by Chris-777
The beauty of coding is that it can be "for" whatever you want it to be.

Those guys (and myself) obviously think that's a pretty good use of AJAX. ;)

Tell that to the people who get booted by their host because they naively install this kind of crap.

Tell that to the people who find that httprequest functions have been disabled because of hosts that are sick of dealing with these issues.

Just becuase dynamite can be used to kill people as well as move mountains doesn't make killing people a good idea.

AN-net 07-21-2006 11:55 PM

basically a cheap copy of Digg.com's Digg Spy;)

Guest210212002 07-31-2006 12:02 AM

Without getting into why comparing code to killing people is a little silly.. ;)

Something like that, showing (for example) the last 5 posts embedded in a CMPS block would be pretty freakin' sleek.

stud 08-01-2006 01:59 PM

Server issues aside, i really like how topics update on that site.

The Diggspy way of refreshing is a pretty attractive one - and would function pretty well on smaller forums that don't already hammer their host servers.

Guest210212002 08-01-2006 07:54 PM

Their code is downloadable (digg-spy), I've been picking at it trying to get it to work with vB, but it'll be a while until I have anything solid.

Andrew Green 08-02-2006 12:40 PM

Quote:

Originally Posted by JumpD
I consider that a horrible missuse of AJAX. It's doing the same thing as the dreadful AJAX chat script does. Polling the server every 5000 ms. That would bring a lot of sites down. If they have the server power then that's fine. But it is still not what ajax is designed to do. You could do the same thing with php and a header refresh.


Depends... It's not as heavy as someone hitting "Find New Posts" every 5 seconds, or watching the who's online page reload every 5 seconds.

Still, might be best used as a staff only page or even a paid members only page for those with stretched servers.

Now if someone where to make a mod to plop this into the header of every page that gets displayed, that would definately crash and burn :)

stud 08-02-2006 12:45 PM

I think the absolute best application of this would be on a CMPS page, in the Recent Posts module.
Having 1 module update while others stay static would be much less strain on the server then having users doing a manual refresh every 30 seconds or so. If you had the ability to change the interval at which it polls, you could customize it to the needs of all types of websites.


All times are GMT. The time now is 07:23 AM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.02074 seconds
  • Memory Usage 1,750KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (4)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (18)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete