Skip to content

Instantly share code, notes, and snippets.

View drrobotnik's full-sized avatar

Brandon drrobotnik

  • ThermoFisher Scientific
  • San Diego
View GitHub Profile
/**
* Theme Specific WP Rollback
*
* @description: Adds a rollback option to themes
* @copyright: http://opensource.org/licenses/gpl-2.0.php GNU Public License
*/
jQuery.noConflict();
{
"name": "bobcatenergy",
"private": true,
"dependencies": {
"bootstrap-sass-official": "~3.3.1",
"modernizr": "~2.8.1",
"fontawesome": "~4.3.0",
"matchHeight": "~0.5.2",
"jasny-bootstrap": "~3.1.3",
"smooth-scroll": "https://github.com/cferdinandi/smooth-scroll.git",
<?php
/*
|--------------------------------------------------------------------------
| Application Routes
|--------------------------------------------------------------------------
|
| Here is where you can register all of the routes for an application.
| It's a breeze. Simply tell Laravel the URIs it should respond to
| and give it the controller to call when that URI is requested.
$app->get('/', function() use ( $app ) {
$request = Request::all();
$ip = $request->getClientIp();
@drrobotnik
drrobotnik / gist:b463c2d388dc3116559f
Created April 15, 2015 17:03
potential structure
::: layout file structure :::
acf/
layouts/
carousel-products/
layout.json
layout-carousel-products.php
css/
slick.min.css
style.css
class autoloader {
public static $loader;
public static function init()
{
if (self::$loader == NULL)
self::$loader = new self();
return self::$loader;
if ( function_exists('cv_slack_{$command}') ) {
// Call the foobar() function with 2 arguments
$value = call_user_func_array("cv_slack_{$command}", array($text) );
}
die();
@drrobotnik
drrobotnik / _global.scss
Created January 5, 2015 19:00
foundation wut
meta.foundation-version {
font-family: "/5.5.0/";
}
meta.foundation-mq-small {
font-family: "/" + unquote($small-up) + "/";
width: lower-bound($small-range);
}
meta.foundation-mq-small-only {
@drrobotnik
drrobotnik / gist:5caaadae484c899bf094
Created December 16, 2014 23:14
filter html attributes
$attributes = array(
'id' => 'section-' . cv_get_section(),
'class' => $classes . ' carousel text-center',
'data-ratio' => get_sub_field( 'ratio' ),
'data-mobile-ratio' => get_sub_field( 'ratio_mobile' )
);
function cv_get_attrs( $attributes = array() ) {
$attributes = array_filter($attributes);
foreach( $attributes as $key => $value ) {
<?php
/*
Plugin Name: Caava
Plugin URI: http://www.caavadesign.com/
Description: Moo
Version: 0.0.1
Author: Brandon Lavigne
*/
add_action( 'plugin_autoloader', 'Caava\Common' );