
/**
*   This file is intended to control all scripting that is run from uBuilder pages.
*   The function runScripts() should call all all other scripts.
**/


function runScripts() {

    //from affiliates.js: functions to set the affiliate cookie
    //and update the product page with the affiliate ID
    handleAffiliateVisit();
    handleAffiliateCheckout();

}

var libraryWin
function libraryPopup(libraryurl,width,height){
    if (libraryWin && !libraryWin.closed) {
        libraryWin.close();
    }

    //add spacing so that libraryitem is shown without scrolling
    newWidth = width + 40;
    newHeight = height + 40;

    libraryWin = window.open( libraryurl, "libraryView","width=" + newWidth + ",height=" + newHeight + ",scrollbars=1");
}
