Beefy Boxes and Bandwidth Generously Provided by pair Networks
Just another Perl shrine
 
PerlMonks  

Checking Saint in our Book for ties

by chacham (Prior)
on Jul 20, 2015 at 16:08 UTC ( #1135457=monkdiscuss: print w/replies, xml ) Need Help??

eyepopslikeamosquito's planetscape and me: 1282 nodes apiece can be queried, or turned into a Greasemonkey script to run each time Saints in our Book loads:

// ==UserScript== // @name PerlMonks Saints in our Book Ties // @namespace http://www.example.com/chacham/ // @description Find ties in Saints in our Book, based on Writeups and + Experience // @include http://perlmonks.org/?node_id=3559 // @grant none // ==/UserScript== var table = document.getElementsByTagName('table')[4]; for (var i = 1; i < table.rows.length; i++) if ( (table.rows[i].cells[2].textContent == table.rows[i + 1].cells +[2].textContent) && (table.rows[i].cells[4].textContent == table.rows[i + 1].ce +lls[4].textContent) ) alert(table.rows[i].cells[0].textContent + ' ' + table.rows[i].cells[ +1].textContent + '\r\n' + table.rows[i + 1].cells[0].textContent + ' ' + table.rows[i ++ 1].cells[1].textContent);

Alternatively, it can be turned into a bookmarklet by enclosing it in javascript:(function(){})();, to execute on demand. That is, copy and paste the following as a new bookmark:

javascript:(function(){var table = document.getElementsByTagName('tabl +e')[4]; for (var i = 1; i < table.rows.length; i++) if ( (table.rows[i].cells[2].textContent == table.rows[i + 1].cells +[2].textContent) && (table.rows[i].cells[4].textContent == table.rows[i + 1].ce +lls[4].textContent) ) alert(table.rows[i].cells[0].textContent + ' ' + table.rows[i].cells[ +1].textContent + '\r\n' + table.rows[i + 1].cells[0].textContent + ' ' + table.rows[i ++ 1].cells[1].textContent);})();

To test it, as it stands at the time this is being posted, it should alert you to one set of duplicates.

Added on OpenUsersJS at PerlMonks Saints in our Book Ties

Replies are listed 'Best First'.
Re: Checking Saint in our Book for ties
by Pope-O-Matik (Pilgrim) on Jul 28, 2015 at 23:21 UTC

    What a book tie? And why are Saints wearing them? :)

      Those saints who are still pondering about their ties, perhaps this is of interest (ISTR via hacker news)

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: monkdiscuss [id://1135457]
Approved by Corion
help
Chatterbox?
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others cooling their heels in the Monastery: (2)
As of 2018-02-19 14:29 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    When it is dark outside I am happiest to see ...














    Results (265 votes). Check out past polls.

    Notices?