Skip to content

Instantly share code, notes, and snippets.

View rwatts3's full-sized avatar
💭
Engineering Stuff

Ryan Watts rwatts3

💭
Engineering Stuff
View GitHub Profile
# Also refer to https://gist.github.com/stevewithington/5060602 if you wish to allow for mixed siteIDs in URLs
# Apache mod_rewrite Docs: http://httpd.apache.org/docs/current/rewrite/
# Intro: http://httpd.apache.org/docs/current/rewrite/intro.html
# Flags: http://httpd.apache.org/docs/current/rewrite/flags.html
Options All -Indexes
Options +FollowSymLinks
# -------------------------------------------------------------------------------
# MURA REWRITE OPTIONS
@rwatts3
rwatts3 / muraImportUsersViaCSV.cfm
Created October 27, 2015 07:29 — forked from stevewithington/muraImportUsersViaCSV.cfm
Example of how to import Users into Mura CMS via .CSV file. Also see https://gist.github.com/stevewithington/4742829 to import content from an RSS Feed.
<cfscript>
param name='form.csvUrl' default='#getPageContext().getRequest().getScheme()#://#cgi.server_name##getDirectoryFromPath(getPageContext().getRequest().getRequestURI())#users.csv';
param name='form.group' default='Temp';
param name='form.isSubmitted' default='false';
param name='form.isTest' default='true';
param name='form.siteid' default='default';
$ = application.serviceFactory.getBean('$').init(form.siteid);
if ( !$.currentUser().isSuperUser() && !$.currentUser().isInGroup('admin') ) {
@rwatts3
rwatts3 / muraImportContentFromRSS.cfm
Created October 27, 2015 07:29 — forked from stevewithington/muraImportContentFromRSS.cfm
Mura CMS: Example of how to import content into Mura CMS from an RSS feed. Place the file under your Mura root. For example: http://yourdomain.com/temp/import/index.cfm. Also see https://gist.github.com/stevewithington/5051646 to importUsersViaCSV
<cfscript>
param name='form.rssurl' default='';
param name='form.parentfilename' default='blog';
param name='form.isSubmitted' default='false';
param name='form.istest' default='true';
param name='form.siteid' default='default';
$ = application.serviceFactory.getBean('$').init(form.siteid);
if ( !$.currentUser().isSuperUser() && !$.currentUser().isInGroup('admin') ) {
@rwatts3
rwatts3 / mura-node.cfm
Created October 28, 2015 07:34 — forked from ronnieduke/mura-node.cfm
Create a new Mura content node
<cfscript>
// Load a new content Bean
bean=$.getBean('content');
//Set the parent node of where you want the new node to live
bean.setParentID('some id');
bean.setTitle('Some Title');
//Should this go live immediately? 0=no 1=yes
@rwatts3
rwatts3 / submit_form.html
Created October 30, 2015 07:14 — forked from jeremyhodges/submit_form.html
Using Dropzone.JS to upload via orion.filesystem with drag and drop support.
<template name="submit_form">
<div class="alert alert-success" style="display: none;" role="alert">
<strong>Your work has been submitted!</strong> You successfully submitted your work. It is now in-review.
</div>
<div class="well">
{{# with job }}
<h3 class="text-info job-name" data-job-id="{{ _id }}">{{ name }}</h3>
@rwatts3
rwatts3 / readme.md
Created June 10, 2016 22:57 — forked from philipz/readme.md
Send file over SSH

cat docker-compose.yml | docker-machine ssh mhs-demo0 "cat - &gt; docker-compose.yml"

@rwatts3
rwatts3 / Dockerfile
Created June 29, 2016 03:17 — forked from Maxim-Filimonov/Dockerfile
Docker meteor example files
# User for local dev
FROM app/base
RUN npm install -g orion-cli
# This forces package-catalog update. Should speed up further runs
RUN meteor show meteor-platform
@rwatts3
rwatts3 / ajaxData.cfc
Created September 12, 2016 21:38 — forked from stevewithington/ajaxData.cfc
Mura CMS : jQuery Ajax example. Sometimes, you'll need to access a file via Ajax in Mura. Some key things to keep in mind are 1) You cannot directly access a .cfm file located under a SiteID unless a) it resides in a directory called 'remote' [as of v6.1], or b) You edit the file located under /{SiteID}/includes/Application.cfc on approximately …
<cfscript>
// Save this file to a path such as /{SiteID}/includes/themes/{ThemeName}/remote/ajaxData.cfc
component {
remote string function getData(siteid='default', contentid='00000000000000000000000000000000001') returnformat='plain' {
var str = '';
var $ = get$(arguments.siteid, arguments.contentid);
savecontent variable='str' {
WriteOutput("<h1>Hello from ajaxData.cfc</h1>
@rwatts3
rwatts3 / webstorm.cmd
Created April 3, 2017 19:31 — forked from mac2000/webstorm.cmd
Open with WebStorm context menu
@ECHO OFF
REM Remove registry if any
REG DELETE "HKEY_CLASSES_ROOT\Directory\shell\WebStorm" /f
REM Get WebStorm executable path
FOR /F "usebackq tokens=3*" %%A IN (`REG QUERY "HKEY_CLASSES_ROOT\Applications\WebStorm.exe\shell\open\command"`) DO (
SET WEBSTORM=%%A %%B
)
@rwatts3
rwatts3 / intellij.bat
Last active April 4, 2023 07:53 — forked from amnuts/phpstorm.bat
Add context menu to Windows 7 to open file/folder in Intellij Idea
@echo off
SET IntellijPath=C:\Program Files\JetBrains\IntelliJ IDEA 173.2463.16\bin\idea64.exe
echo Adding file entries
@reg add "HKEY_CLASSES_ROOT\*\shell\Open in Intellij" /t REG_SZ /v "" /d "Open in Intellij" /f
@reg add "HKEY_CLASSES_ROOT\*\shell\Open in Intellij" /t REG_EXPAND_SZ /v "Icon" /d "%IntellijPath%,0" /f
@reg add "HKEY_CLASSES_ROOT\*\shell\Open in Intellij\command" /t REG_SZ /v "" /d "%IntellijPath% \"%%1\"" /f
echo Adding folder entries