Skip to content

Instantly share code, notes, and snippets.

View jlahijani's full-sized avatar

Jonathan Lahijani jlahijani

View GitHub Profile
@alexmercenary
alexmercenary / mystyles.js
Created September 2, 2017 10:24
Add UIKit text classes to CKEditor mystyles.js for ProcessWire
/**
* mystyles.js - for ProcessWire CKEditor "Custom Editor Styles Set" option
*
* Example file for "Custom Editor Styles Set" as seen in your CKEditor field config.
* This file is not in use unless you specify it for that configuration item.
*
* PLEASE NOTE:
*
* It's possible this file may be out of date since it is in /site/ rather than /wire/,
* and the version of this file will reflect whatever version you had when you first
@kentliau
kentliau / backup_script.js
Last active August 30, 2023 08:12
OneTab backup script
function backup() {
function downloadBlob(filename, blobUrl) {
var element = document.createElement('a');
element.setAttribute('href', blobUrl);
element.setAttribute('download', filename);
element.style.display = 'none';
document.body.appendChild(element);
element.click();
document.body.removeChild(element);
}
@Da-Fecto
Da-Fecto / bidirectional
Last active August 29, 2015 14:18
Bidirectional save & remove of products & groups (Fieltype pages)
<?php
/**
* Groups & Products references guard.
*
* Bidirectional save & remove of products & groups
*
* templates:
* - 'group', pagefield: page_products
* - 'product', pagefield: page_groups