function initPagePubs() {

    // Get a handle on the select element
    var select = document.getElementById("pubSelect");

    // Ensure that the 'LEMMA pubs' option is selected
    select.options[0].selected = true;

    // Set up the event handler
    addEventHandler(select, "change", changeSelect);
}

//==============================================================================

function changeSelect() {

    // Retrieve the tables in this page
    var tables = document.getElementsByTagName("table");
    for (var i=0; i<tables.length; i++) {
        var currentTable = tables[i];
        if (currentTable.className == "pubTable")
        {
            // Get the rows associated with this table
            var rows = currentTable.getElementsByTagName("tr");
            
            // Iterate over the rows, toggling those associated with 
            // non-LEMMA publications
            for (var j=0; j<rows.length; j++) {
                var currentRow = rows[j];
                if (currentRow.className != 'lemma') {
                    toggleRowClass(currentRow);
                }
            }
        }
    }
}

//==============================================================================

function toggleRowClass(me) {
    if (me.className == "other") {
        me.className = "other off";
    } else {
        me.className = "other";
    }
}

//==============================================================================
