Meaningful Markup “Semantics”
Well I am back to doing more on blogging about what I am up to her at The Art Institute of Dallas. This quarter (winter 2010) I am finally taking my clients side languages classes.
Semantics
I was doing a bit of research on meaningful semantics and the web and came across this blog by Kevin Dees. At first when I started my research into this topic I was really unsure what emantics and the web meant to eaach other. In Kevins article he talks about how we should use tags that are proper to what they are and use them when they need to be used. Not just use all sort of names to id a certain div if it does not make sense to what content is in that <div>. For example why would we name a <div id=”first-div”> when that <div> contains images of landscape photos. A more proper name would be <div id=”landscape-photo”>, so it would actually come down to using more of a description to name your content instead of just a name. Something else he touched on that I really found most interesting than anything else was how he is now using less <divs> and giving his content meaningful semantic by giving the content an id. For example instead of putting your <ul> <li></li></ul> inside a <div>, why not just give that <ul> an id and control it like that ( <ul id=”navigation”> ). I think this would also help in keeping our code cleaner and tighter.
I think that Kevin has many good points about meaningful semantics and I for one like to give meaning to the names i use to define the id of a <div> a class=” ” and I think that the idea of giving an id to your <ul> instaed of putting it inside a <div> sounds like a more meaningful way to code a tag.