{ "translatorID": "fa396dd4-7d04-4f99-95e1-93d6f355441d", "label": "CiteSeer", "creator": "Sebastian Karcher", "target": "^https?://citeseerx?\\.ist\\.psu\\.edu", "minVersion": "3.0", "maxVersion": "", "priority": 100, "inRepository": true, "translatorType": 4, "browserSupport": "gcsibv", "lastUpdated": "2014-04-24 02:37:16" } /* ***** BEGIN LICENSE BLOCK ***** Copyright © 2012 Sebastian Karcher This file is part of Zotero. Zotero is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. Zotero is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more details. You should have received a copy of the GNU Affero General Public License along with Zotero. If not, see . ***** END LICENSE BLOCK ***** */ function detectWeb(doc, url) { if (url.indexOf('/search?q') != -1 && getSearchResults(doc).length) { return "multiple"; } if (url.indexOf('/viewdoc/') != -1 && doc.getElementById('bibtex')) { return "journalArticle"; } } function getSearchResults(doc) { return ZU.xpath(doc, '//div[@class="result"]/h3/a'); } function doWeb(doc, url) { var articles = new Array(); if (detectWeb(doc, url) == "multiple") { var items = {}; var titles = getSearchResults(doc); for (var i=0; i