fixes #2631 artist urls in related tags should have option to open in new window
This commit is contained in:
@@ -222,7 +222,21 @@
|
|||||||
$("<li/>").append($link)
|
$("<li/>").append($link)
|
||||||
);
|
);
|
||||||
} else {
|
} else {
|
||||||
$ul.append($("<li/>").text(tag[0]));
|
var text = tag[0];
|
||||||
|
if (text.match(/^ http/)) {
|
||||||
|
text = text.substring(1, 1000);
|
||||||
|
var $url = $("<a/>");
|
||||||
|
$url.text("open");
|
||||||
|
$url.attr("href", text);
|
||||||
|
$url.attr("target", "_blank");
|
||||||
|
var $li = $("<li/>");
|
||||||
|
$li.append(text + " [");
|
||||||
|
$li.append($url);
|
||||||
|
$li.append("]");
|
||||||
|
$ul.append($li);
|
||||||
|
} else {
|
||||||
|
$ul.append($("<li/>").text(text));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user