use https for google, bing and archive.org
Merged pull from dessant on original author page: https://github.com/arantius/resurrect-pages/pull/21 and updated bing URIs as well.
Cette révision appartient à :
Parent
71ae348186
révision
26b63ae276
1 fichiers modifiés avec 5 ajouts et 5 suppressions
|
@ -151,18 +151,18 @@ var resurrect={
|
||||||
|
|
||||||
switch (mirror) {
|
switch (mirror) {
|
||||||
case 'google':
|
case 'google':
|
||||||
gotoUrl='http://webcache.googleusercontent.com/search?&q=cache:'+encUrl;
|
gotoUrl='https://webcache.googleusercontent.com/search?&q=cache:'+encUrl;
|
||||||
break;
|
break;
|
||||||
case 'googletext':
|
case 'googletext':
|
||||||
gotoUrl='http://webcache.googleusercontent.com/search?strip=1&q=cache::'+encUrl;
|
gotoUrl='https://webcache.googleusercontent.com/search?strip=1&q=cache::'+encUrl;
|
||||||
break;
|
break;
|
||||||
case 'archive':
|
case 'archive':
|
||||||
gotoUrl='http://wayback.archive.org/web/'+rawUrl;
|
gotoUrl='https://wayback.archive.org/web/'+rawUrl;
|
||||||
break;
|
break;
|
||||||
case 'bing':
|
case 'bing':
|
||||||
var xhr=new XMLHttpRequest();
|
var xhr=new XMLHttpRequest();
|
||||||
xhr.open('GET',
|
xhr.open('GET',
|
||||||
'http://api.search.live.net/xml.aspx'+
|
'https://api.bing.com/xml.aspx'+
|
||||||
'?AppId=FD382E93B5ABC456C5E34C238A906CAB1E6F9875'+
|
'?AppId=FD382E93B5ABC456C5E34C238A906CAB1E6F9875'+
|
||||||
'&Query=url:'+encUrl+
|
'&Query=url:'+encUrl+
|
||||||
'&Sources=web&Web.Count=1',
|
'&Sources=web&Web.Count=1',
|
||||||
|
@ -173,7 +173,7 @@ var resurrect={
|
||||||
var c=xhr.responseXML.getElementsByTagName('web:CacheUrl');
|
var c=xhr.responseXML.getElementsByTagName('web:CacheUrl');
|
||||||
gotoUrl=c[0].textContent;
|
gotoUrl=c[0].textContent;
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
gotoUrl='http://www.bing.com/search?q=url:'+encUrl;
|
gotoUrl='https://www.bing.com/search?q=url:'+encUrl;
|
||||||
}
|
}
|
||||||
|
|
||||||
break;
|
break;
|
||||||
|
|
Chargement…
Référencer dans un nouveau ticket