Skip to content

Instantly share code, notes, and snippets.

View Phunky's full-sized avatar

Mark Harwood Phunky

View GitHub Profile
@Phunky
Phunky / gist:b36c9c786c43de3ab2a5
Created May 14, 2015 16:56
Simple MySQLi wrapper idea... named after MariaDB as it would only be for MySQLi!
<?php
// Records
$Maria->user()->insert(['name'=>'Bobby']);
$Maria->user(1)->delete();
$Maria->user(1)->read();
$Maria->user(1)->update('name', 'bobby');
@Phunky
Phunky / SassMeister-input-HTML.html
Created May 11, 2015 15:05
Generated by SassMeister.com.
<div class="color">
<div class="___blue-grey_light4"></div>
<div class="___blue-grey_light3"></div>
<div class="___blue-grey_light2"></div>
<div class="___blue-grey_light1"></div>
<div class="___blue-grey"></div>
<div class="___blue-grey_dark1"></div>
<div class="___blue-grey_dark2"></div>
<div class="___blue-grey_dark3"></div>
<div class="___blue-grey_dark4"></div>
@Phunky
Phunky / gist:0a3de8d986a7b9b72fd3
Created April 16, 2015 15:43
base16-ocean.dark.tmTheme
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>author</key>
<string>Chris Kempson (http://chriskempson.com)</string>
<key>name</key>
<string>Base16 Ocean Dark</string>
<key>semanticClass</key>
<string>base16.ocean.dark</string>
@Phunky
Phunky / gist:34e3944d4b9304622bcb
Created January 27, 2015 15:51
AutoHotKey config for OSX Keyboard on Windows and Linux. As in proper 1:1 keyboard mappings for those used to British OSX keyboard layout
#z::Run www.autohotkey.com
; Swap CMD and CTRL around
LWin::Ctrl
; Select start
^Left::
Send, {Home}
return
@Phunky
Phunky / 0_reuse_code.js
Last active August 29, 2015 14:11
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
@Phunky
Phunky / SassMeister-input-HTML.html
Last active August 29, 2015 14:11
Generated by SassMeister.com.
Make a mixin instead of nesting
@Phunky
Phunky / index.php
Created November 21, 2014 15:56
Don't judge the code... it suppose to be crap, this is just a very simple front controller I tend to use for quick mockups or playing with composer packages.
<?php
define('ROOT_DIR', __DIR__ . '/../');
define('VENDOR_DIR', ROOT_DIR. 'vendor/');
define('PUBLIC_DIR', ROOT_DIR . 'public/');
define('ROUTES_DIR', ROOT_DIR . 'routes/');
define('VIEW_DIR', ROOT_DIR . 'views/');
define('CACHE_DIR', ROOT_DIR . 'cache/');
// Include libs
require( VENDOR_DIR . 'autoloader.php' );
@Phunky
Phunky / vhost.conf
Created September 29, 2014 16:02
Simple vhost for any .dev site in apache and with xip.io, obviously you need to point the domain to local host (dnsmasq is simplest way!)
#
# Any .dev folder in ~/Sites
#
<VirtualHost *:80>
VirtualDocumentRoot "/Users/phunky/Sites/%1.0.dev/public"
UseCanonicalName Off
ServerAlias %1.0.dev.*.xip.io
<Directory "/Users/phunky/Sites">
Options FollowSymLinks
@Phunky
Phunky / SassMeister-input-HTML.html
Last active August 29, 2015 14:05
Generated by SassMeister.com.
<div class="cta-btn blue">Button</div>
<div class="cta-btn green">Button</div>
<div class="cta-btn red">Button</div>
@Phunky
Phunky / SassMeister-input-HTML.html
Created August 20, 2014 10:52
Generated by SassMeister.com.
<div class="fg">
<div class="fg-full">
Full
</div>
<div class="fg-half">
Half
</div>
<div class="fg-half">