Skip to content

Instantly share code, notes, and snippets.

View jsieber's full-sized avatar

John Sieber jsieber

  • BlueLine Development
  • Missoula, Montana
View GitHub Profile
@mattlevine
mattlevine / OAuth2.md
Last active January 27, 2020 19:08
OAuth2 cheat sheet
@stevewithington
stevewithington / config.xml.cfm
Last active July 21, 2021 21:41
Mura Module With HTML Editor Example
<mura name="My Module" contenttypes="*" iconclass="mi-rebel" />
@jsieber
jsieber / muraRebuildImageCache.cfm
Created September 11, 2018 20:42 — forked from stevewithington/muraRebuildImageCache.cfm
Mura CMS: Rebuild image cache or re-save images on redefined image sizes
<!--- Force Image Resave for All Images --->
<cfset application.serviceFactory.getBean('fileManager').rebuildImageCache(siteid='YOURSITEID')>
<!--- or to just reset a specific image size you can use --->
<cfset application.serviceFactory.getBean('fileManager').rebuildImageCache(siteid='YOURSITEID' ,size='YOURSIZE')>
@mizterp
mizterp / mysql_iso_country.sql
Last active April 3, 2020 18:09
MySQL Country table (data source: iso.org)
CREATE TABLE IF NOT EXISTS `country` (
`iso2` char(2) NOT NULL,
`name` varchar(45) NOT NULL,
`iso3` char(3) NOT NULL,
`numeric` smallint(3) UNSIGNED NOT NULL,
PRIMARY KEY (`iso2`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
INSERT INTO `country` (`iso2`, `name`, `iso3`, `numeric`) VALUES
('AF', 'Afghanistan', 'AFG', 4),
@stevewithington
stevewithington / mura-ckeditor-image-options.js
Created November 20, 2017 19:01
Mura CMS: CKEditor has 2 image plugins, and you can easily use either of them on a theme-by-theme basis.
/*
There are two (2) image plugins available for CKEditor:
The "Image" plugin (https://ckeditor.com/cke4/addon/image), which is used by default;
and the "Enhanced Image" plugin (https://ckeditor.com/cke4/addon/image2), which offers the ability to caption images.
To enable the "Enhanced Image" plugin, follow these instructions:
1. Edit the file located under {ThemeName}/js/editor/config.js.cfm
(if the file doesn't exist, create it ... if the config.js.cfm.txt file exists, rename it to remove '.txt')

DOCKER FIRST (Webinar)

7.1 was designed with a Docker first work flow in mind.

Docker allows increased support for Continuous Deployment and Testing, Multi-Cloud Platforms, Environment Standardization and Version Control. As well as better Isolation and Security (stolen from https://dzone.com/articles/5-key-benefits-docker-ci)

@scottdomes
scottdomes / app.css
Created September 18, 2017 21:35
React Audio Tutorial
body {
background: #f9f9f9;
font-family: 'Open Sans', sans-serif;
text-align: center;
}
#container {
position: relative;
z-index: 2;
padding-top: 100px;
anonymous
anonymous / trycf-gist.cfm
Created April 27, 2017 14:11
TryCF Gist
<p>Using closures, it is possible to create an "object-like" struct with cfml and not using any components. It allows you to do encapsulation, have methods, do chaining, etc. It's api is pretty much identical to an object, except that you use a function to create it (instead of new). ACF10+ and Lucee 4.5+</p>
<cfscript>
//this version encapsulates the value, you cannot update it from the outside
function make (required numeric input) {
var value = input;
var o = {
add: function (required numeric input) {
value += input;
@stevewithington
stevewithington / mura-js-form.js
Last active April 27, 2018 19:09
Mura CMS: How to manipulate the DOM of a form in Mura CMS v7+
<script>
Mura.DisplayObject.Form.reopen({
onAfterRender: function() {
//this.context.targetEl is a pointer to the dom element that contains the rendered Mura form.
var container = Mura(this.context.targetEl);
console.log(this.context.targetEl);
}
@stevewithington
stevewithington / primary-nav-with-images.cfm
Last active April 27, 2018 19:10
Mura CMS: Custom primary navigation with primary associated images as links.
<!--- Mura 6.2 Syntax (will work in 7.0 as well) --->
<cfset it = $.getBean('feed').addParam(relationship='AND', field='parentid', condition='EQ', criteria='00000000000000000000000000000000001').getIterator() />
<!--- Mura 7.0 Syntax --->
<!--- <cfset it = $.getBean('feed').where().prop('parentid').isEQ('00000000000000000000000000000000001').getIterator() /> --->
<cfif it.hasNext()>
<ul>
<cfloop condition="it.hasNext()">
<cfset item = it.next() />
<li>
<a href="#item.getURL()#">