Posts tagged 〝webdevtrick〞

(page 11 of 12)

Cutting down on loop iterations with labels

April 28th, 2006 at 1:48 pm

Use break, continue and loop labels in JavaScript to exit nested loops early, cutting iterations when searching a JSON result set from nine to two.


Linking both text and icons with rollover state

March 2nd, 2006 at 10:55 pm

Make both a link's text and icon clickable in one link by using a CSS background image with padding, which also gives an easy rollover state.


Don’t rely on maxlength to shorten passwords

February 6th, 2006 at 6:47 pm

A demo shows JavaScript can set a field value longer than maxlength in IE and Opera, so always validate input length on the server too.


Styling submit buttons or using links to submit a form?

January 3rd, 2006 at 4:32 pm

Submit buttons, image inputs or text links? Pros and cons for accessibility and i18n, plus an unobtrusive script that swaps buttons for styled links.


How to remove the ugly border around an image in a link

December 14th, 2005 at 11:32 am

Why a linked image gets a coloured border and how to remove it: target the image with a img { border: none; } rather than styling the link itself.