Index: other-projects/hathitrust/wcsa/vol-checker/WebContent/HT-HTRC_Mashup.user.js
===================================================================
--- other-projects/hathitrust/wcsa/vol-checker/WebContent/HT-HTRC_Mashup.user.js	(revision 31330)
+++ other-projects/hathitrust/wcsa/vol-checker/WebContent/HT-HTRC_Mashup.user.js	(revision 31331)
@@ -17,4 +17,6 @@
 // grant GM_addStyle
 
+var http_servlet_url="http://bedrock.resnet.cms.waikato.ac.nz:8686/vol-checker/";
+var https_servlet_url="https://bedrock.resnet.cms.waikato.ac.nz:8643/vol-checker/";
 
 function mashupInit() {
@@ -27,5 +29,5 @@
     $search_button.find('span').first().hide();
 
-    $fieldset.append('<button id="htrc-bw" class="button search" style="width:47px; right: -105px; background-image:url(http://www.cs.waikato.ac.nz/~davidb/htrc-mashup/bookworm.png);" title="Bookworm"></button>');
+    $fieldset.append('<button id="htrc-bw" class="button search" style="width:47px; right: -105px; background-image:url('+https_servlet_url + 'bookworm.png);" title="Bookworm"></button>');
 
     var $bw_button = $('#htrc-bw');
@@ -148,56 +150,42 @@
 	//console.log("*** ids_str = " + ids_str);
 
-	console.log("**** Away to request: " + "http://bedrock.resnet.cms.waikato.ac.nz:8686/vol-checker/VolumeCheck?ids=" + encodeURIComponent(ids_str));
+	console.log("**** Away to request: " + https_servlet_url + "VolumeCheck?ids=" + encodeURIComponent(ids_str));
 
+	var encoded_ids=encodeURIComponent(ids_str);
+	var full_url = https_servlet_url + "VolumeCheck?ids=" + encoded_ids;
 
+	$.ajax(full_url)
+	    .done(function(data,textStatus,response) {
+		console.log("Adding in HTRC cross-checks");
+		var ids_exist = data;
+		for (var k in ids_exist) {
+		    //console.log("*** k = '" + k + "'");
 
+		    //var id_str = '#htrc-mashup-'+k;
+		    //console.log("*** id str = " + id_str);
+		    // var $id_div = $(id_str);
+		    
+		    //var $id_div = $('#'+'htrc-mashup-'+k);
+		    var id_div = document.getElementById('htrc-mashup-'+k);
+		    //console.log("*** id_div = " + id_div);
+		    var $id_div = $(id_div);
 
-	GM_xmlhttpRequest ({
-	            method: "GET",
-	            url: "http://bedrock.resnet.cms.waikato.ac.nz:8686/vol-checker/VolumeCheck?ids=" + encodeURIComponent(ids_str),
-	            //url: "http://localhost:8080/htrc-ef-exists/VolumeCheck?ids=" + encodeURIComponent(file_safe_ids_str),
-	            //headers: {
-	        //"Content-Type": "application/x-www-form-urlencoded"
-	          //  },
-	            onload: function (response) {
+		    if (ids_exist[k]) {
+			$id_div.find("ul").append("<li title=\""+k+"\" style=\"color: #924a0b;\"><a>Download Extracted Features</a></li>"); // â
+		    }
+		    else {
+			// â, â
+			$id_div.find("ul").append("<li title=\""+k+"\" style=\"color: red;\">HTRC unfriendly â</li>");
+		    }
 
-			    console.log("Adding in HTRC cross-checks");
-			    var text = response.responseText;
-			    //console.log ( "Response text: " + text);
-			    var ids_exist = JSON.parse(text);
+		    //console.log("*** id div len = " + $id_div.length);
 
-			    for (var k in ids_exist) {
-				    //console.log("*** k = '" + k + "'");
+		    //$.append("<li>HTRC friendly</li>");
+		}
+	    })
+	    .fail(function(esponse,textStatus,errorThrown) {
+		alert( "error:"  + errorThrown);
+	    });
 
-				    //var id_str = '#htrc-mashup-'+k;
-				    //console.log("*** id str = " + id_str);
-				    // var $id_div = $(id_str);
-
-				    //var $id_div = $('#'+'htrc-mashup-'+k);
-				    var id_div = document.getElementById('htrc-mashup-'+k);
-				    //console.log("*** id_div = " + id_div);
-				    var $id_div = $(id_div);
-
-				    if (ids_exist[k]) {
-					$id_div.find("ul").append("<li title=\""+k+"\" style=\"color: #924a0b;\"><a>Download Extracted Features</a></li>"); // â
-					    }
-				    else {
-					// â, â
-					$id_div.find("ul").append("<li title=\""+k+"\" style=\"color: red;\">HTRC unfriendly â</li>");
-					    }
-
-				    //console.log("*** id div len = " + $id_div.length);
-
-				    //$.append("<li>HTRC friendly</li>");
-				    /*
-				                if (ids_exist.hasOwnProperty(k)) {
-						  //console.log("*** processing id: " + k);
-						    //$('#htrc-mashup-'+k).css("background-color:","red");
-						      $('#htrc-mashup-'+k).append("<p>HTRC friendly</p>");
-						            }*/
-				}
-
-			        }
-	        });
 
 	//console.log("*** GM httpRequest made ");
Index: other-projects/hathitrust/wcsa/vol-checker/WebContent/WEB-INF/web.xml
===================================================================
--- other-projects/hathitrust/wcsa/vol-checker/WebContent/WEB-INF/web.xml	(revision 31330)
+++ other-projects/hathitrust/wcsa/vol-checker/WebContent/WEB-INF/web.xml	(revision 31331)
@@ -11,13 +11,35 @@
   </welcome-file-list>
   
+
+  <filter>
+    <filter-name>cross-origin</filter-name>
+    <filter-class>org.eclipse.jetty.servlets.CrossOriginFilter</filter-class>
+    <init-param>
+        <param-name>allowedOrigins</param-name>
+        <param-value>*</param-value>
+    </init-param>
+    <init-param>
+        <param-name>allowedMethods</param-name>
+        <param-value>GET,POST,HEAD</param-value>
+    </init-param>
+    <init-param>
+        <param-name>allowedHeaders</param-name>
+        <param-value>X-Requested-With,Content-Type,Accept,Origin</param-value>
+    </init-param>
+  </filter>
+  <filter-mapping>
+    <filter-name>cross-origin</filter-name>
+    <url-pattern>/*</url-pattern>
+  </filter-mapping>
+
+
   <servlet>
-		<servlet-name>HTRC Volume Check</servlet-name>
-		<servlet-class>org.hathitrust.extractedfeatures.VolumeCheck</servlet-class>
-	</servlet>
-
-	<servlet-mapping>
-		<servlet-name>HTRC Volume Check</servlet-name>
-		<url-pattern>/VolumeCheck</url-pattern>
-	</servlet-mapping>
+    <servlet-name>HTRC Volume Check</servlet-name>
+    <servlet-class>org.hathitrust.extractedfeatures.VolumeCheck</servlet-class>
+  </servlet>
+  <servlet-mapping>
+    <servlet-name>HTRC Volume Check</servlet-name>
+    <url-pattern>/VolumeCheck</url-pattern>
+  </servlet-mapping>
   
 	
