function inputTextKeyword(id, defaultText) {
    var obj = $(id);
    if (obj.value == defaultText) {
        obj.style.color = "#aaa";
    } else {
        obj.style.color = '#000';
    }
    Event.observe(window, 'load', function() {
        var val = obj.value;
        if (val == null || val == '') {
            obj.style.color = '#aaa';
            obj.value = defaultText;
        }
        Event.observe(obj, 'focus', function() {
            if (obj.value == defaultText) {
                obj.style.color = '#000';
                obj.value = '';
            }
        });
        Event.observe(obj, 'blur', function() {
            if (obj.value == '') {
                obj.style.color = '#aaa';
                obj.value = defaultText;
            }
        });
        var form = obj;
        while (true) {
            form = form.parentNode;
            if (form.tagName.toLowerCase() == 'form') {
                break;
            }
        }
        Event.observe(form, 'submit', function() {
            if (obj.value == defaultText) {
                obj.value = '';
            }
        });
    });
}