Skip to content

Instantly share code, notes, and snippets.

View howardpanton's full-sized avatar

Howard Panton howardpanton

View GitHub Profile
@howardpanton
howardpanton / gist:2084309
Created March 18, 2012 23:08 — forked from luetkemj/wp-query-ref.php
WP: Query $args
<?php
/**
* WordPress Query Comprehensive Reference
* Compiled by luetkemj - luetkemj.com
*
* CODEX: http://codex.wordpress.org/Class_Reference/WP_Query
* Source: http://core.trac.wordpress.org/browser/tags/3.3.1/wp-includes/query.php
*/
$args = array(
@howardpanton
howardpanton / gist:2991093
Created June 25, 2012 20:42 — forked from thehydroimpulse/gist:2872907
A Laravel task generator. Models, Migrations and Controllers.
<?php
/**
* @copyright 2012 TheHydroImpulse, Daniel Fagnan
* @version 0.1
* @todo Add an overwite ability. Among other things.
* @note Use this as you wish. Extend it, Mash it. Enjoy it.
*/
@howardpanton
howardpanton / README.md
Created December 1, 2012 21:03 — forked from necolas/README.md
Experimenting with component-based HTML/CSS naming and patterns

Template Components

Used to provide structural templates.

Pattern

t-template-name
t-template-name--modifier-name
t-template-name__subcomponent-name--subcomponent-modifier-name
.clearfix:before,
.clearfix:after {
content: " ";
display: table;
}
.clearfix:after {
clear: both;
}
var gulp
= require('gulp'),
gutil = require('gulp-util'),
gutils = require('gulp-load-utils')(['date']);
sass = require('gulp-sass'),
csso = require('gulp-csso'),
uglify = require('gulp-uglify'),
jade = require('gulp-jade'),
concat = require('gulp-concat'),
livereload = require('gulp-livereload'), // Livereload plugin needed: https://chrome.google.com/webstore/detail/livereload/

Adding HipChat support to applications

Simple instruction that show you how to add HipChat support for your app so that it will post to a room of your choice, preferably one for the application in question. Both require an API token which you can get from Niklas. v2 of the HipChat API lets you use your own tokens, but I couldn't get that working intially.

Travis

You can optionally use secure tokens in your travis.yml file. It requires you to install the travis command line tool:

$ gem install travis

<head>
<!--[Font include]
/**
* @license
* MyFonts Webfont Build ID 2886433, 2014-09-19T11:53:00-0400
*
* The fonts listed in this notice are subject to the End User License
* Agreement(s) entered into by the website owner. All other parties are
* explicitly restricted from using the Licensed Webfonts(s).
*
@howardpanton
howardpanton / Fix Cygwin Issue with RubyGem
Created October 8, 2015 13:19 — forked from devcfgc/Fix Cygwin Issue with RubyGem
No such file or directory — /cygdrive/c/Ruby/bin/gem (LoadError)
//We must add the following to your .bashrc (C:\cygwin\home\user\.bashrc):
alias ruby='/cygdrive/c/Ruby21-x64/bin/ruby'
alias gem='/cygdrive/c/Ruby21-x64/bin/gem.bat'
alias irb='/cygdrive/c/Ruby21-x64/bin/irb.bat'
alias compass='/cygdrive/c/Ruby21-x64/bin/compass.bat'
alias sass='/cygdrive/c/Ruby21-x64/bin/sass.bat'
alias scss='/cygdrive/c/Ruby21-x64/bin/scss.bat'
@howardpanton
howardpanton / hapijs-rest-api-tutorial.md
Created July 28, 2016 13:31 — forked from agendor/hapijs-rest-api-tutorial.md
A practical introduction to building a RESTful API with the hapi.js server framework for Node.js
@howardpanton
howardpanton / sanitizehtml.pipe.ts
Created April 17, 2018 11:10 — forked from schmidt1024/sanitizehtml.pipe.ts
angular 4 pipe for bypass security trust html
// <div [innerHTML]="your.value | sanitizeHtml" ></div>
import { Pipe, PipeTransform } from '@angular/core';
import { DomSanitizer, SafeHtml } from '@angular/platform-browser';
@Pipe({name: 'sanitizeHtml'})
export class SanitizeHtmlPipe implements PipeTransform {
constructor(private _sanitizer:DomSanitizer) {
}
transform(v:string):SafeHtml {