matte Posted May 3, 2007 Share Posted May 3, 2007 hey, I am working on a newsletter management script in php. The problem i am having is the browser times out after 30 seconds and there are 5000 + users in the newsletter. I thought about using ini_set to change the timeout time, but then users will think the page has hung up and leave the page...inturn stopping the newsletter from sending all the emails. My question is will ajax timeout after a set amount of time or could i use ajax to send the newsletters and create some sort of progress indicator? Thanks in advance. Quote Link to comment https://forums.phpfreaks.com/topic/49857-wanting-to-use-ajax-to-send-newsletter/ Share on other sites More sharing options...
cmgmyr Posted May 3, 2007 Share Posted May 3, 2007 well the problem would be with the php not the javascript. So you should change the ini_set and maybe put a message saying "please wait...this might take a while" or something like that. You can also get javascript to do that on the wait state. Quote Link to comment https://forums.phpfreaks.com/topic/49857-wanting-to-use-ajax-to-send-newsletter/#findComment-244598 Share on other sites More sharing options...
matte Posted May 3, 2007 Author Share Posted May 3, 2007 i was thinking that when they hit submit on the form to send the newsletter it would fire up ajax in the background and disable the page from being used and put a progress indicator up just showing the progress of sending out the emails i suppose as you are saying during the wait state. How long does ajax wait in the wait state before it times out? That is what i am afraid of...don't really want to do all the work to find out javascript has the same problem as php in this case. Quote Link to comment https://forums.phpfreaks.com/topic/49857-wanting-to-use-ajax-to-send-newsletter/#findComment-244677 Share on other sites More sharing options...
cmgmyr Posted May 3, 2007 Share Posted May 3, 2007 i don't think that the wait state times out...I might be wrong but when I've tried a bad php code with ajax I let it go for a while and it never timed out. Quote Link to comment https://forums.phpfreaks.com/topic/49857-wanting-to-use-ajax-to-send-newsletter/#findComment-244860 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.