开发者

Increasing the speed of the website [closed]

It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhet开发者_Go百科orical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center. Closed 12 years ago.

Can anyone tell me the things what we need to consider while coding to create a website (website having more stuff) which should not get slow in any situation other than server problem....


Yahoo maintain a good summary of speed optimisations:

http://developer.yahoo.com/performance/rules.html

You can measure your site against these using YSlow, a Firebug plugin:

http://developer.yahoo.com/yslow/


Keep your code as slim as possible.

Try and use AJAX calls, so you don't have to refresh the entire page to get the information that you require.

http://www.w3schools.com/ajax/

Hope that helps.


Well, something I'm used to do to increase speed/reduce HTTP requests:

  • css sprites
  • gzip compression
  • basic ajax requests through get (post will do 2 requests)
  • css stylesheets in separated files
  • js files as above
  • caching
  • etc.

while coding, OO or not, be sure you're not doing something that slows down your server (too many ajax requests, too many queries repeated and not cached etc..)


The resource Adam posted is solid. Google also has a similar guide, search for "Google Web Performance Best Practices."

Some other things you'll want to think about include caching as much as possible to avoid hitting the application (look for things like memcached), simplifying redundant or complex database queries, and working background processes into your application so web requests are not tied up. A quick Google search for your chosen environment should yield some helpful info.

Additional helpful links:

http://code.google.com/p/google-perftools/ (Performance Analysis Tool) http://www.mnot.net/cache_docs/ (Very In-depth Caching Tutorial)

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜