Should Students Learn to Write HTML Code?

I saw an email from someone today suggesting that they would be starting next term to teach their students to write HTML code from scratch, so the kids could make their own webpages. My initial reaction when I read this message was to ask “Why?” Why would anyone bother to learn HTML coding from scratch when there are so many great editing tools around? Surely, in a WYSIWYG world, learning how to to actually write HTML code is a complete waste of time? With so many great web editing tools around, isn’t learning to write raw HTML code a pointless exercise?

In once sense, these are valid questions. There’s no doubt that the majority of websites these days are created using a templated approach and an “engine” such as WordPress, Drupal, Joomla, Squarespace, etc. It’s also true that for any really customised web work, it would still fall to a workhorse like Adobe Dreamweaver or something else, such as excellent free tools like KompoZer or NVU editor.

However, on reflection, I think there is a great deal to be said for being able to understand basic HTML code. Take using Moodle as an example… as much as I would like to tell my teachers at school that Moodle has a wonderful WYSIWYG editor, and that it will automatically format all the text and images for you just by cllicking on the little buttons in the editing bar, the fact remains that I still find myself hitting the little <> button on the Moodle editor bar to dive into HTML code on an almost daily basis just to fix little quirky things that are going on.

It’s also true that, although you can use the buttons on the editor to align text to the left or right (which in HTML, behaves quite differently to how it behaves in, say, Word) knowing a little bit about what those buttons are actually doing on a code-level makes it much easier to predict how things will actually look. Being able to manually write a link to a URL, being able to strip out some rogue heading level text, fixing paragraphs that have gone askew because of a stray tag, and so on… these are all things that I find myself doing fairly regularly, even WITH access to fancy WYSIWYG editing tools. I taught myself the basics of writing HTML nearly 15 years ago now (well, to be completely honest, one of my students taught me!) and I can’t even begin to tell you how handy it has been and how often I have used that knowledge. Although I would like to think that we are living in a world where it SHOULD be completely unnecessary to know how to write HTML source code, the truth is that over the years it’s proven itself to be a damn handy skill!

Even being able to use the provided code to put an YouTube video or a Google Map into a wiki or blog, for example… sure, you CAN do it without having the slightest idea of how it all works, but if you want to make a minor adjustment such as changing the width or height of the frame, just being unintimidated by the code makes a big difference to your general level of technological fluency.

I’m not saying that everyone should be able to write heavy-duty CSS code or be able to create complicated PHP script, but HTML is dead simple… and for the number of times I find myself rescuing a page because of a relatively simple adjustment to the underlying code… I gotta say, I can’t think of anyone who would not benefit from knowing the basics.

So, should this teacher spend time teaching his kids to code? Some may disagree, but I say yes. My advice would be to teach kids to write a fairly simple webpage. They should know the core structure of html, head and body. They should understand heading levels (and depending on the age of the students, how these can be tied to style sheets). They should know how to manually write (or at least understand) the code for a hyperlink, for an image, and for an embed. It’s good to know these basics. I guarantee you those kids will find them useful at some point in their future.

For the majority of your students, that’s probably all they need to know. Then, once they have a grip on the basics, switch over to a decent visual editor like Dreamweaver or similar… some tool that lets them switch back and forth between code view and output view. Output view will make SO much more sense once they see the relationship between code and output!

And who knows, just that small exposure to the underlying code could make all the difference to that one kid in your class. It could open them up to a whole world of coding and being interested in what really makes a computer tick. In this WYSIWYG world, God knows we need more kids like that!

And if nothing else, you’ll at least understand why the picture that goes with this post is so funny! 🙂

What about you?  Do you think teaching kids to understand HTML is a useful skill, or a waste of time?

Image: ‘html tag italicized
http://www.flickr.com/photos/30127486@N00/346483297

CC BY-SA 4.0 Should Students Learn to Write HTML Code? by Chris Betcher is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License.

18 Replies to “Should Students Learn to Write HTML Code?”

  1. I believe kids should know a little about HTML, especially those that would like to pursue ICT as a subject in senior school. I teach ICT to senior students, and it is baffling how some kids end up in my class without ever being exposed to any HTML. Yes, we use Dreamweaver, but we also need to learn some of the basics, like you mentioned in this blog post. Also, I think TEACHERS should know a little bit about HTML, for the same reasons…we will be expected to use wikis, blogs etc more and more as teaching tools. We should know the basics, so as not to be daunted by the code. 🙂

  2. I teach my students to make a website using nothing other than TextEdit and a browser. It gives them a real sense of achievement, sure some already know HTML codes and some think it is a waste of time because of the WYSIWYG alternatives but the vast majority appreciate the opportunity to have some understanding of what is happening behind the nice WYSIWYG interfaces we use so readily these days.

  3. my 12year old`s science project was “how much smaller is a page coded by hand than one done in ms word?”

  4. Even if you are using a WYSIWYG editor you still need to understand the most basic HTML tags. WordPress for example (like most CSS based editors) doesn’t insert (gasp) tables for you. If you would like one in your page or post you still have to code it by hand. I think that is more important for students to learn and understand CSS, since this is the code that is really driving modern webpages.

  5. I use Joomla for my website, but I still am very greatful I learnt a little bit of HTML because sometimes the WYSIWYG editors are a little buggy and so I can go into the HTML and add a tag here and there. You don’t need to build your site from it, but the basics are quite useful.

  6. I do believe it is important for students to understand the basic tags. Just simply being able to control some of the strange things that WYSIWYG editors do to layout is a plus! I have been coding by hand since 1995, and still only work in the code side of Dreamweaver. I use basic HTML codes every day to tweak a Blogger template, a Google Sites page, or even the assignments in my Moodle-hosted course.

  7. I saw the email too and thought “Why?”
    I agree that there is a place and time for being able to use HTML code to create certain elements or fix WYSIWYG errors, but would it not be better for the kids to use tools to create pages simply and easily – perhaps with a focus of reflecting on learning, and then only dig into the HTML code when they have a *need* to fix something? Would that make the learning more relevant, rather than learning something for just-in-case?
    I know that’s how I learnt the little bits of HTML I do know – and when something new happens, a bit of research gets me to a solution.
    I like the image you used also Chris.

  8. A long time ago I learnt Pascal and Cobol from a teacher, I’ve never used either of them (although they did get me a job). Now, I can find my way around HTML to make a little tweak here and there but I don’t really *know* even basic HTML, much less CSS. If there’s something I need to do I work it out when I need it. Did I learn that as part of my programming course or is it something I learned in the High School library with my teachers helping me research whatever project I was working on? (I don’t know).

    You taught yourself … teach them to teach themselves … it’s gonna change anyway.

  9. I start my fourth and fifth grade students with wikispaces. I show them the code incidentally, but I have never invested time in teaching them the code. It might be a good idea. wiki code so easily goes awry in editor. I think the algebraic nature is confusing to them, but as we all know, some pick it up independently.

  10. Many kids love code; some hate it! I’ve used Dreamweaver with kids as a basic tool, and the “code lovers” will always work in at least split view; the “code haters” will grumble when expected to do anything in code. One thing that spurs some of them on is that knowing simple code can dress up our use of the Nicenet ICA.

    Of course there are also those who will type what they want in Dreamweaver and then just copy the code for their Nicenet post. Hey, I’m OK with that as they have to at least recognize what to copy to have it turn out right!

    I too taught myself HTML, looking at others pages and asking myself: “How did they do that?” I’d save the page in code and try out little pieces at a time to see what it did. Ended up created the entire website for our school with code; there just weren’t any editors out there yet.

    Agreeing with Christopher Rogers, I think today the more important thing to learn and understand is CSS. Again, just try making a change see what happens. Some awesome 12 year old kids did that this year creating their GVC website and went way beyond what I taught the class.

  11. I think knowing basic HTML is necessary for any student these days. If nothing else, to understand how to read an embed code before they place it on their site.
    Understanding HTML and CSS has allowed me to totally tweak a wordpress theme and also a website template.
    Understanding HTML has helped me in adding text to a sidebar on that same blog and get it to look as I wish with and 🙂
    Understanding HTML has helped tremendously when trying to find out why that certain something does not look right on a webpage.
    And understanding HTML has given me many opportunities when I see something on a page or blog that I wish to possibly use on my page.
    A basic understanding I think should be woven into the Digital Footprint Curriculum we are teaching our students. A more thorough understanding should be encouraged for those students who WISH to take it to a higher level.

    And have to agree…..I taught myself first with Front Page, then onto Dreamweaver, and then totally tweaking out the CSS and PHP (oh, another option) on self-hosted Word Press Blog Template.

  12. I like the picture.

    I agree with Mr Gray and Kelly and this is because it aligns well with my experience in the IT industry – technology moves too quickly such that learning to learn and learning to anticipate are ]most important.

    This means, don’t teach how to write HTML. Teach them how to read HTML…and then, create a task with a challenge such as, you said yourself, embed an image and/or video of a specific dimension.

    Then, show the students how to help themselves. I like w3schools .

    One of the best challenges for a programmer is not writing from scratch – rather tweaking something that’s already there and making it more effective, efficient and “elegant”.

    That’s learning to learn. In learning to anticipate, you can model the thinking process. Using the same example above, you can ask – if you can embed a hyperlinked picture in a word document, can you do the same a web page? If you can do this in FrontPage, can you do the same in DreamWeaver? In other words, learning to anticipate is learning to transfer knowledge from one tool to the next….it’s rare that techies start from scratch whenever new technology is introduced.

    So there’s my take on teaching HTML. I hope it makes sense.

  13. I definitely think it’s important for everyone to know HTML- just for similar reasons to what you’ve said. So that they can change things, understand things, and have better control over their internet experiences.

    I think one of the majoy concerns I have with teaching html is how it will be asessed. Even in my husband’s web design course at Uni (unfortunately his Uni isn’t too crash hot on RPL- he’s already working as a web designer and Moodle maker currently), it is SO out dated, and he is asked to make websites using, yes, just html, that are completely workplace irrelevant.

    He actually wrote a bit of a speal about it here: http://lukecarbis.com/blog/2010/06/internet-speeds-page-sizes/

    Anyway, back to assessment. I think that being able to MANIPULATE html is more important then being able to write it from scratch, and UNDERSTANDING it is more important then writing it from scratch, so the assessment should reflect that. 🙂

  14. Wow Chris, interesting discussion. I like the fact as someone else said that a lot of the students get a real sense of achievement out of being able to use basic code. Yes some will hate it but some do love it and gets some motivated for doing real programming. Also I think it is good for them to get the basics so they can get more into it and tweak their own web pages if needed.

  15. I believe that the basic html is important. I don’t know anything about it and I wish somebody taught me before. In this times now, wherein people likes to customize understanding html is quite important. Still, students should not deal with it much since there are a lot of software out there doing an even better job for us. I believe what’s important to teach is about the content. Teachers should teach how to provide valuable content, how to provide the student’s voice in the best manner and the internet ethics.

    1. Content is the most important thing. Really?? Content?

      There are so many more things about a contemporary education that I’d put in front of content.

  16. Chris,

    I taught my third graders how to write simple HTML so they could add italics, bold, or a hyperlink to their comments on our blog. At first, I thought it would be too difficult. I was so wrong! They ♥ed emphasizing important words or phrases and it really ended up making their comments better. If they had a low-level comment with nothing to emphasize, they noticed and improved it! (One students realized he could combine the italics and bold and have both!)

    I also liked the idea of introducing them to code. Everyone used it, but I could tell that some kids were quite interested in the code. As you said, who knows where that interest might lead?

    And, I must say, that is a fabulous image to go with this post! 🙂 You’re very funny!

  17. I work as a Business Analyst and I obtained my position many years back through impressing some managers with an Infopath form I attached to an Access db to track work from one department to another. I never understood much of the xml behind Infopath and it has shamed me over the years, despite learning to be a proficient SQL and PL/SQL writer. There is something to be said about understanding the nuts and bolts and being able to write queries from scratch without having editors such as Toad doing all the work. Likewise, I am now learing HTML from scratch and I believe it is finally laying a foundation to surpass the trial and error efforts of the past in making changes to HTML. A proper foundation facilitates the seeking of answers when problems arise versus blind Googling.

That's all well and good, but what do YOU think?