    $(document).ready(function() {
        var cls = 'placeholded';
        
        $('input[alt]').each(function () {
            $(this).bind('focus', function() {
                var o = $(this);
                o.removeClass(cls);
                
                if (o.val() == o.attr('alt')) {
                    o.val('');
                }
            }).bind('blur', function() {
                var o = $(this);
                    
                if (o.val() == '' || o.val() == o.attr('alt')) {
                    o.val(o.attr('alt')).addClass(cls);
                }
            }).addClass(cls).val($(this).attr('alt'));
        });
        
        $('#menu td').each(function() {
            var
                id      = this.id.substr(5, this.id.length - 5),
                link    = $(this).children('.submenu'),
                this_td = id,
                submenu = $('#m' + id);

            if (submenu.size() > 0) {
                $(this).popup({
                    popupObject : submenu,
                    mouseoverCb : function() {
                        $('#menu_' + this_td).attr('class', 'bg');
                        $(link).show();
                    },
                    mouseoutCb  : function() {
                        $('#menu_' + this_td).attr('class', 'nbg');
                        $(link).hide();
                    }
                });
            }
        });
    });
    
    $(function() {
        $("#online-block a[rel]").overlay({expose: '#000', effect: 'apple'});
    });
