function smartTextField(id) {
	$('#' + id).focus(function() {
		if($(this).val() == this.defaultValue) {
			$(this).val('');
		}
	});
	$('#' + id).blur(function() {
		if($.trim($(this).val()) == '') {
			$(this).val(this.defaultValue);
		}
	});
}

function smartPasswordField(id) {
	$('#' + id).focus(function() {
		this.type = 'password';
		if($(this).val() == this.defaultValue) {
			$(this).val('');
		}
	});
	$('#' + id).blur(function() {
		if($.trim($(this).val()) == '') {
			$(this).val(this.defaultValue);
			this.type = 'text';
		} else {
			this.type = 'password';
		}
	});
}