'); //openModal($J('#'+rId+'_marcview'), 'MARC for record # '+catKey, {width:500, maxHeight:700}, true); /***begin jqueryui dialog***/ $J(function() { $J(htmlOutput).dialog({ width:'97%', maxHeight:700, hide: { effect: "scale", duration: 750 }, title:'MARC for record # '+catKey, modal:true, buttons:{ Ok: function(){ $J(this).dialog("close"); } } }); }); setTimeout(function(){ $J('#marc_table_'+catKey).parent().css('background-color',"#fff"); $J('#marc_table_'+catKey).parent().addClass('floatingModal'); $J('#marc_table_'+catKey).siblings('.ui-dialog-titlebar').addClass('text-h2'); $J('#marc_table_'+catKey).siblings('.ui-dialog-buttonpane').find('.ui-dialog-buttonset').addClass('okButton'); $J('#marc_table_'+catKey).siblings('.ui-dialog-buttonpane').find('button').addClass('button fullwidth').removeClass('ui-button ui-corner-all ui-widget');$J('#marc_table_'+catKey).parent().css('top', "18%"); $J('#marc_table_'+catKey).css('max-height',"350px"); },100); /***end jQueryUI dialog****/ } else { /***begin jqueryui dialog***/ $J(function() { $J(htmlOutput).dialog({ width:500, maxHeight:700, hide: { effect: "scale", duration: 750 }, title:'MARC for record # '+catKey, modal:true, buttons:{ Ok: function(){ $J(this).dialog("close"); } } }); }); /***end jQueryUI dialog****/ } }, error: function (xhr, ajaxOptions, thrownError) { console.log('Error occurred of status ' + xhr.status + ', message is ' + thrownError); } });//end ajax() }//end getbibRoa function reload_jqueryui(rId){ jQuery.getScript( "/client/js/ui/jquery.ui.core.js", function( data, textStatus, jqxhr ) { getBibRoa(rId); }); } function modifyNewSearchIndex (rId) { var resultsId = rId.split("detail")[1]; jQuery('#detail_biblio'+resultsId).find('.displayElementText.SUBJECT_TERM a').each(function(){ var searchString = '&rt=false|||SUBJECT|||Subject'; var myHREF = jQuery(this).attr('href'); var newHREF = myHREF + searchString; jQuery(this).attr('href', newHREF); }); jQuery('#detail_biblio'+resultsId).find('.displayElementText.GEOGRAPHIC_TERM a').each(function(){ var searchString = '&rt=false|||SUBJECT|||Subject'; var myHREF = jQuery(this).attr('href'); var newHREF = myHREF + searchString; jQuery(this).attr('href', newHREF); }); jQuery('#detail_biblio'+resultsId).find('.displayElementText.CORPORATE_SUBJECT a').each(function(){ var searchString = '&rt=false|||SUBJECT|||Subject'; var myHREF = jQuery(this).attr('href'); var newHREF = myHREF + searchString; jQuery(this).attr('href', newHREF); }); jQuery('#detail_biblio'+resultsId).find('.displayElementText.CONFERENCE_SUBJECT a').each(function(){ var searchString = '&rt=false|||SUBJECT|||Subject'; var myHREF = jQuery(this).attr('href'); var newHREF = myHREF + searchString; jQuery(this).attr('href', newHREF); }); jQuery('#detail_biblio'+resultsId).find('.displayElementText.GENRE_TERM a').each(function(){ var searchString = '&rt=false|||GENRE_TERM|||Genre'; var myHREF = jQuery(this).attr('href'); var newHREF = myHREF + searchString; jQuery(this).attr('href', newHREF); }); jQuery('#detail_biblio'+resultsId).find('.displayElementText.PERSONAL_AUTHOR a').each(function(){ var searchString = '&rt=false|||AUTHOR|||Author'; var myHREF = jQuery(this).attr('href'); var newHREF = myHREF + searchString; jQuery(this).attr('href', newHREF); }); jQuery('#detail_biblio'+resultsId).find('.displayElementText.CORPORATE_AUTHOR a').each(function(){ var searchString = '&rt=false|||AUTHOR|||Author'; var myHREF = jQuery(this).attr('href'); var myHREF = jQuery(this).attr('href'); var newHREF = myHREF + searchString; jQuery(this).attr('href', newHREF); }); jQuery('#detail_biblio'+resultsId).find('.displayElementText.CONFERENCE_AUTHOR a').each(function(){ var searchString = '&rt=false|||AUTHOR|||Author'; var myHREF = jQuery(this).attr('href'); var myHREF = jQuery(this).attr('href'); var newHREF = myHREF + searchString; jQuery(this).attr('href', newHREF); }); jQuery('#detail_biblio'+resultsId).find('.displayElementText.ADDED_AUTHOR a').each(function(){ var searchString = '&rt=false|||AUTHOR|||Author'; var myHREF = jQuery(this).attr('href'); var myHREF = jQuery(this).attr('href'); var newHREF = myHREF + searchString; jQuery(this).attr('href', newHREF); }); jQuery('#detail_biblio'+resultsId).find('.displayElementText.ADDED_CONFERENCE_AUTHOR a').each(function(){ var searchString = '&rt=false|||AUTHOR|||Author'; var myHREF = jQuery(this).attr('href'); var myHREF = jQuery(this).attr('href'); var newHREF = myHREF + searchString; jQuery(this).attr('href', newHREF); }); jQuery('#detail_biblio'+resultsId).find('.displayElementText.ADDED_CORPORATE_AUTHOR a').each(function(){ var searchString = '&rt=false|||AUTHOR|||Author'; var myHREF = jQuery(this).attr('href'); var myHREF = jQuery(this).attr('href'); var newHREF = myHREF + searchString; jQuery(this).attr('href', newHREF); }); jQuery('#detail_biblio'+resultsId).find('.displayElementText.SERIES a').each(function(){ var searchString = '&rt=false|||SERIES|||Series'; var myHREF = jQuery(this).attr('href').split("+%3B")[0]; var myHREFArray = myHREF.split('qu='); var mySearchTerm = myHREFArray[1]; var mySearchVariable = myHREFArray[0]; var newHREF = mySearchVariable + 'qu="' + mySearchTerm + '"' + searchString; jQuery(this).attr('href', newHREF); }); jQuery('#detail_biblio'+resultsId).find('.displayElementText.SERIES_TITLE a').each(function(){ var searchString = '&rt=false|||SERIES_TITLE|||Series+Title'; var myHREF = jQuery(this).attr('href').split("+%3B")[0]; var myHREFArray = myHREF.split('qu='); var mySearchTerm = myHREFArray[1]; var mySearchVariable = myHREFArray[0]; var newHREF = mySearchVariable + 'qu="' + mySearchTerm + '"' + searchString; jQuery(this).attr('href', newHREF); }); } // End function function addGoodReadsButton (rId) { //original from Mount Prospect Library; but heavily altered from that //In case anyone asks, the same can be done for LibraryThing; the basic URL for that is: // https://www.librarything.com/search.php?searchtype=work&searchtype=work&sortchoice=0&search=9780596802448 //though LibraryThingForLibraries uses a slightly different URL. if (jQuery('#'+rId+'_FORMAT .FORMAT_value').length) { var thisFormat = jQuery('#'+rId+'_FORMAT .FORMAT_value:first-child').text(); if (thisFormat == "Books") { if (jQuery('#'+rId+'_ISBN .ISBN_value').length) { var thisISBN = jQuery('#'+rId+'_ISBN .ISBN_value:first-child').text(); var goodReadsButton = '