Entries tagged “html”

HasGeek

In August this year, I started working on a conference around HTML5. DocType HTML5 went live on October 9 with 200 participants, out of over 450 applicants. The event was the first coming out of a concept I had been toying with since the middle Barcamp Bangalore period in 2007. DocType HTML5 was an unexpected success. None of us thought it would go off as well as it did. Until two weeks before the event, we weren’t even sure it would happen.

The event helped shape the startup I had long wanted to do, to fix a personal problem: the lack of spaces in which to have in-depth technical conversations. HasGeek was named over a dinner conversation in one of the DocType HTML5 planning meetings, and our first act as a registered entity is to take DocType HTML5 across India. Registrations are now open for the Chennai (Nov 27) and Pune (Dec 4) editions, with upcoming editions in Hyderabad, Mumbai and Delhi scheduled for Jan and Feb 2011.

I expect that this event series will point to some aspect of the modern web that deserves a deep examination in the March-May 2011 period. Early feedback is pointing to the canvas tag.

On markup

I was looking up markup syntaxes recently and realised that one of the reasons I find writing in HTML tedious – apart from the verbosity – is that annotations are loaded up front. Consider this example dummy link pointing back at this post. If I were writing in HTML, I’d write:

Consider this <a href="/2009/09/15/on-markup">example dummy link</a>
pointing back at this post.

Contrast with popular markup languages, say Markdown (in two variations):

1. Consider this [example dummy link](/2009/05/15/on-markup)
   pointing back at this post.

2. Consider this [example dummy link][link] pointing back at this post.

[link]: /2009/05/15/on-markup

Or reStructuredText (two variations):

1. Consider this `example dummy link </2009/05/15/on-markup>`__
   pointing back this post.

2. Consider this `example dummy link`__ pointing back at this post.

__ /2009/05/15/on-markup

Notice how in HTML, the link target, which is an annotation on the text, appears before the text itself? It forces you to break the flow of thought and switch from writing mode to editing mode.

It gets worse when you have more content between the opening and closing.

Some background: I’ve spent a few weeks working on Zine, the blog engine powering this blog. Zine supports multiple markup formats, with the ability to add more via a plugin API. This post is written in Markdown, older posts are in reStructuredText, while the posts imported from LiveJournal use a parser I contributed that converts LJ’s markup to HTML. Because parsers cannot be trusted to be time-efficient, they are called once and the results cached in the database alongside the original text. The cached version is shown when a page is rendered.

Most blogs also have a feature to show only part of a post on the index page and the full text on the post’s own page. In WordPress, this happens when the user places a <!--more--> tag in their text, while LiveJournal uses <lj-cut text="optional cut text">. Zine needs a way to handle this across markup parsers. It does it by implementing a derivative of HTML called, appropriately, Zine Extensible Markup Language, which is basically the same thing as HTML but with a new <intro> tag and some other small features. If you’d like to introduce with a paragraph, cut, then write the rest, it’ll be something like this in ZEML:

<intro>
  <p>
    This is my introductory paragraph.
  </p>
</intro>
<!-- At this point, Zine will cut the post with a Read More link. -->
<p>
  And this is the rest of the post.
</p>

But what if you have a long intro leading to an enticing cut-line? You’ll get:

<intro text="and now, unveil the mystery...">
  <p>
    Blah, blah, blah and blah
  </p>
  <p>
    ...
    ...
    Even more blah
    ...
    ...
    Blah up to a compelling lead-in.
  </p>
</intro>

Whoops! The line that should have been last in your writing sequence moved all the way up to the top.* This is like top-posting in email, but worse: you write your own lines in reverse order.

Consensus in the CMS industry seems to be heading towards discouraging HTML markup and WYSIWYG editors, ushering users instead towards markup languages and limited-ability WYSIWYM editors. I can see why.

* Zine doesn’t actually support the text attribute on the intro tag, but I may add it.