Skip to content
View in the app

A better way to browse. Learn more.

Web Designer Forum

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

New to html5, not sure what tag to use

Featured Replies

Hi, as the title says, I am new to html 5, and I have a question about what tag to use in a fairly common situation.

 

I have a list of blog posts, which are basically articles, but they are shortened and once you click on them you get the whole article.

 

When I open the whole post I am going to wrap the content in an article tag, but what should I do with the shortened versions?

 

To be defined as an article they should be able to stand on their own, but since they display only a portion of the article I think that's clearly not the case.

 

So, should I use the section tag on each of those elements or just wrap the whole thing in a section labeled "latest post" and use div's to wrap each element, does it even matter which tag do I choose in this case?

 

 

An older article, but quite helpful in making your decision http://www.brucelawson.co.uk/2010/html5-articles-and-sections-whats-the-difference/. You can still use the div tag - section and article are are to make your markup more structured and semantic. It's your call, but I would wrap the 'excerpts' in a div personally but I think some would wrap in an article still.

Create an account or sign in to comment

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.