Home > เริ่มต้นกับ CSS > div หรือ span

div หรือ span

เมื่อเรามีไฟล์ .css เรียบร้อยแล้ว และได้ทำการเรียกไฟล์ในหน้า html แล้ว tag หลักๆที่เราจะใช้สำหรับกำหนด layout แทน table ก็คือ <div></div> นั่นเอง ส่วน <span></span> ก็ให้ผลอย่างเดียวกัน แต่ div จะมีคุณสมบัติในการขึ้นบรรทัดใหม่ tag ที่สามารถขึ้นบรรทัดใหม่ก็ เช่น <h1>,<p>,<li>,<div> แต่ span นั้น จะไม่ขึ้นบรรทัดใหม่ จึงมักจะใช้ ครอบส่วนที่เป็น text ครับ

Related Articles


Share
Categories: เริ่มต้นกับ CSS
Tags:

About the author

Webmaster ของเว็บนี้และ www.toysmile.com กับ www.wondercutie.com ความสามารถ : web design, graphic design, CSS, PHP programming, wordpress, magento ตอนนี้กำลังสนใจ : การออกแบบ ตัวการ์ตูน คาแรคเตอร์ ^^

Website : http://www.divland.com

Facebook : http://www.facebook.com/divland

Twiter : http://twitter.com/divland


  1. test
    March 26th, 2009 at 17:42 | #1

    <?php echo”alert(‘doing’);”; ?>

  2. December 6th, 2009 at 17:50 | #2

    ความรู้แบบนี้ชอบจริงๆ

  3. December 6th, 2009 at 17:50 | #3

    ข้อมูลดีๆแบบนี้หามาบอกกันเรื่อยๆนะครับ

  1. January 15th, 2011 at 20:40 | #1