var current_active = cssQuery(".active")[0];
var mega_all = cssQuery(".mg-item");

function showme(e){
    if (current_active == this){
    }
    else {
        current_active.className = "mg-item";
        $("p", current_active).hide();
        current_active = this;
        this.className+=" active";
        $("p",this).fadeIn("slow");
    }
    return 0;
}

for (var i=0; i < mega_all.length; i++) {
    mega_all[i].onmouseover = showme;
}

mega_all[0].onmouseover(); // switch 0 to any number to change initial active item
