รวมโค้ดไว้..กันหาย กันลืม

แบบว่านานๆๆ แต่งที พอ..หายไปนานๆๆก็ลืมได้เหมือนกัน..อย่ากระนั้นเลยขอรวบรวมโค้ดที่น่ารัก จากเพื่อนๆๆที่น่ารักมารวมๆๆ เก็บไว้ใช้กัน ไว้แจก ต่อๆๆ ไปอีกนะค่ะ..ขอบคุณเพื่อนๆๆมากเลย

การใส่ back ground

ส่ใน script area อย่าลืมเอาเครื่องหมายนี้ * ออกด้วยนะจ๊ะ

1.ใส่ bg แบบ tile
<*style>body{background-image:url(xxx);} <*/style>

2.ใส่ bg แบบ fixed ไม่ให้ bg เลื่อนลงตาม scroll bar
<*style>body{background-attachment: fixed;background-image:url(XXX);} <*/style>

3.ใส่ bg เป็นรูปภาพเดียวทั้งหน้า
<*style>Body{background-image:url(http:XXX);background-position: center (bottom left..etc..);background-repeat: no-repeat;background-attachment: fixed;background-color:ใส่โค้ดสี;} <*/style>

4.ใส่ bg โดยใช้สี
<*style>body{background:โค้ดสี}><*/style>

5.ให้ภาพมุมบล็อกอยู่..กลางบล็อก
<*style>Body {background-image:url("ใส่ URLของภาพที่จะใช้");background-position:center;background-repeat: no-repeat;background-attachment: fixed;background-color: "ใส่สี Bg ที่ต้องการ";}<*/style>

6.ให้ภาพมุมบล็อกอยู่ ..มุมขวากลาง
<*style>Body {background-image:url("ใส่ URLของภาพที่จะใช้");background-position:right center;background-repeat: no-repeat;background-attachment: fixed;background-color: "ใส่สี Bg ที่ต้องการ";}<*/style>

7.ให้ภาพมุมบล็อกอยู่ ..มุมขวาล่าง
<*style>Body {background-image:url("ใส่ URLของภาพที่จะใช้");background-position:right bottom;background-repeat: no-repeat;background-attachment: fixed;background-color: "ใส่สี Bg ที่ต้องการ";}<*/style>

8.ให้ภาพมุมบล็อกอยู่ ..มุมซ้ายบน
<*style>Body {background-image:url("ใส่ URLของภาพที่จะใช้");background-position:left top;background-repeat: no-repeat;background-attachment: fixed;background-color: "ใส่สี Bg ที่ต้องการ";}<*/style>

9.ให้ภาพมุมบล็อกอยู่ ..มุมซ้ายกลาง
<*style>Body {background-image:url("ใส่ URLของภาพที่จะใช้");background-position:left center;background-repeat: no-repeat;background-attachment: fixed;background-color: "ใส่สี Bg ที่ต้องการ";}<*/style>

10.ให้ภาพมุมบล็อกอยู่ ..มุมซ้ายล่าง
<*style>Body {background-image:url("ใส่ URLของภาพที่จะใช้");background-position:left bottom;background-repeat: no-repeat;background-attachment: fixed;background-color: "ใส่สี Bg ที่ต้องการ";}<*/style>

11.บีจีจากภาพเล็กๆหลายภาพเรียงกัน
<*style>body{background-attachment: fixed;background-image:url(ใส่ URLของภาพที่จะใช้);}<*/style>

12. โค๊ด สำหรับทำบีจีแจก
(ทำให้ทดลองคลิกดูลายบีจีได้เลย)
<*a href=javascript:document.body.style.backgroundImage='url("urlภาพbg")'; document.close();><*IMG src="urlภาพbg แบบกำหนดขนาดเล็ก" width="200"<*/a>

13. โค๊ด ให้คลิกดูภาพขนาดจริง
(เมื่อคลิกจะแยกออกไปแสดงอีกหน้าเว็บเพจ)
<*a href="URL ของภาพ" target=_blank><*img src=URL ของภาพ width='ความกว้างที่จะแสดง'height='ความสูงที่จะแสดง' border=0><*/a>

14. วิธีใส่โค๊ด ลงในกล่องไม่ว่าจะใส่กล่อง รึไม่ใส่กล่อง
แต่ถ้าอยากแจกโค๊ด รึอยากแปะโค๊ดให้เป็นโค๊ด(ตัวหนังสือ)
ก็ต้องเปลี่ยนสัญลักษณ์ของโค๊ดตามนี้ค่ะ


15.โค๊ดใส่ภาพที่จะให้เพื่อนๆ ทดลองคลิกดูได้ .. ใช้โค๊ดนี้
ภาพมุมซ้าย-ขาว ปรับขนาดของภาพได้จาก width และ height
<*a href=javascript:document.body.style.backgroundImage='url("URL ของภาพ")';document.close();><*IMG src="URL ของภาพ" width="150" height="150" border="0"><*/a>


16.โค้ดสำหรับเปลี่ยนรูปจุดกลมๆ สีดำหน้า Group Blog
<*style>ul{list-style: ;list-style-image: url(....url ของรูป....);<*/style>


17.ใส่รูปที่หัวบล็อก
วางใน Scrip Area
<*script>document.images[0].src = "urlรูปที่ต้องการใส่"

18.โค้ดใส่กรอบชั้นเดียวพร้อมใส่สี BGในกรอบ มีข้อความหรือรูป
วางใน Scrip Area
<*center><*table style="background:#000000 url();border: 2px dotted #FFCCCC;" cellspacing=20><*tr><*td align=center>ใส่รูปหรือข้อความที่นี่<*/td><*/tr>& lt;*/table><*/center>

19.ใส่เฮดได หรือภาพบนสุดของหน้าเว็บ
ใส่ที่ slogan
<*img src='url ของรูปที่ใส่'border=0>
ถ้าอยากจะให้รูปอยู่ตรงกลาง ต้องใช้โค้ดข้างล่างนี้เพิ่ม
<*img src="images/spacer.gif" width="x"
height="10"*>
ใส่ต่อกันเลยและเปลี่ยนขนาดตรง x ไปเรื่อยๆ จนได้ขนาดที่ต้องการ ตามตัวอย่างข้างล่างนี้
เช่น <*img src='urlของรูปที่ใส่'border=0>
<*img src="images/spacer.gif" width="100" height="10">

20.ใส่รูปเฮดบล็อกแบบกำหนดความยาว
<*center><*img src="http:… ภาพเฮดบล็อก " width="1224" height="140" /><*/center>

21.สร้างกรอบเขียนข้อความแบบง่ายๆ
<*table border="0" cellspacing="10" cellpadding="5" width="100%" align="center" style="background-image: url('ใส่//บีจีที่1')"><*tbody><*tr><*td align="center" valign="middle" style="background-image: url('ใส่//บีจีที่2')"><*table border="0" cellspacing="5" cellpadding="5" width="100%" align="center" style="background-image: url('ใส่//ของบีจีที่3')"><*tbody><*tr><*td align="center" valign="middle">เขียนข้อความ<*/td><*/tr><*/tbody& gt;<*/table><*/td><*/tr><*/tbody><*/table>

100% ลดให้เหลือ 80%-90% หรือน้อยกว่าตามต้องการ
ส่วนที่เป็น ตัวเลขได้ตามต้องการ ตัวเลขมากช่องระหว่าง บีจี ต่อ บีจี ก็ห่างมาก

22.คลิกเม้าส์ที่ภาพ ภาพจะเปลี่ยนขนาด
<*img src="urlของรูป" height="200" width="150" onclick="this.src='urlของรูป';this.height=400;this.width=300" ondblclick="this.src='urlของรูป';this.height=200;this.width=150">
ตัวเลขที่เป็นขนาดของรูปเปลี่ยนได้ตามความต้องการ

23.cursor/เมาส์
<*body style="cursor:url( URLรูป.ani )">

24.ลบกรอบและสีขอบของบล็อก
(ใส่ในscript จะแสดงทุกหน้า ใส่ใน table จะแสดงแค่table นั้น) โค้ด=
<*style>table {background-color: transparent;border-style: none;border-spacing: none;}TD {border: none;border-color: none;background: none;}<*/style>

25.ทำกรอบรอบๆบล็อก
<*script language="JavaScript1.2"> if (document.all)
document.body.style.cssText="border:10 ridge โค้ดสี"<*/script>

26.เปลี่ยนรูปอมยิ้ม (log in) ท้ายชื่อ
<*script>iLength = document.images.length; for(i=0;i<*/script>

27.เปลี่ยน Now Here
ใส่ในช่อง slogan
<*script>iLength = document.images.length; for(i=0;i<*/script>

28.ลูกเล่นเมื่อเปลี่ยน Webpage
ใส่ที่ช่องsloganหรือScript
<*="Page-Enter" content="RevealTrans (Duration=3, Transition=23)">
<*="Page-Exit" content="RevealTrans (Duration=2, Transition=23)">

29.กลับไปหน้าหลัก
<*font face="MS Sans Serif" size="1"><*a href="//ของหน้าที่ตั้งเป็นหน้าหลัก">กลับไปหน้าหลัก<*/
ตัวอักษรและขนาดเปลี่ยนได้ตามความต้องการ

30..ส่งหลังไมค์
<*a href ="URL หลังไมค์" target='_blank'> ส่งหลังไมค์ที่นี่<*/a>

31.เปลี่ยนจุดหน้าหัวข้อ bullet
(ใส่ในscript จะแสดงทุกหน้า ใส่ใน table จะแสดงแค่table นั้น) โค้ด=
<*style>ul{list-style: ;list-style-image: url(รูปที่ต้องการ);}<*/style>

32.เปลี่ยนรูปเรารักในหลวง อยู่หลังชื่อเวลาเขียนcomment
<*script>iLength = document.images.length; for(i=0;i<*iLength;i++)if(document.images[i].src=="//www.bloggang.com/images/smile.gif") {document.images[i].src="ใส่รูปที่นี่..................."}& lt;*/script>

33.ลบกรอบใน Profile
<*style>img {border: none;}<*/style>

34.ข้อความที่เราเขียนวิ่งไปเรื่อยๆที่ไตเติ้ลบาร์
<*SCRIPT LANGUAGE="JavaScript">
<*!-- Begin
var scrl = "เขียนข้อความที่นี่ ";
function scrlsts() {
scrl = scrl.substring(1, scrl.length) + scrl.substring(0, 1);
document.title = scrl;
setTimeout("scrlsts()", 300);
}
// End -->
<*/script>

<*/head>

<*BODY onLoad="scrlsts()"><*/body>

35.ข้อความที่เราเขียนเปลี่ยนไปเรื่อยๆที่ Title Bar (แถบสีฟ้าที่อยู่บนสุด)
<*script language="Javascript">
var tt = 0;
var FMess = new Array("ข้อความที่ 1","ข้อความที่ 2","ข้อความที่ 3")
function FTitle()
{
document.title = FMess[tt]
tt = (tt <* (FMess.length -1)) ? tt + 1 : 0;
setTimeout('FTitle()',700);
}
FTitle();
<*/script>

36.เปลี่ยนสี scroll bar
ใสในscript จะแสดงทุกหน้า ใส่ใน table จะแสดงแค่table นั้น) โค้ด=
<*style type="text/css">body {scrollbar-arrow-color: ใส่โค้ดสี;scrollbar-highlight-color:ใส่โค้ดสี; scrollbar-base-color:ใส่โค้ดสี;scrollbar-dark-shadow-color: ใส่โค้ดสี;scrollbar-track-color:ใส่โค้ดสี;}<*/style>

37.เปลี่ยนรูปอมยิ้ม (log in) ท้ายชื่อ
ใส่ไว้ที่ช่อง script
<*script>iLength = document.images.length; for(i=0;i<*iLength;i++) if(document.images[i].src=="//www.bloggang.com/images/smile.gif") {document.images[i].src="//ของรูปที่ต้องการ"}<*/script>

38.กรอบนับ Comment โดยคุณ กึ่งยิงกึ่งผ่าน
<*script>HTML = document.body.innerHTML; CommentCount = 0; var reg = new RegExp("-- Comment", "gm"); while(reg.test(HTML)) CommentCount++; CommentCount--; for(i=1; i<*=CommentCount; i++){ originalHtml = document.getElementById( i ).innerHTML; beforeHtml = '<*fieldset style="border:โค้ดสี groove 3px; padding:20"> <*legend align=center><*img src=URL ของรูป> ความเห็นที่ ' + i + ' <*img src=URL ของรูป><*/font><*/legend>';document.getElementById( i ).innerHTML = beforeHtml + originalHtml;}<*/script>

39.คลิ๊ก MOUSE ขวาแล้วไม่มีอะไรขึ้นมาเลย
<*script type="text/javascript" src ="//www.geocities.com/paradijs.bloggang/mouse.js"> <*/script>

40.โค้ด กลับขึ้นข้างบนของ Page
<*center><*a href="#top">TOP<*/a><*/center>

41.ทำกรอบให้กล่อง summit
<*script>
document.forms.reply.Submit.value = "Submit";
document.forms.reply.Reset.value = "Reset";
document.forms.reply.Submit.style.width = 100;
document.forms.reply.Reset.style.width = 100;
document.forms.reply.Submit.style.height = 30;
document.forms.reply.Reset.style.height = 30;
document.forms.reply.Submit.style.backgroundColor = "black";
document.forms.reply.Reset.style.backgroundColor = "black";
document.forms.reply.Submit.style.color = "#e65c7c";
document.forms.reply.Reset.style.color = "#e65c7c";
document.forms.reply.Submit.style.border = "3px double #e65c7c";
document.forms.reply.Reset.style.border = "3px double #e65c7c";
<*/script>
Submit = เปลี่ยนเป็นคำที่ต้องการแทน Submit
Reset = เปลี่ยนเป็นคำที่ต้องการแทน Reset
100 = ความยาวของกรอบ
30 = ความสูงของกรอบ
black = สีพื้นหลังที่ต้องการ
#e65c7c = สีตัวอักษรที่ต้องการ
3px double #e65c7c = ขนาด, ชนิด, และสีกรอบที่ต้องการ

42.ใส่รูปให้ Reed
<*script>iLength = document.images.length; for(i=0;i<*/script>

43.ตัวอักษรวิ่งบนแถบสี
<*font color="โค้ดสีตัวอักษร "><*marquee direction="left" style="background:โค้ดสีพื้น ">ข้อความ<*/marquee>

44.ตัวอักษรวิ่งในกรอบ
<*marquee style="border:โค้ดสีกรอบ 2px SOLID">ข้อความ<*/marquee>

45.ทำลิงค์ที่เปิดในหน้าเดียวกัน
<*a href="ใส่..//..ของเวป">เขียนข้อความ<*/a>

46.ทำ Link เปิดหน้าใหม่
<*a href =URL Link target=_blank>ข้อความที่ต้องการ<*/a>

47.ทำ Link
<*a href ="URL Link">ข้อความที่ต้องการ<*/a>

48.โค้ดเชคข้อความหลังไมค์
<*a href ="//www.pantip.com/cafe/krazip/index.php" target=_blank>เชคข้อความหลังไมค์<*/a>
หรือใส่รูป
<*a href="//www.pantip.com/cafe/krazip/index.php" target=_blank><*img src="URL ของรูปที่ต้องการ" border="0"><*/a>

49.โค้ดเปลี่ยรูปตรงฝากข้อความหลังไมด์
<*script>iLength = document.images.length; for(i=0;i<*/script>


50.โค้ดเปลี่ยนรูปตรง My Network
<*script>iLength = document.images.length; for(i=0;i<*iLength;i++) if(document.images[i].src=="//www.bloggang.com/images/icon_network_mini1.gif") {document.images[i].src="ใส่ URL ของรูปที่ต้องการเปลี่ยน"}<*/script>

51.โค้ดเปลี่ยนรูปตรง Rss Feed
<*script>iLength = document.images.length; for(i=0;i<*iLength;i++) if(document.images[i].src=="//www.bloggang.com/images/icon_rss.png") {document.images[i].src="URL ของรูปที่ต้องการ"}<*/script>

52.ข้อความต้อนรับ
<*Script Language= "VBScript">alert("ใส่ข้อความตรงนี้เลยจ้า")<*/Script>

53.ข้อความบอกลา
<*Script Language="VBScript">
Sub Window_onUnLoad()
alert("ใส่ข้อความตรงนี้เลยจ้า")
End Sub
<*/Script>

54.กล่องใส่โค๊ดที่มีสกอร์บาร์ เอาไว้แจกที่บล็อก
<*DIV align=left style=' color: #000000; background-color: #CCCCFF; border: solid 2px black; width: 400px; height: 100px; overflow: scroll; '><*/DIV>

ขนาดของกล่องสามารถเปลี่ยนได้ตามต้องการ
ถ้าอยากใส่โค้ดไว้แจกโดยไม่ต้องใส่เครื่องหมาย*ให้ใช้โค้ด
< แทนเครื่องหมาย <
แต่เมื่อกดPublishแล้วไม่สามารถแก้ไขได้อีก
ถ้าจะแก้ไขต้องทำใหม่หมด

55.Code ทำให้ตัวหนังสือห่าง
<*style>p{letter-spacing:2px;}<*/style>

<*style>body, ul, li, p{letter-spacing:2px;}<*/style>

56.จำนวนผู้ชมออนไลน์

<*script type="text/javascript" src="//fastonlineusers.com/on4.php?d=URL บล็อคของคุณ"><*/script> : Users Online

57.จำนวนผู้ชมทั้งหมด

รวมทั้งหมด <*script src="//fastwebcounter.com/secure.php?s=url บล๊อคของคุณ"><*/script> คน

58.โค้ดป้องกันการยืดของหน้าบล็อก เวลาคนอื่นใส่รูปใหญ่เกินไป
<*style>div.comment{overflow: auto; width: 400px; height: auto;}<*/style>
width: 400px ----- เปลี่ยนขนาดได้


ขอบคุณค่ะ ขอบคุณค่ะ


Create Date : 20 ตุลาคม 2552
Last Update : 20 ตุลาคม 2552 15:59:43 น. 7 comments
Counter : 1251 Pageviews.

 
ว้าวววขอบคุงคร้า


โดย: สาวสุพรรณฝันหวาน วันที่: 20 ตุลาคม 2552 เวลา:16:27:57 น.  

 
แวะมาทักทายค่ะ ขอให้มีความสุขมากๆ นะคะ


โดย: Elbereth วันที่: 20 ตุลาคม 2552 เวลา:19:47:42 น.  

 
ขอบคุณมากค่ะ


โดย: Sasi_chon วันที่: 22 ตุลาคม 2552 เวลา:16:17:11 น.  

 
Thanks na ka


โดย: sjt วันที่: 23 ตุลาคม 2552 เวลา:1:04:16 น.  

 
ขออนุญาติเอาไปรวมรวบไว้ที่บล๊อคเหมือนกันนะคะ ขอบคุณคะ


โดย: orbside_d วันที่: 14 พฤศจิกายน 2553 เวลา:16:47:28 น.  

 
ขออณุญาต แอดน้องไว้ในบล็อกนะคะ
ขอบคุณที่ให้ความรู้การทำบล็อก
มีความสุขมากๆนะคะ


โดย: Tahoe วันที่: 16 พฤศจิกายน 2553 เวลา:15:34:22 น.  

 
ตามสบายเลยค่ะ


โดย: zita_jira วันที่: 17 มกราคม 2554 เวลา:18:21:14 น.  

ชื่อ :
Comment :
  *ใช้ code html ตกแต่งข้อความได้เฉพาะสมาชิก
 

zita_jira
Location :
พระนครศรีอยุธยา Thailand

[ดู Profile ทั้งหมด]

ฝากข้อความหลังไมค์
Rss Feed

ผู้ติดตามบล็อก : 1 คน [?]




Cartoons
Group Blog
 
<<
ตุลาคม 2552
 
 123
45678910
11121314151617
18192021222324
25262728293031
 
20 ตุลาคม 2552
 
All Blogs
 
Friends' blogs
[Add zita_jira's blog to your web]
Links
 

 Pantip.com | PantipMarket.com | Pantown.com | © 2004 BlogGang.com allrights reserved.