Certainly possible, tho it can, of course, be dangerous to follow a link simply on the basis of its label text, without checking its underlying href.
If you were going to do that, on safe pages that you know well, you could:
- use a (Safari or Chrome) 'Execute Javascript in ...' action to harvest links which match an xpath expression
- capture the resulting line(s) in a KM variable
- Use an 'Open URL' action (embedded in a foreach in case of multiple lines)
The Javascript (this version to capture a single link) might look something like this:
(function (strPath) {
var r = document.evaluate(strPath, document, null, 0, null),
lst = [],
oNode;
while (oNode = r.iterateNext()) {
lst.push(oNode.href);
}
return lst[0];
})("//a[text()='" + document.kmvar.linkText + "']")
