Mitch's Technical Blog

HTML Notes

November 22, 2018
html, notes
permalink

I'm not a "front end" developer. I like clean code. I get excited about beautiful algorithms and data structures. I like to make data whirl and dance with my expert SQL skills.

But, I am first and foremost a problem solver and solution builder whose medium is programming.

So I can't afford to gloss over the critical aspect of any user-facing application: the interface.

Many "real" programmers treat it as an afterthought or brag about their poor UI design skills, as if having good UI skills somehow makes them an inferior programmer.

Simpler is better. Not interested in complex javascript frameworks right now, because I'm not a "front end" developer.

Mini-essay over for now. What follows are my quick reference html notes. They help me look up what I have used in the past, but haven't yet memorized. My online memory.

HTML document structure

!DOCTYPE HTML
html
head
    title
body

MDN OptGroup

Drop-down lists (Select groups)

select
    optgroup label="grouplabel"
            option value="optionvalue"
            option selected="selected"

Jquery UI

    $( ".selector" ).datepicker({
      altField: "#actualDate"
    });
    // Getter
    var altField = $( ".selector" ).datepicker( "option", "altField" );

    // Setter
    $( ".selector" ).datepicker( "option", "altField", "#actualDate" );

    MIN DATE. Using 1 - 1 is an elegant concise reminder that month index is 0-based.
    $( ".selector" ).datepicker({
      minDate: new Date(2007, 1 - 1, 1)
    });

    MAX DATE.
    $( ".selector" ).datepicker({
      maxDate: "-1d"
    });

JQuery UI API Doc


Contact: hello at escapefromsql.net