Skip to content

Instantly share code, notes, and snippets.

View Sinetheta's full-sized avatar

Kevin Attfield Sinetheta

View GitHub Profile
# Numerous always-ignore extensions
*.diff
*.err
*.orig
*.log
*.rej
*.swo
*.swp
*.vi
*~
<?php
function themename_customize_register($wp_customize){
$wp_customize->add_section('themename_color_scheme', array(
'title' => __('Color Scheme', 'themename'),
'priority' => 120,
));
// =============================
@Sinetheta
Sinetheta / log.js
Created November 15, 2012 22:32 — forked from cowboy/log.js
JavaScript: (madness?).log()
/*
* (madness?).log()
*
* Copyright (c) 2012 Kevin Attfield
* Licensed under the MIT license.
*/
Object.prototype.log = function(){
console.log(this.valueOf());
return this;
@Sinetheta
Sinetheta / utils.js
Created March 12, 2012 16:03
JS: Good Javascript prototypes to have!
// ++ Array Remove - By John Resig (MIT Licensed)
//----------------------------------------------
Array.prototype.remove = function(from, to) {
var rest = this.slice((to || from) + 1 || this.length);
this.length = from < 0 ? this.length + from : from;
return this.push.apply(this, rest);
};
// ++ Trim spaces
//----------------------------------------------