User:T12/scripts/copySectionLink.js: Difference between revisions
< User:T12
Jump to navigation
Jump to search
(++) |
m (Abhidevananda moved page User:Tito Dutta/scripts/copySectionLink.js to User:T12/scripts/copySectionLink.js: Automatically moved page while renaming the user "Tito Dutta" to "T12") |
(No difference)
|
Latest revision as of 11:37, 6 November 2022
$(document).ready(function() {
var i=0;
$('span.mw-headline').each(function() {
var $pilcrowlink = $('<a>¶</a>').attr({
id: 'sectiontitlecopy'+i,
href: '/wiki/'+mw.config.get('wgPageName')+'#'+$(this).attr('id'),
style: 'display:none;'
});
$(this).append(' ',$pilcrowlink);
$(this).parent().attr({
onMouseOver: '$("#sectiontitlecopy'+i+'").attr("style","display:inline")',
onMouseOut: '$("#sectiontitlecopy'+i+'").attr("style","display:none")'
});
i++;
});
});