This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function remove_dashboard_widgets() { | |
global $wp_meta_boxes; | |
unset($wp_meta_boxes['dashboard']['side']['core']['dashboard_quick_press']); | |
unset($wp_meta_boxes['dashboard']['normal']['core']['dashboard_incoming_links']); | |
unset($wp_meta_boxes['dashboard']['normal']['core']['dashboard_right_now']); | |
unset($wp_meta_boxes['dashboard']['normal']['core']['dashboard_plugins']); | |
unset($wp_meta_boxes['dashboard']['normal']['core']['dashboard_recent_drafts']); | |
unset($wp_meta_boxes['dashboard']['normal']['core']['dashboard_recent_comments']); | |
unset($wp_meta_boxes['dashboard']['side']['core']['dashboard_primary']); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$args = array( | |
'numberposts' => -1, // Using -1 loads all posts | |
'orderby' => 'menu_order', // This ensures images are in the order set in the page media manager | |
'order'=> 'ASC', | |
'post_mime_type' => 'image', // Make sure it doesn't pull other resources, like videos | |
'post_parent' => $post->ID, // Important part - ensures the associated images are loaded | |
'post_status' => null, | |
'post_type' => 'attachment' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
wp-config.php | |
wp-content/uploads/ | |
wp-content/blogs.dir/ | |
wp-content/upgrade/ | |
wp-content/backup-db/ | |
wp-content/advanced-cache.php | |
wp-content/wp-cache-config.php | |
sitemap.xml | |
*.log | |
wp-content/cache/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
jQuery(document).ready(function($) { | |
$('a[href*=".jpg"], a[href*=".jpeg"], a[href*=".png"], a[href*=".gif"]').each(function(){ | |
//single image popup | |
if ($(this).parents('.gallery').length == 0) { | |
$(this).magnificPopup({type:'image'}); | |
} | |
}); | |
//gallery popup | |
$('.gallery').each(function() { | |
$(this).magnificPopup({ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Requre a specific version in this file: | |
# gem 'zurb-foundation', '=4.3.1' | |
require 'zurb-foundation' | |
# Require any additional compass plugins here. | |
# IE 9 and below only support up to 4095 CSS selectors | |
# This class will split all selectors after that point | |
class CssSplitter | |
def self.split(infile, outdir = File.dirname(infile), max_selectors = 4095) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
global $wp_query; | |
query_posts( | |
array_merge( | |
$wp_query->query, | |
array( | |
'order' => 'ASC', | |
'orderby'=>'title', | |
'posts_per_page' => 20, | |
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function todo_restrict_manage_posts() { | |
global $typenow; | |
$args=array( 'public' => true, '_builtin' => false ); | |
$post_types = get_post_types($args); | |
if ( in_array($typenow, $post_types) ) { | |
$filters = get_object_taxonomies($typenow); | |
foreach ($filters as $tax_slug) { | |
$tax_obj = get_taxonomy($tax_slug); | |
wp_dropdown_categories(array( | |
'show_option_all' => __('Show All '.$tax_obj->label ), |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function MODULE_update_7200() { | |
if( module_exists('MODULE')) { | |
module_disable(array('MODULE')); | |
drupal_uninstall_modules(array('MODULE')); | |
} | |
} |
OlderNewer