Skip to content

Instantly share code, notes, and snippets.

Micah asuh

Block or report user

Report or block asuh

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View index.html
<!DOCTYPE html>
<html>
<head>
<title>My Page</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="http://code.jquery.com/mobile/1.1.1/jquery.mobile-1.1.1.min.css" />
<script src="//code.jquery.com/jquery-1.7.1.min.js"></script>
<script src="http://code.jquery.com/mobile/1.1.1/jquery.mobile-1.1.1.min.js"></script>
</head>
<body>
@asuh
asuh / gist:3956362
Created Oct 26, 2012
jQuery - hide from IE8
View gist:3956362
if (!$.browser.msie || $.browser.version !== "8.0") {
// Hidden from IE8
}
View frontend.php
// .content contains content
<div class="content"></div>
<script>
$(document).ready(function() {
// ajax to fetch the slider data.
$.ajax({
type: 'POST',
url: '<?php echo admin_url("admin-ajax.php"); ?>',
data: { action: "front_page_slider" },
@asuh
asuh / templating.js
Last active Dec 10, 2016
JS templating system
View templating.js
'use strict';
/*
* Javascript templating system
*/
$(document).ready(function() {
function loadTemplate(element, path, callback, done) {
$.ajax(path).then(function(html) {
element.append(html);
if (typeof callback === 'function' ) {
@asuh
asuh / package.json
Last active Sep 30, 2017
NPM only, no Grunt, Gulp, Broccoli or Brunch
View package.json
{
"name": "_s",
"version": "1.0.1",
"scripts": {
"clean": "rimraf style.css",
"notify": "notify -h",
"serve": "browser-sync start --proxy 'my.asuh' --files '**/*.css, **/*.js, *.php, **/*.json, dist/images/*'",
"imagemin": "imagemin src/images/* -o dist/images",
"icons": "svgo -f src/images/icons -o dist/images/icons && svg-sprite-generate -d dist/images/icons -o dist/images/icons/sprite.svg",
"lint-scss": "stylelint 'sass/**/*.scss' --syntax scss --config node_modules/stylelint-config-wordpress/scss.js",
View keybase.md

Keybase proof

I hereby claim:

  • I am asuh on github.
  • I am asuh (https://keybase.io/asuh) on keybase.
  • I have a public key ASA5GySldrdOvSxhRE_sFiMC-3aayiBOE3cHASzXvr0Kwwo

To claim this, I am signing this object:

@asuh
asuh / boxstarter.ps1
Last active Oct 30, 2018 — forked from jessfraz/boxstarter.ps1
Boxstarter Commands for a new Windows box.
View boxstarter.ps1
# Description: Boxstarter Script
# Author: Jess Frazelle <jess@linux.com>
# Last Updated: 2017-09-11
#
# Install boxstarter:
# . { iwr -useb http://boxstarter.org/bootstrapper.ps1 } | iex; get-boxstarter -Force
#
# You might need to set: Set-ExecutionPolicy RemoteSigned
#
# Run this boxstarter by calling the following from an **elevated** command-prompt:
@asuh
asuh / Preferences.sublime-settings
Last active Apr 16, 2019
Sublime Text 3 User Preferences sublime-settings file
View Preferences.sublime-settings
{
"always_show_minimap_viewport": true,
// Using ⌘-P, these files will never be shown in results
"binary_file_patterns":
[
"*.ai",
"*.dds",
"*.eot",
"*.gif",
"*.ico",
@asuh
asuh / comments.php
Created May 27, 2018
Walker_Comment overwrite for WordPress
View comments.php
<?php
class comments_reloaded extends \Walker_Comment {
var $tree_type = 'comment';
var $db_fields = array(
'parent' => 'comment_parent',
'id' => 'comment_ID'
);
// start_lvl – Wrapper for child comments list, starts the list before the elements are added.
@asuh
asuh / filter-wc-orders-by-gateway.php
Created Jul 21, 2019 — forked from bekarice/filter-wc-orders-by-gateway.php
Filters WooCommerce Orders by Payment Gateway Used
View filter-wc-orders-by-gateway.php
<?php
/**
* Plugin Name: Filter WooCommerce Orders by Payment Method
* Plugin URI: http://skyverge.com/
* Description: Filters WooCommerce orders by the payment method used :)
* Author: SkyVerge
* Author URI: http://www.skyverge.com/
* Version: 1.0.0
* Text Domain: wc-filter-orders-by-payment
*
You can’t perform that action at this time.