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
<!--- Previous code which is not loading plugin icons properly in IE10 ---> | |
<script src="tiny_mce/tiny_mce.js" type="text/javascript"></script> | |
<!--- Added a random number as a querystring ---> | |
<script src="tiny_mce/tiny_mce.js?key=#randrange(1,1000)#" type="text/javascript"></script> |
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
jQuery(document).ready(function($) { | |
$.validator.setDefaults({ | |
errorClass: 'errorField', | |
errorElement: 'div', | |
errorPlacement: function(error, element) { | |
error.addClass("ui red pointing above ui label error").appendTo( element.closest('div.field') ); | |
}, | |
highlight: function(element, errorClass, validClass) { | |
$(element).closest("div.field").addClass("error").removeClass("success"); | |
}, |
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
<cfscript> | |
myxmldoc = XmlParse("#expandpath('.')#/toc.xml"); | |
if(listfirst(server.coldfusion.productversion) gte 10) | |
selectedElements = XmlSearch(myxmldoc, "//topic[ upper-case(@label) = '#ucase(url.q)#' ]"); | |
else | |
selectedElements = XmlSearch(myxmldoc, "//topic[ contains(translate(@label, 'ABCDEFGHIJKLMNOPQRSTUVWXYZ', 'abcdefghijklmnopqrstuvwxyz') ,'#lcase(url.q)#') ]/@href"); | |
</cfscript> | |
<cfif arrayLen(selectedElements) neq 0> | |
<cflocation url="#selectedElements[1].XmlAttributes.href#" addtoken="false"> |
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
import sublime, sublime_plugin, webbrowser | |
class LaunchCfHelpCommand(sublime_plugin.TextCommand): | |
def run(self, edit, forward = True): | |
word = "" | |
for s in self.view.sel(): | |
word = self.view.word( s ) | |
''' To use cfquickdocs | |
s = sublime.load_settings("CfQuickDocs.sublime-settings") |
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
<cfscript> | |
/* ColdFusion 11 dropped the undocumented cfusion_encrypt & decrypt functions while Railo 4.2 still officially supports it. | |
This script will reestablish the built-in function. You can also use fusion_encrypt/decrypt (without the "c"). | |
Based on 2005 blog post: http://www.barneyb.com/barneyblog/2005/10/28/cfusion_encryptcfusion_decrypt-udfs/ */ | |
function fusion_binaryXOR(n1, n2){ | |
n1 = formatBaseN(n1, 2); | |
n2 = formatBaseN(n2, 2); | |
return inputBaseN(replace(n1 + n2, 2, 0, "all"), 2); | |
} | |
function fusion_encrypt(string, key){ |
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
// Reference : https://portal.netfusion.ch/kb/a19/konfiguration-presidecms.aspx | |
component extends="preside.system.config.Config" output=false { | |
public void function configure() output=false { | |
super.configure(); | |
settings.preside_admin_path = "cmsadmin"; | |
settings.system_user = "sysadmin"; | |
settings.default_locale = "en"; |
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
<cfcomponent hint="Canada Post"> | |
<cffunction name="init" access="public"> | |
<cfargument name="apiKey" type="string" required="true" /> | |
<cfargument name="customerNumber" type="string" required="true" /> | |
<cfargument name="contractNumber" type="string" required="true" /> | |
<cfset variables.apiKey = arguments.apiKey> | |
<cfset variables.customerNumber = arguments.customerNumber> | |
<cfset variables.contractNumber = arguments.contractNumber> |
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
<cfscript> | |
clos = function( func ) { func(); }; | |
clos( function(){ | |
clos( function(){ | |
writeDump( foo ?: "I am null" ); | |
} ); | |
} ); | |
</cfscript> |
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
<cfcomponent output="no"> | |
<cfset variables.logFileName = "demoLogGateway" /> | |
<cfset variables.state="stopped" /> | |
<cffunction name="init" access="public" output="no" returntype="void"> | |
<cfargument name="id" required="false" type="string"> | |
<cfargument name="config" required="false" type="struct"> | |
<cfargument name="listener" required="false" type="component"> |
OlderNewer