UBB.Dev
About:
This additional javascript enables modern browsers to forward directly to the next page without needing to load the "middle" acknowledgement page. It removes the "2 second" delay page between new posts, post edits, post deletions...etc. This also eliminates the server building and page downloading of your site's header-page-footer templates, saving a bit of server resources, and bandwidth for the user -- who might be on a data-limited mobile devices.

Because it does not remove the "refresh" meta tag, it keeps the "view post" and "return to the forum" middle-page functionality for older browsers -- which cannot support the "window.location.href" script command. I'm looking at you, IE6!

This is just a quick upgrade in which many users have asked for in the past -- without removing the current functionality for older browsers and browsers with javascript turned off.

How-To:
FIND IN libs/html.inc.php:
Code
$meta = "<meta http-equiv=\"Refresh\" content=\"{$delay};url=" . make_ubb_url("ubb={$redirect['redirect']}", "", false) . "\" />";

REPLACE WITH:
Code
$meta = "<meta http-equiv=\"Refresh\" content=\"{$delay};url=" . make_ubb_url("ubb={$redirect['redirect']}", "", false) . "\" /><script type=\"text/javascript\">window.location.href = \"" . make_ubb_url("ubb={$redirect['redirect']}", "", false) . "\"</script>";

done.
What a good "tweak". These are the kinds of things that I really hope get added to any future upgrade... It would be a shame to have to go back and manually add them... eg. Stop Forum Spam.
You should add the control panel one as well, it's a 2 second delay listed in the libs
For the life of me, I couldn't find which file it was in.
Originally Posted by Bill B
For the life of me, I couldn't find which file it was in.

libs/html.inc.php @ about line 562 of UBBT 7.5.8-r2

And while you're in there, if you wanted to change the refresh delay for older browsers; about 3 lines up, change "$delay = 2;" from 2, to 5, or whatever. The number is the automatic page refresh delay in seconds.

BTW, I just updated the OP to add a better description of what this mod does.
Originally Posted by Gremelin
You should add the control panel one as well, it's a 2 second delay listed in the libs

You might not want to add it to the control panel. I can see problems occurring when an admin user runs one of the "Content Rebuilder" options (Rebuild Posts, Rebuild Topics, Rebuild Forums...etc) This may kill your server/database -- or at the very least, to the admin running the command, make it look like the page isn't loading at all.

In the same sentence, there is a "refresh delay" of 5 seconds at about line 1393 of html.inc.php regarding incorrect/bad password entry ("BAD_PASS") that should be left as-is, or extended to 10 seconds if you so choose.
Sorry. I meant that I couldn't find which file controlled the Control Panel delay that Gremlin (?) mentioned.

ADD: I see you posted while I was typing... Okay, understand about not pushing the CP too much. I'll skip that. Thanks.
@ Bill,

libs/admin.inc.php @ about line 338

FIND:
Code
$time = "5";

REPLACE WITH:
Code
$time = "2";

Personally, I have mine set to "2" seconds, but the default is "5" seconds. You can modify it to whatever you want that delay to be. Be aware of the condition I mentioned above, regarding the Content Rebuilder requiring some sort of delay.
© UBB.Developers