Grouping Elements with <div> and <span>

Author Topic: Grouping Elements with <div> and <span>  (Read 3547 times)

Offline beingchinmayTopic starter

  • Trade Count: (0)
  • Jr. Member
  • **
  • Thank You 1
  • Posts: 73
  • Karma: 0
  • Gender: Male
  • I am Chinmay
    • Modular Kitchen Designer
Grouping Elements with <div> and <span>
« on: 02-10-2017, 02:34:32 »
The <div> and <span> elements allow you to group several elements to create sections or subsections of a page. On their own, they will not affect the appearance of a page, but they are commonly used with CSS to allow you to attach a style to a section of a page . For example, you might
want to put all of the footnotes on a page within a <div> element to indicate that all of the elements within that <div> element relate to the footnotes. You might then attach a style to this <div> element so that they appear using a special set of style rules.


The <div> element is used to group block-level elements:

Quote
<div class=”footnotes”>
<h2>Footnotes</h2>
<p><b>1</b> The World Wide Web was invented by Tim Berners-Lee</p>
<p><b>2</b> The W3C is the World Wide Web Consortium who maintain many Web
standards</p>
</div>


 

Related Topics

  Subject / Started by Replies Last post
4 Replies
3143 Views
Last post 12-09-2011, 15:58:07
by electra
6 Replies
4139 Views
Last post 11-28-2013, 04:13:38
by ComoliWesta
0 Replies
2075 Views
Last post 03-10-2015, 05:52:27
by BrendanForum
0 Replies
5116 Views
Last post 04-26-2016, 01:52:06
by immediate
3 Replies
412 Views
Last post 10-10-2023, 04:46:47
by brantelyolivia1320