var mydate = new Date();
var mydate = new Date(987654321987);
var mydate = new Date("Sat Mar 23 10:02:24 UTC 2002");
var mydate = new Date(2002, 0, 22, 9, 14, 30, 0);
var mthday = mydate.getDate();Universal Time:
var wkday = mydate.getDay();
var fyear = mydate.getFullYear();
var hours = mydate.getHours();
var msec = mydate.getMilliseconds();
var minutes = mydate.getMinutes();
var month = mydate.getMonth();
var seconds = mydate.getSeconds();
var mtime = mydate.getTime();
var year = mydate.getYear();
Older HTML tags and attributes that have been superseded by other more functional or flexible alternatives (whether as HTML or as CSS) are declared as deprecated in HTML4 by the W3C - the consortium that sets the HTML standards. Browsers should continue to support deprecated tags, but eventually these tags are likely to become obsolete and so future support cannot be guaranteed.
display property: Display can be set to block, inline, list-item or none and can be specified for any element. display:none; causes the element to be completely removed from the page AND the space it would otherwise occupy is closed up dynamically, using whatever content follows the hidden element, (excluding elements using absolute positioning). display:block; re-creates the space required and displays the element as normal. Use list-item to add a bullet in front of the element (as in ul li) or use inline to create a new inline (i.e. relative positioning) box on the same line as previous content.
If you create your graphics with a lot of different colour shades, you must bear in mind that not all visitors will be using monitors capable of such resolution. When the graphic is displayed by the browser, a certain amount of dithering occurs in an attempt to simulate the shade on the display. Two fixed colours are combined in a random dot pattern to create the illusion of the intended shade. This leads to grainy images and increases the final file size of any gif file. If you need lots of colour shades for an image, consider using a jpeg. Otherwise, try and maximise the areas of solid, uniform colour in your gif file and design your graphic in a low colour depth mode within your drawing software.
div tag: Along with <span>,
div was especially created as an HTML tag for use with style sheets. The div tag divides the content on screen using a line break above the <div> and below the </div> tag. <span> </span> tags are displayed without line breaks.
onUnload();are part of the window object rather than document.
document.alinkColor;Active link colour.
document.linkColor;Initial link colour.
document.vlinkColor;Visited link colour.
document.links;First link in this document. Provides access to each link sequentially, , , etc.
document.fgColor;Default text colour.
document.forms;array provides access to forms sequentially, most applications use a name for the form and
document.formname;but take care if you want to validate HTML4 pages using the
nameattribute in the
document.images;provides sequential access to images in the form (in order of the position of the
<img>tag, not the vertical position in the page).
document.title;Contents of the
document.url;Location of the document.
Drop capitals are popular in certain forms of presentations or newsletters. CSS2 makes this easy, just specify a class in your stylesheet and add a contextual pseudo-element selector. For a drop-cap effect, use a paragraph class that doesn't use a text-indent setting and use text-align:justify for best effect. The rest of the paragraph style can be copied from other paragraphs on the page. Now create a contextual selector for this new class using the first-letter pseudo-element and the float style:
Now each time you use
p class="drop", the
first-letter will be a drop-capital, the rest of the paragraph will flow around the drop-cap and other paragraphs are not affected. The important settings for effective drop-caps are font-weight, font-size, line-height, width and padding-right. Experiment with the values to get the effect you want. Note that even a change from
line-height:0.9em has a beneficial effect - too large and the drop-cap appears isolated from the paragraph, too small and you can get an overlap. Remember to test your styles in a variety of browsers to check you get what you expect - browsers still indulge in 'second-guessing' and try to compensate for almost-right code. The results of this guesswork are not entirely predictable!