User:DannyS712 test/cv.js

// $(function { var Copy_vio_config = {	name: 'CV.js',	version: 1.2,	debug: true };

mw.loader.using( 'mediawiki.util', function {    $(document).ready( function  { var newDiff = mw.config.get( 'wgDiffNewId' ); var oldid = mw.util.getParamValue( 'oldid' ); var linkOldid; if ( newDiff ) { linkOldid = newDiff; } else if ( oldid ) { linkOldid = oldid; } else { linkOldid = mw.config.get( 'wgCurRevisionId' ); }   	var link = '//tools.wmflabs.org/copyvios/?lang=en&project=wikipedia&title=&oldid=' + linkOldid + '&action=search&use_engine=1&use_links=1&turnitin=0'; mw.util.addPortletLink ( 'p-cactions', link, 'CV', 'ca-copyVioLink', 'Assess copyrights'); } ); } ); }); //