Group Blog
 
 
ตุลาคม 2552
 
 123
45678910
11121314151617
18192021222324
25262728293031
 
5 ตุลาคม 2552
 
All Blogs
 

รวมโค๊ด สำหรับมือใหม่

การใส่ back ground


คำสั่งที่ใส่ใน script จะแสดงผลทุกบล็อก
ใส่ที่ช่องรายละเอียดจะแสดงเฉพาะที่บล็อกนั้น
อย่าลืมเอาเครื่องหมายนี้ * ออกด้วยทุกครั้ง



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>


ใส่รูปที่หัวบล็อก
วางใน Scrip Area

<*script>document.images[0].src = "urlรูปที่ต้องการใส่"

โค้ดใส่กรอบชั้นเดียวพร้อมใส่สี BGในกรอบ มีข้อความหรือรูป
วางใน Scrip Area

<*center><*table style="background:#000000 url();border: 2px dotted #FFCCCC;" cellspacing=20><*tr><*td align=center>ใส่รูปหรือข้อความที่นี่<*/td><*/tr><*/table><*/center>

ใส่เฮดได หรือภาพบนสุดของหน้าเว็บ
ใส่ที่ 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">

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

สร้างกรอบเขียนข้อความแบบง่ายๆ<*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% หรือน้อยกว่าตามต้องการ
ส่วนที่เป็น ตัวเลขได้ตามต้องการ ตัวเลขมากช่องระหว่าง บีจี ต่อ บีจี ก็ห่างมาก

คลิกเม้าส์ที่ภาพ ภาพจะเปลี่ยนขนาด
<*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">
ตัวเลขที่เป็นขนาดของรูปเปลี่ยนได้ตามความต้องการ

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

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

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

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

เปลี่ยน Now Here
ใส่ในช่อง slogan

<*script>iLength = document.images.length; for(i=0;i<*/script>

ลูกเล่นเมื่อเปลี่ยน Webpage
ใส่ที่ช่องsloganหรือScript

<*="Page-Enter" content="RevealTrans (Duration=3, Transition=23)">
<*="Page-Exit" content="RevealTrans (Duration=2, Transition=23)">

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

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

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

เปลี่ยนรูปเรารักในหลวง อยู่หลังชื่อเวลาเขียน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>

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

ข้อความที่เราเขียนวิ่งไปเรื่อยๆที่ไตเติ้ลบาร์
<*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>

ข้อความที่เราเขียนเปลี่ยนไปเรื่อยๆที่ 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>

เปลี่ยนสี 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>

เปลี่ยนรูปอมยิ้ม (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>

กรอบนับ 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>

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

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

ทำกรอบให้กล่อง 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 = ขนาด, ชนิด, และสีกรอบที่ต้องการ

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

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

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

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

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

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

โค้ดเชคข้อความหลังไมค์<*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>

โค้ดเปลี่ยนรูปตรง 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>

โค้ดเปลี่ยนรูปตรง 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>

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

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

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

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

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

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

จำนวนผู้ชมออนไลน์
<*script type="text/javascript" src="//fastonlineusers.com/on4.php?d=URL บล็อคของคุณ"><*/script> : Users Online

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

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





 

Create Date : 05 ตุลาคม 2552
12 comments
Last Update : 5 ตุลาคม 2552 7:26:27 น.
Counter : 611 Pageviews.

 

ขอบคุณสำหรับโค้ดดีๆค่ะ T^T

 

โดย: เด็กหัวส้ม 5 ตุลาคม 2552 10:19:03 น.  

 

ขอบคุณมากครับ (ผมทำไม่ค่อยเป็น)

 

โดย: nadashiko (nadashiko ) 5 ตุลาคม 2552 10:51:45 น.  

 

ขอบคุณค่ะ ช่วยได้มากเลยค่ะ

 

โดย: <Lhim> 5 ตุลาคม 2552 11:40:58 น.  

 

Thank you

 

โดย: goodlife (kearaly ) 5 ตุลาคม 2552 13:23:05 น.  

 

ขอบคุณจ้า

 

โดย: BabyBravo 5 ตุลาคม 2552 21:24:08 น.  

 

 

โดย: maamodJa 6 ตุลาคม 2552 23:03:36 น.  

 

ขอบคุนมากๆเลยนะค๊า
เก่งจังเลยคร่า

 

โดย: ปุยฝ้ายสายรุ้ง 7 ตุลาคม 2552 12:43:42 น.  

 

น่ารักจังเลยค่ะ

 

โดย: K.Panisa 12 ตุลาคม 2552 17:30:21 น.  

 

แวะมาทักทาย ขอบคุณมาก ๆ เลยน่ะค่ะ สำหรับโคด

 

โดย: immunecoco 13 ตุลาคม 2552 23:57:16 น.  

 

สุดยอด..ด...ด

 

โดย: นภาพันแสง 24 ตุลาคม 2552 12:02:44 น.  

 

สุดยอดอ่ะค่ะ
ขอบคุณมากๆเลย

 

โดย: moo_yid2 24 ตุลาคม 2552 21:03:51 น.  

 

denmashita doumo arigarigatou mata kimasuyo

 

โดย: nami (jena_naam ) 5 พฤศจิกายน 2552 19:02:51 น.  

ชื่อ : * blog นี้ comment ได้เฉพาะสมาชิก
Comment :
  *ส่วน comment ไม่สามารถใช้ javascript และ style sheet
 


kaikookza
Location :


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

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

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




TOP
Friends' blogs
[Add kaikookza's blog to your web]
Links
 

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