Skip to content

Instantly share code, notes, and snippets.

@idenkov
idenkov / css_resources.md
Last active August 29, 2015 14:10 — forked from jookyboi/css_resources.md
CSS libraries and guides to bring some order to the chaos.

Libraries

  • 960 Grid System - An effort to streamline web development workflow by providing commonly used dimensions, based on a width of 960 pixels. There are two variants: 12 and 16 columns, which can be used separately or in tandem.
  • Compass - Open source CSS Authoring Framework.
  • Bootstrap - Sleek, intuitive, and powerful mobile first front-end framework for faster and easier web development.
  • Font Awesome - The iconic font designed for Bootstrap.
  • Zurb Foundation - Framework for writing responsive web sites.
  • SASS - CSS extension language which allows variables, mixins and rules nesting.
  • Skeleton - Boilerplate for responsive, mobile-friendly development.

Guides

@idenkov
idenkov / Pro Sites - level check
Created December 6, 2014 23:16
Displays some information depending on the level in Pro Sites
<?php
global $wpdb;
$blog_id = $wpdb->blogid;
$sql = "SELECT level FROM {$wpdb->base_prefix}pro_sites WHERE blog_ID = '$blog_id'";
$level = $wpdb->get_var( $sql );
?>
<?php if ( $level == 1 ) : ?>
@idenkov
idenkov / all-cat-drop.php
Last active August 29, 2015 14:11
Get a dropown list of all the category names.
<select name="event-dropdown" onchange='document.location.href=this.options[this.selectedIndex].value;'>
<option value=""><?php echo esc_attr(__('Select Category')); ?></option>
<?php
$option = '<option value="' . get_option('home') . '/category/">All Categories</option>';
// change category to your custom page slug
$categories = get_terms( 'category', array(
'orderby' => 'count',
'hide_empty' => 0,
) );