当前位置: 首页 > 网络学院 > 设计教程 > 设计理念 > 优化网站图片

设计理念
利用.htaccess控制网站
别具一格的网站评论
网站设计原理

设计理念 中的 优化网站图片


出处:互联网   整理: 软晨网(RuanChen.com)   发布: 2009-03-01   浏览: 1356 ::
收藏到网摘: n/a

Optimize_Your_Photos_For_The_WebIt doesn't matter if your emailing photos of your grandson or putting images of your latest product on your online store. Too many people don't consider optimizing their photos for the web. We've all been on too many web pages where it seemed that the photos would never load, and sometimes they didn't. So here are some steps to make sure that your photos show up on your site.

不管是利用电子邮件发送孙子的照片,还是在网上商店发布新产品图片,都需要考虑图片的优化。但是现在很多网站忽视了图片优化这个步骤,所以我们看到许多网站图片不能呈现。下面介绍几条建议,可以保证图片呈现在网站上。

1. Always have a back up original format copy of your image. Never alter the original. Believe me you will regret it.

支持图片原来的格式,不要改变图片原来的尺寸。如果这样做你会后悔的。。

2. Crop to size. Make sure that you crop out any extra information that isn't needed. Remember the larger the photo the longer it takes to load or send.

修改图片尺寸。删除所有的多余信息,记住:图片越大,下载时间越长。

3. Resize to reduce pixels. There should be an option to resize according to pixels. You're going to want the largest size to be no more than 250 pixels or you can reduce the dpi to no more than 96.

减少图片像素。你最好可以根据像素调整图片尺寸,图片最大像素不能超过250;或者你可以把dpi控制在96以内。

4. Reduce the color palette. Many images have millions of colors so the first thing that you need to do is reduce the colors to 256. You will lose some depth with this.

减少色区。许多图片拥有百万种颜色,所以你首先把颜色减少到256,这样位深会减少。

5. Save the file in a standard format. JPEG is the most common for photos and you can compress the image with a JPEG for further reduction in file size. It's not unusual to see GIF or PNG as well.

以标准格式保存图片。JPEG是一种最常见的图片格式,你可以把图片压缩成JPEG格式,这样可以缩小文件尺寸。你也可以使用GIF或者PNG格式。

Remember that with a 56k connection a 150k file will take 20 seconds to load. If you're creating a web page every photo that you add will add to the time it takes to download all of the images. If you keep the images small in size the smaller resolution will not be as obvious.

请记住:在56k的网络连接中,150k的文件下载需要20秒钟。图片会增加网页的下载时间,但如果图片尺寸太小,会影响图片质量。

评论 (0) All

登陆 | 还没注册?