Last active
April 11, 2017 04:33
-
-
Save r-k-b/9675b4e353f59e968d1986bc6f7ac2a0 to your computer and use it in GitHub Desktop.
No Alerts When Changing Page Templates
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ==UserScript== | |
// @name No Alerts When Changing Page Templates | |
// @namespace https://gist.github.com/r-k-b | |
// @version 1.1.0 | |
// @description No Alerts When Changing Page Templates | |
// @author Robert K. Bell <robert.k.bell@gmail.com> | |
// @homepage https://gist.github.com/r-k-b/9675b4e353f59e968d1986bc6f7ac2a0 | |
// @downloadURL https://gist.github.com/r-k-b/9675b4e353f59e968d1986bc6f7ac2a0/raw/no-alerts-when-changing-bc-page-templates.user.js | |
// @match https://*.worldsecuresystems.com/Admin/WebPages_Detail.aspx?PageID=* | |
// @grant none | |
// @run-at document-idle | |
// ==/UserScript== | |
/* jshint esnext: true */ | |
(function() { | |
'use strict'; | |
console.info('replacing annoying page template CSS prompt...'); | |
window.ReloadCSS = function(val) { | |
// do also if choosing no template so we clear classes | |
// var c = confirm('You have changed the template. Would you like to update the list of CSS classes available in the WYSIWYG editor?'); | |
// if (c) __doPostBack("ctl00_cp_dropdownTemplate",""); | |
window.updateTemplatePreviewUrl(); | |
}; | |
console.info('replaced.'); | |
})(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment