Tuesday, December 9, 2014

HTML Attributes


Attributes provide information about content. Attributes are placed inside an opening HTML tag. All XHTML attributea are specified as follows: . HTML5 attributes usually take the same format, but may occassionally be single words (such as required for form elements or autoplay for media).
It is a good idea to always place attribute values (which can be numbers, letters, words or file paths) inside double quotes, as shown above. Single quotes may also be used. In HTML5, the quotes may be dropped entirely if the value is a series of characters or numbers without any special characters. This is not an advised practice until you are very experienced: you will occassionally see examples of this in code samples in articles here, in order to save space.
Previously we specified the word SAIT as being an abbreviation, but the tag we used did not say what SAIT was an abbreviation for. We will now use the title attribute to specify this.
I am a student at SAIT Polytechnic

No comments:

Post a Comment