html¶ÁÊé±Ê¼ÇÈý
13.HTML ͼÏñ
ͼÏñ±êÇ©£¨<img>£©ºÍÔ´ÊôÐÔ£¨Src£©
ÔÚ HTML ÖУ¬Í¼ÏñÓÉ <img> ±êÇ©¶¨Òå¡£
<img> ÊÇ¿Õ±êÇ©£¬Òâ˼ÊÇ˵£¬ËüÖ»°üº¬ÊôÐÔ£¬²¢ÇÒûÓбպϱêÇ©¡£
ÒªÔÚÒ³ÃæÉÏÏÔʾͼÏñ£¬ÄãÐèҪʹÓÃÔ´ÊôÐÔ£¨src£©¡£src Ö¸ "source"¡£Ô´ÊôÐÔµÄÖµÊÇͼÏñµÄ URL µØÖ·¡£
¶¨ÒåͼÏñµÄÓï·¨ÊÇ£º
<img src="url" />
URL Ö¸´æ´¢Í¼ÏñµÄλÖá£Èç¹ûÃûΪ "boat.gif" µÄͼÏñλÓÚ www.w3school.com.cn µÄ images Ŀ¼ÖУ¬ÄÇôÆä URL Ϊ http://www.w3school.com.cn/images/boat.gif¡£
ä¯ÀÀÆ÷½«Í¼ÏñÏÔʾÔÚÎĵµÖÐͼÏñ±êÇ©³öÏֵĵط½¡£Èç¹ûÄ㽫ͼÏñ±êÇ©ÖÃÓÚÁ½¸ö¶ÎÂäÖ®¼ä£¬ÄÇôä¯ÀÀÆ÷»áÊ×ÏÈÏÔʾµÚÒ»¸ö¶ÎÂ䣬ȻºóÏÔʾͼƬ£¬×îºóÏÔʾµÚ¶þ¶Î¡£
Ìæ»»Îı¾ÊôÐÔ£¨Alt£©
alt ÊôÐÔÓÃÀ´ÎªÍ¼Ïñ¶¨ÒåÒ»´®Ô¤±¸µÄ¿ÉÌæ»»µÄÎı¾¡£Ìæ»»Îı¾ÊôÐÔµÄÖµÊÇÓû§¶¨ÒåµÄ¡£
<img src="boat.gif" alt="Big Boat">
ÔÚä¯ÀÀÆ÷ÎÞ·¨ÔØÈëͼÏñʱ£¬Ìæ»»Îı¾ÊôÐÔ¸æË߶ÁÕßËýÃÇʧȥµÄÐÅÏ¢¡£´Ëʱ£¬ä¯ÀÀÆ÷½«ÏÔʾÕâ¸öÌæ´úÐÔµÄÎı¾¶ø²»ÊÇͼÏñ¡£ÎªÒ³ÃæÉϵÄͼÏñ¶¼¼ÓÉÏÌæ»»Îı¾ÊôÐÔÊǸöºÃÏ°¹ß£¬ÕâÑùÓÐÖúÓÚ¸üºÃµÄÏÔʾÐÅÏ¢£¬²¢ÇÒ¶ÔÓÚÄÇЩʹÓô¿Îı¾ä¯ÀÀÆ÷µÄÈËÀ´ËµÊǷdz£ÓÐÓõġ£
»ù±¾µÄ×¢ÒâÊÂÏî - ÓÐÓõÄÌáʾ£º
¼ÙÈçij¸ö HTML Îļþ°üº¬Ê®¸öͼÏñ£¬ÄÇôΪÁËÕýÈ·ÏÔʾÕâ¸öÒ³Ã棬ÐèÒª¼ÓÔØ 11 ¸öÎļþ¡£¼ÓÔØͼƬÊÇÐèҪʱ¼äµÄ£¬ËùÒÔÎÒÃǵĽ¨ÒéÊÇ£ºÉ÷ÓÃͼƬ¡£
ͼÏñ±êÇ©
±êÇ©ÃèÊö
<img>
¶¨ÒåͼÏñ¡£
<map>
¶¨ÒåͼÏñµØͼ¡£
<area>
¶¨ÒåͼÏñµØͼÖеĿɵã»÷ÇøÓò¡£
14.HTML ±³¾°
±³¾°£¨Backgrounds£©
<body> ÓµÓÐÁ½¸öÅäÖñ³¾°µÄ±êÇ©¡£±³¾°¿ÉÒÔʹÑÕÉ«»òÕßͼÏñ¡£
±³¾°ÑÕÉ«£¨Bgcolor£©
±³¾°ÑÕÉ«ÊôÐÔ½«±³¾°ÉèÖÃΪijÖÖÑÕÉ«¡£ÊôÐÔÖµ¿ÉÒÔÊÇÊ®Áù½øÖÆÊý¡¢RGB Öµ»òÑÕÉ«Ãû¡£
<body bgcolor="#000000">
<body bgcolor="rgb(0,0,0)">
<body bgcolor="black">
ÒÔÉϵĴúÂë¾ù½«±³¾°ÑÕÉ«ÉèÖÃΪºÚÉ«¡£
±³¾°£¨Background£©
±³¾°ÊôÐÔ½«±³¾°ÉèÖÃΪͼÏñ¡£ÊôÐÔֵΪͼÏñµÄURL¡£Èç¹ûͼÏñ³ß´çСÓÚä¯ÀÀÆ÷´°¿Ú£¬ÄÇôͼÏñ½«ÔÚÕû¸öä¯ÀÀÆ÷´°¿Ú½øÐи´ÖÆ¡£
<body background="clouds.gif">
<body background="http://www.w3school.com.cn/clouds.gif">
URL¿ÉÒÔÊÇÏà¶ÔµØÖ·£¬ÈçµÚÒ»ÐдúÂë¡£Ò²¿ÉÒÔʹ¾ø¶ÔµØÖ·£¬ÈçµÚ¶þÐдúÂë¡£
Ìáʾ£ºÈç¹ûÄã´òËãʹÓñ³¾°Í¼Æ¬£¬ÄãÐèÒª½ô¼Çһϼ¸µã£º
±³¾°Í¼ÏñÊÇ·ñÔö¼ÓÁËÒ³ÃæµÄ¼ÓÔØʱ¼ä¡£Ð¡ÌùÊ¿£ºÍ¼ÏñÎļþ²»Ó¦³¬¹ý 10k¡£
±³¾
Ïà¹ØÎĵµ£º
//»Ø³µ£º[\n\r\t]
$reg="|typeid=\"(.*)\" onsel.*[\n\r\t]*<a href="\" mce_href="\""#\">(.*)</a>|";
preg_match_all ($reg,
$html,
$out, PREG_PATTERN_ORDER);
foreach ($out as $value){
foreach ($value as $value2){
if(strlen($value2)<20)
echo ($value2."<br>");
}
} ......
METAÊÇÓÃÀ´ÔÚHTMLÎĵµÖÐÄ£ÄâHTTPÐÒéµÄÏìӦͷ±¨ÎÄ¡£META±êÇ©ÓÃÓÚÍøÒ³µÄÓëÖУ¬META±êÇ©µÄÓô¦ºÜ¶à¡£METAµÄÊôÐÔÓÐÁ½ÖÖ£ºnameºÍhttp-equiv¡£nameÊôÐÔÖ÷ÒªÓÃÓÚÃèÊöÍøÒ³£¬¶ÔÓ¦ÓÚcontent£¨ÍøÒ³ÄÚÈÝ£©£¬ÒÔ±ãÓÚËÑË÷ÒýÇæ»úÆ÷È˲éÕÒ¡¢·ÖÀࣨĿǰ¼¸ºõËùÓеÄËÑË÷ÒýÇ涼ʹÓÃÍøÉÏ»úÆ÷ÈË ......
ÕâÁ½¸ö²Ù×÷ĬÈÏÊDZ»ÆÁ±ÎÁ˵ģ¬ÐèÒªÊÖ¶¯À¹½Ø°´¼üÏûϢȻºó´¦Àí¡£
Èç¹ûǶÈëHTMLµÄ´°¿ÚÄò»µ½WM_KEYDOWNÕâÑùµÄÏûÏ¢£¬¾ÍÖ»ºÃÖ±½ÓÔÚÏûϢѻ·ÀïÀ¹½ØÁË£º
{
while (0 != (r = GetMessage(&msg, NULL, 0, 0))) {
if (r == -1) {
break;
}
if (CheckIfDealCopyPaste(msg)) {
......
1.ʲôÊÇ HTML Îļþ£¿
HTML Ö¸³¬Îı¾±êÇ©ÓïÑÔ¡£
HTML ÎļþÊÇ°üº¬Ò»Ð©±êÇ©µÄÎı¾Îļþ¡£
ÕâЩ±êÇ©¸æËß WEB ä¯ÀÀÆ÷ÈçºÎÏÔʾҳÃæ¡£
HTML Îļþ±ØÐëʹÓà htm »òÕß html ×÷ΪÎļþÀ©Õ¹Ãû¡£
HTML Îļþ¿ÉÒÔͨ¹ý¼òµ¥µÄÎı¾±à¼Æ÷À´´´½¨¡£
2.HTML ÔªËØ
HTML ÎĵµÊÇÓÉ HTML ÔªËع¹³ÉµÄÎı¾Îļþ¡£
HTML ÔªËØÊÇͨ¹ýʹÓà HTML ......
HTMLÎĵµÖ÷ÒªÓÉÈý²¿·Ö¹¹³É£ºÐò(Prologue)¡¢Í·£¨Head£©ºÍÖ÷Ìå(Body)¡£
“Ðò”λÓÚHIMLÎĵµµÄµÚÒ»ÐУ¬ËüµÄ×÷ÓÃÊǰѱàдÕâ¸öH1MLÎĵµÊ¹ÓõÄHTML
°æ±¾ºÅ¸æË߸øä¯ÀÀÆ÷¡£ÐòÔÚHTML3£®o°æ±¾Ö®Ç°½ÏÉÙʹÓá£
“Í·”ÓÃÀ´±êʶÕû¸öHTMLÎĵµµÄÊôÐÔ£¬ËüÓëÎÒÃdz£ÓõÄEmailÖе ......