Quick example of a header section of a web page that contains a few form elements done with RML:

  markup: {
    header: function() {
      var $header = RML.div({
        id:'header',
        content: RML.h1('The Chat') +
        RML.hr() +
        RML.div({
          class:'message-form',
          content: RML.textarea({
          name:'txt-message',
          id:'txt-message',
          rows:'4',
          cols:'60'
        }) + RML.input({
          type:'button',
          id:'btn-send-message',
          name:'btn-send-message',
          value:'Send Message',
        }) + RML.input({
          type:'button',
          id:'btn-clear-message',
          name:'btn-clear-message',
          value:'Clear Message',
        }) + RML.input({
          type:'button',
          id:'btn-logout',
          name:'btn-logout',
          value:'Log Out',
        })
      })
    });
    return $header;
    } //end header
  }

I’m using it here in a larger object literal method which can be called with a refinement like so:

HTML rendered by the RML methods
The rendered HTML

Get the code at github or here on the RML page. I’ll post more later this week…