Private
09-25-2003, 10:00 PM
If you ever had problems when sending an email to more than 200 users at once or if you got the silly error message: Problem Report (Timeout), this hack is made for you !
Purpose:
When you send a large number of emails at once (100-1000, depends on your server) using Email Users feature in the admin control panel, you propably get a timeout error message and that's because a certain time limit has ended while the emails are in the sending process.
A solution is to decrease the number of emails bieng sent at once, but this will force you to click the submit button in order to proceed to the next page, and this is difficult because you'll have a large number of pages.
e.g. if you have 10000 users in your forums, and you choose to send 100 messages at once, you'll have 100 pages, when every page finished loading, you must click (Do Next Page) button to proceed to next page!
Well, (Auto Redirect) hack will click the submit button in behalf of you :), using a small Java Script code, the emailing process will continue automatically, sending batch after batch until you email all users of your forum.
Installation:
PLEASE make a backup of email.php, all changes are made in this file.
For your safety, always make a backup of your files before hacking it!
Open up email.php that is located in the Admin directory, and change the following:
1: find:
makehiddencode("test",$test);
and right under this line, write:
makehiddencode("redirect",$redirect);
2: couple of lines below, you'll find:
doformfooter("Do Next Page (page $page)",0);
On the line below it, place:
// automatic redirect
if ($redirect) {
echo '
<script language="javascript">
myvar = "";
timeout = 15;
function dorefresh() {
window.status="Redirecting"+myvar;
myvar = myvar + " .";
timerID = setTimeout("dorefresh();", 100);
if (timeout > 0) {
timeout -= 1;
}
else {
clearTimeout(timerID);
window.status="";
document.name.submit();
}
}
dorefresh();
</script>';
}
// automatic redirect
3: finally, find:
makeinputcode("Messages to send at once:","perpage","500");
and place the following code below it:
makeyesnocode("Auto redirect to next page?","redirect");
ENJOY!
Hack Summary:
- Author: Private (privateman@flashmail.com)
- Tested on: all versions of vb 2.2.x and 2.3.x
- Support: post your questions in this thread only
- effects: 1 file effected (email.php)
- I strongly encourage vBulletin team to include this hack in VB3
Purpose:
When you send a large number of emails at once (100-1000, depends on your server) using Email Users feature in the admin control panel, you propably get a timeout error message and that's because a certain time limit has ended while the emails are in the sending process.
A solution is to decrease the number of emails bieng sent at once, but this will force you to click the submit button in order to proceed to the next page, and this is difficult because you'll have a large number of pages.
e.g. if you have 10000 users in your forums, and you choose to send 100 messages at once, you'll have 100 pages, when every page finished loading, you must click (Do Next Page) button to proceed to next page!
Well, (Auto Redirect) hack will click the submit button in behalf of you :), using a small Java Script code, the emailing process will continue automatically, sending batch after batch until you email all users of your forum.
Installation:
PLEASE make a backup of email.php, all changes are made in this file.
For your safety, always make a backup of your files before hacking it!
Open up email.php that is located in the Admin directory, and change the following:
1: find:
makehiddencode("test",$test);
and right under this line, write:
makehiddencode("redirect",$redirect);
2: couple of lines below, you'll find:
doformfooter("Do Next Page (page $page)",0);
On the line below it, place:
// automatic redirect
if ($redirect) {
echo '
<script language="javascript">
myvar = "";
timeout = 15;
function dorefresh() {
window.status="Redirecting"+myvar;
myvar = myvar + " .";
timerID = setTimeout("dorefresh();", 100);
if (timeout > 0) {
timeout -= 1;
}
else {
clearTimeout(timerID);
window.status="";
document.name.submit();
}
}
dorefresh();
</script>';
}
// automatic redirect
3: finally, find:
makeinputcode("Messages to send at once:","perpage","500");
and place the following code below it:
makeyesnocode("Auto redirect to next page?","redirect");
ENJOY!
Hack Summary:
- Author: Private (privateman@flashmail.com)
- Tested on: all versions of vb 2.2.x and 2.3.x
- Support: post your questions in this thread only
- effects: 1 file effected (email.php)
- I strongly encourage vBulletin team to include this hack in VB3