css ý½éÀàÐÍ
ý½éÀàÐÍ(Media Types)ÔÊÐíÄ㶨ÒåÒÔºÎÖÖý½éÀ´Ìá½»Îĵµ£¬Îĵµ¿ÉÒÔ±»ÏÔʾÔÚÏÔʾÆ÷¡¢´òÓ¡»ú»òÕßÌý¾õä¯ÀÀÆ÷µÈµÈ¡£
ʵÀý
ÏÂÃæÕâ¸öÀý×ÓÖеÄÑùʽ¸æÖªä¯ÀÀÆ÷ÔÚÏÔʾÆ÷ÉÏÏÔʾ 14 ÏñËØµÄ Verdana ×ÖÌå¡£µ«ÊǼÙÈçÒ³ÃæÐèÒª±»´òÓ¡£¬½«Ê¹Óà 10 ¸öÏñËØµÄ Times ×ÖÌå¡£×¢Ò⣺font-weight ±»ÉèÖÃΪ´ÖÌ壬²»ÂÛÏÔʾÆ÷»¹ÊÇֽý½é£º
<%@ page language="java" pageEncoding="UTF-8"%>
<html>
<head>
<style type="text/css">
@media screen{
p.test {font-family:verdana,sans-serif; font-size:14px; color:red}
}
@media print{
p.test {font-family:times,serif; font-size:10px; color:blue}
}
@media screen,print{
p.test {font-weight:bold}
}
</style>
<script type="text/javascript">
function preView(){
try{
WB.ExecWB(7,1);
}catch(e){
alert("ÄúµÄä¯ÀÀÆ÷²»Ö§³Ö´Ë¹¦ÄÜ");
}
Ïà¹ØÎĵµ£º
¡¡¡¡CSS¼òд
¾ÍÊÇÖ¸½«¶àÐеÄCSSÊôÐÔÉùÃ÷»¯³ÉÒ»ÐУ¬ÓÖ³ÆΪCSS
´úÂëÓÅ»¯
¡£CSS¼òдµÄ×î´óºÃ´¦¾ÍÊÇÄܹ»ÏÔÖø¼õÉÙCSSÎļþµÄ´óС£¬Æäʵ»¹ÓкܶàÆäËûÒæ´¦¡£Ó·Ö׶øÔÓÂÒµÄCSSÑùʽ±í»áʹÄãÓöµ½ÎÊÌâÊÇÄÑÒÔµ÷ÊÔ¡£ÓÈÆäÊǵ±Ò»¸öÍŶÓÔÚ½øÐÐÉè¼ÆµÄʱºò£¬ÄãµÄÓ·Ö×µÄCSS´úÂë»áʹÄãµÄÍŶÓÆäËû³ÉÔ±µÄ¹¤×÷ЧÂÊϽµ¡£
¡¡¡¡Ì«¶àµÄÈËʹÓÃDreamwe ......
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Èý¼¶dropdownµ¯³ö ......
Á½Áв¼¾Ö
1¡¢×óÁй̶¨£¬ÓÒÁÐ×ÔÊÊÓ¦
#left{ width:190px; float:left; }
#right{ margin-left:205px; }
2¡¢ÓÒÁй̶¨£¬×óÁÐ×ÔÊÊÓ¦
#left{ float:left; width:100%; }
#right{ float:left; margin-left:-100px; width:100px; }
ÈýÁв¼¾Ö
×óÓ ......
ÊÂʵÉÏ£¬ËùÓбíÏֵĵط½¶¼ÐèÒªÓÃCSSÀ´ÊµÏÖ¡£ÎÒÃÇÒÔÇ°¶¼Ï°¹ßÓÃtableÀ´¶¨Î»ºÍ²¼¾Ö£¬ÏÖÔÚÒª¸ÄÓÃDIVÀ´¶¨Î»ºÍ²¼¾Ö¡£ÕâÊÇ˼ά·½Ê½µÄ±ä»¯£¬Ò»¿ªÊ¼ÓÐЩ²»Ï°¹ß¡£ºÇºÇ£¬Èκαä¸ï¶¼»áÓÐ×èÁ¦µÄ£¬ÎªÁËÏíÊܱê×¼´øÀ´µÄ"Òæ´¦"£¬·ÅÆúһЩÀϵĴ«Í³×ö·¨ÊÇÖµµÃµÄ¡£
¡¡¡¡Íⲿµ÷ÓÃÑùʽ±í
¡¡¡¡ÔÚÒÔÇ°£¬ÎÒÃÇͨ³£²ÉÓÃ2ÖÖ·½·¨Ê¹ÓÃÑùʽ±í£º
......
SpriteMeÊÇGoogleµÄÒ»¸ö¿ªÔ´ÏîÄ¿£¬¿ÉÒÔÓÃÀ´·½±ãµØÕÒ³öÒ»¸öÒ³ÃæÖÐËùʹÓõÄͼƬ£¬È»ºó¿ÉÒÔ½«ËùÒÔͼƬºÏ²¢µ½Ò»¸ö“Sprite”ͼƬ£¬È»ºóÔÙͨ¹ý
CSS¿ØÖƵ÷ÓÃÄÄÒ»¸öÇøÓò£¬ÆäÌṩÁËÒ»¸öÍøÕ¾À´°²×°£¬ÑÝʾʹÓ÷½·¨£¬http://spriteme.org/ ¡£
°²×°·½·¨ºÜ¼òµ¥£¬°´ÕÕÉÏÃæÄǸöÒ³ÃæÉϵÄÌáʾ£¬½«Ò»¸öÁ´½ÓÍϵ½“ÊéÇ©¹ ......