MediaWiki:Common.js: Difference between revisions

no edit summary
No edit summary
No edit summary
 
Line 1: Line 1:
/* Any JavaScript here will be loaded for all users on every page load. */
/* Any JavaScript here will be loaded for all users on every page load. */
// Insert TopMessage template at the beginning of content on all pages
$(document).ready(function() {
    if ($('#mw-content-text').length) {
        $('#mw-content-text').prepend('{{TopMessage}}');
    }
});
/* Top section styling */
.top-message {
    background-color: #fff8e1;
    border: 2px solid #ffeb3b;
    padding: 15px;
    text-align: center;
    font-size: 16px;
    margin-bottom: 20px;
}