|
- <%!
- from flask import request
- %>\
- <%
- titleparts = []
- if query.page:
- titleparts.append(query.page.title)
- titleparts.append("Earwig's Copyvio Detector")
- title = " - ".join(titleparts)
- %>\
- <%include file="/includes/header.mako" args="title=title, splash=not result"/>
- <%namespace module="copyvios.misc" import="httpsfix"/>
- % if notice:
- <div id="notice-box" class="gray-box">
- ${notice}
- </div>
- % endif
- % if query.submitted:
- % if query.error:
- <div id="info-box" class="red-box"><p>
- % if query.error == "bad action":
- Unknown action: <b><span class="mono">${query.action | h}</span></b>.
- % elif query.error == "no search method":
- No copyvio search methods were selected. A check can only be made using the search engine, links present in the page, Turnitin, or some combination of these.
- % elif query.error == "bad oldid":
- The revision ID <code>${query.oldid | h}</code> is invalid. It should be an integer.
- % elif query.error == "no URL":
- Compare mode requires a URL to be entered. Enter one in the text box below, or choose copyvio search mode to look for content similar to the article elsewhere on the web.
- % elif query.error == "bad URI":
- Unsupported URI scheme: <a href="${query.bad_uri | h}">${query.bad_uri | h}</a>.
- % elif query.error == "no data":
- Couldn't find any text in <a href="${query.url | h}">${query.url | h}</a>. <i>Note:</i> only HTML documents, plain text pages, and PDFs are supported, and content generated by JavaScript or found inside iframes is ignored.
- % elif query.error == "timeout":
- The URL <a href="${query.url | h}">${query.url | h}</a> timed out before any data could be retrieved.
- % elif query.error == "search error":
- An error occurred while using the search engine (${query.exception}). <i>Note:</i> there is a daily limit on the number of search queries the tool is allowed to make. You may <a href="${request.url | httpsfix, h}&use_engine=0">repeat the check without using the search engine</a>.
- % else:
- An unknown error occurred.
- % endif
- </p></div>
- % elif not query.site:
- <div id="info-box" class="red-box">
- <p>The given site (project=<b><span class="mono">${query.project | h}</span></b>, language=<b><span class="mono">${query.lang | h}</span></b>) doesn't seem to exist. It may also be closed or private. <a href="https://${query.lang | h}.${query.project | h}.org/">Confirm its URL.</a></p>
- </div>
- % elif query.oldid and not result:
- <div id="info-box" class="red-box">
- <p>The revision ID couldn't be found: <a href="https://${query.site.domain | h}/w/index.php?oldid=${query.oldid | h}">${query.oldid | h}</a>.</p>
- </div>
- % elif query.title and not result:
- <div id="info-box" class="red-box">
- <p>The page couldn't be found: <a href="${query.page.url}">${query.page.title | h}</a>.</p>
- </div>
- % endif
- %endif
- <p>This tool attempts to detect <a href="https://en.wikipedia.org/wiki/WP:COPYVIO">copyright violations</a> in articles. In <i>search mode</i>, it will check for similar content elsewhere on the web using <a href="https://developers.google.com/custom-search/">Google</a>, external links present in the text of the page, or <a href="https://en.wikipedia.org/wiki/Wikipedia:Turnitin">Turnitin</a> (via <a href="https://en.wikipedia.org/wiki/User:EranBot">EranBot</a>), depending on which options are selected. In <i>compare mode</i>, the tool will compare the article to a specific webpage without making additional searches, like the <a href="https://dupdet.toolforge.org/">Duplication Detector</a>.</p>
- <p>Running a full check can take up to a minute if other websites are slow or if the tool is under heavy use. Please be patient. If you get a timeout, wait a moment and refresh the page.</p>
- <p>Be aware that other websites can copy from Wikipedia, so check the results carefully, especially for older or well-developed articles. Specific websites can be skipped by adding them to the <a href="https://en.wikipedia.org/wiki/User:EarwigBot/Copyvios/Exclusions">excluded URL list</a>.</p>
-
- <%include file="/includes/form.mako" args="query=query"/>
- % if result:
- <%include file="/includes/result.mako" args="query=query, result=result, turnitin_result=turnitin_result"/>
- % endif
- <%include file="/includes/footer.mako"/>
|