guarriman Posted March 27, 2008 Share Posted March 27, 2008 Hi. Using Apache/2.2 + PHP/5.2, my web application runs very slow when users access the very first webpage. The first webpage takes 5-10 to load and users see the messages: "Connecting" > "Read" > "Waiting for foo.com" > "Transferring from foo.com" > "Connecting" > "Read" > ... I inserted some PHP code to log the script speed with 'microtime' function, and I get (in the very bottom of the webpage): <!-- 0.13374590873718 sec. (Page Ends) --> The second time I access this page, I get: <!-- 0.55434894561768 sec. (Page Ends) --> It takes more time to be executed, but it loads faster! Any similar experience? I use Smarty template engine. Quote Link to comment https://forums.phpfreaks.com/topic/98141-app-runs-very-slow-when-users-access-the-very-first-webpage/ Share on other sites More sharing options...
MadTechie Posted March 27, 2008 Share Posted March 27, 2008 Doesn't sound like php issule to me.. but if it is it should be posted in third party (as its smarty related) to me it sounds like a large file (maybe image) loading into cache, theirs a few other things but i think the large image or connecting to remote files is likely. if you can post a link we could take a look. Quote Link to comment https://forums.phpfreaks.com/topic/98141-app-runs-very-slow-when-users-access-the-very-first-webpage/#findComment-502055 Share on other sites More sharing options...
guarriman Posted March 27, 2008 Author Share Posted March 27, 2008 Thank you very much for your answer. Doesn't sound like php issule to me.. but if it is it should be posted in third party (as its smarty related) Yep, I posted it on the Smarty forum, but I was told it doesn't look like a Smarty issue. to me it sounds like a large file (maybe image) loading into cache, You mean the webbrowser cache, don't you? It could be, since the homepage includes a SWF file theirs a few other things but i think the large image or connecting to remote files is likely. we include a lot of Ajax. if you can post a link we could take a look. It's within an Intranet, sorry Quote Link to comment https://forums.phpfreaks.com/topic/98141-app-runs-very-slow-when-users-access-the-very-first-webpage/#findComment-502076 Share on other sites More sharing options...
MadTechie Posted March 27, 2008 Share Posted March 27, 2008 Yep.. the SWF would do it, check the filesize of everything that loads on the firstpage, maybe clear cache and test, then remove the link to the swf then clear cache and test, yes i mean client/browser cache Quote Link to comment https://forums.phpfreaks.com/topic/98141-app-runs-very-slow-when-users-access-the-very-first-webpage/#findComment-502103 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.