Last active
February 10, 2019 04:07
-
-
Save shuuji3/74dcb4b3cbb5b1d65d380c53441505d4 to your computer and use it in GitHub Desktop.
「HPCS Lab. SS Team リソース一覧」の「書籍」シートのための情報をCalilのページから簡単にコピーするためのブックマークレット
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// 動作確認: Google Chrome 73.0.3683.27(Official Build)beta (64 ビット) | |
var authors = [...$('[itemprop="author"]')].map(a => a.textContent.trim()).join(' / ').replace(/\s+/g, ' '); var title = $('.book_title').text().trim(); var pubdate = $('[itemprop="datePublished"]').text().replace(/[()]/g, '').trim(); var publisher = $('[itemprop="publisher"]').text().trim(); var isbn = [...$('[href*="isbn"]')][0].href.split('=')[1]; var text = [authors, title, publisher, pubdate, isbn].join('\t'); alert(text); console.log(text) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment