User:Opencooper/domainRedirect.js: Difference between revisions

Content deleted Content added
Undid revision 871781725 by Opencooper (talk)
add another case
Line 49:
function getInfobox() {
var infoboxUrl;
 
// Get {{Url|}}
infoboxUrl = $(".infobox .url a").last().attr("href");
if (infoboxUrl) {
console.log("domainRedirect.js: Found Url via {{Url}} in infobox: " + infoboxUrl);
getRedirects(infoboxUrl);
return;
}
 
// Get |website=
$(".infobox tr").each(function() {
if ($(this).children("th").text() == "Website") {
Line 57 ⟶ 67:
if (infoboxUrl) {
console.log("domainRedirect.js: Found Url via website= in infobox: " + infoboxUrl);
getRedirects(infoboxUrl);
} else {