Skip to content

Instantly share code, notes, and snippets.

@wpsmith
wpsmith / column-classes.css
Last active October 11, 2017 19:02
CSS: Genesis Column Classes including fifths
/* Column Classes
Link: Link: http://wpsmith.net/2013/wp/genesis-2-0-drops-fifths-from-column-classes/
Link: http://twitter.github.io/bootstrap/assets/css/bootstrap-responsive.css
--------------------------------------------- */
.five-sixths,
.four-sixths,
.four-fifths,
.one-fifth,
.one-fourth,
@toshimaru
toshimaru / jquery-scroll-bottom.js
Last active July 21, 2024 00:02
Detect the scrolling to bottom of the page using jQuery.
$(window).on("scroll", function() {
var scrollHeight = $(document).height();
var scrollPosition = $(window).height() + $(window).scrollTop();
if ((scrollHeight - scrollPosition) / scrollHeight === 0) {
// when scroll to bottom of the page
}
});
@rfmeier
rfmeier / functions.php
Last active December 18, 2015 01:48
Remove comment date link in comment meta within Genesis Framework
<?php
add_filter( 'genesis_comment_list_args', 'custom_genesis_comment_list_args' );
/**
* Callback for Genesis 'genesis_comment_list_args' filter.
*
* Override the comment callback and implement custom comment.
*
* @package Genesis
* @category comments
@nathanielks
nathanielks / add-to-sidebar.php
Created April 26, 2013 18:22
These functions will programmatically add widgets to a specified sidebar. This can be useful when a theme is first installed to fill specific sidebars with widgets you're written for your theme. $add_to_sidebar takes the id of the sidebar you wish to add to. $widgets takes the id's of the widgets you wish to add.
<?php
function cur_add_widget_to_sidebar( $widget_name, $add_to_sidebar, &$sidebar_options ){
$widget = get_option('widget_'.$widget_name);
if(!is_array($widget))$widget = array();
$count = count($widget)+1;
$sidebar_options[$add_to_sidebar][] = $widget_name.'-'.$count;
$widget[$count] = array();
update_option('widget_'.$widget_name,$widget);
@braddalton
braddalton / Remove Page Navigation Genesis
Last active October 14, 2020 13:58
Remove Pagination Genesis. This PHP code removes the page naviagtion from all archives Source http://wpsites.net/web-design/genesis-remove-page-navigation-pagination-from-any-archive-page/
remove_action( 'genesis_after_endwhile', 'genesis_posts_nav' );
@raelmax
raelmax / get_repos.sh
Created October 21, 2012 00:50
Get all repos from bitbucket account
curl -u ${1} https://api.bitbucket.org/1.0/users/${1} > repoinfo
for repo_name in `grep \"name\" repoinfo | cut -f4 -d\"`
do
repo="${repo_name}.git"
git clone [email protected]:${1}/$repo
done
@erikreagan
erikreagan / mac-apps.md
Created August 4, 2012 19:18
Mac developer must-haves

Mac web developer apps

This gist's comment stream is a collection of webdev apps for OS X. Feel free to add links to apps you like, just make sure you add some context to what it does — either from the creator's website or your own thoughts.

— Erik

@pitch-gist
pitch-gist / gist:2999707
Created June 26, 2012 22:21
HTML: Simple Maintenance Page
<!doctype html>
<title>Site Maintenance</title>
<style>
body { text-align: center; padding: 150px; }
h1 { font-size: 50px; }
body { font: 20px Helvetica, sans-serif; color: #333; }
article { display: block; text-align: left; width: 650px; margin: 0 auto; }
a { color: #dc8100; text-decoration: none; }
a:hover { color: #333; text-decoration: none; }
</style>
@Rarst
Rarst / r-debug.php
Last active March 27, 2025 16:58
R Debug (set of dump helpers for debug)
<?php
/*
Plugin Name: R Debug
Description: Set of dump helpers for debug.
Author: Andrey "Rarst" Savchenko
Author URI: https://www.rarst.net/
License: MIT
*/
@leek
leek / _Magento1_DeleteTestData.md
Last active December 29, 2023 09:51
Magento 1 - Delete All Test Data

These set of scripts are for Magento 1. For Magento 2, see this Gist.