/**
 * Javascript defined here is called after all other scripts have been imported.  In particular, we load the Google CSE
 * scripts near the end of the document to prevent any delay in seeing the page content, so we need to define the
 * GSearch callback after these scripts have been imported.
 */
try {
    GSearch.setOnLoadCallback(function() {
        var cseOverlay = new CSEOverlay("013265782523816064955:8amckok_yow",
                                        document.getElementById("searchbox_013265782523816064955:8amckok_yow"),
                                        document.getElementById("results_013265782523816064955:8amckok_yow"));
        try {
            cseOverlay.searchControl.setLinkTarget(GSearch.LINK_TARGET_SELF);
        } catch (cse_error) {
        }
    });
    // we have GSearch (i.e. should have internet connectivity), so show the search box
    document.getElementById('search').style.display = 'block';
} catch (gsearch_err) {
    // GSearch wasn't defined
}
