Skip to content

Instantly share code, notes, and snippets.

View edheltzel's full-sized avatar
🇺🇸
Just your average run-of-the-mill kinda guy

Mr. ED edheltzel

🇺🇸
Just your average run-of-the-mill kinda guy
View GitHub Profile
@edheltzel
edheltzel / customize-wp-tinymce.php
Created October 22, 2012 23:55 — forked from arod2634/customize-wp-tinymce.php
Customize Wordpress TinyMCE Editor
<?php
// Make TinyMCE editor awesome!
function make_mce_awesome( $init ) {
$init['theme_advanced_blockformats'] = 'h2,h3,h4,p';
$init['theme_advanced_buttons1_add'] = 'copy, cut, paste, redo, undo';
$init['theme_advanced_buttons2_add'] = 'anchor, hr, sub, sup';
$init['theme_advanced_disable'] = 'wp_help';
return $init;
}
@edheltzel
edheltzel / custom-wp-toolbar.php
Created October 12, 2012 15:32 — forked from arod2634/custom-wp-toolbar.php
Wordpress: Customize Admin Toolbar
<?php
// Customize Admin toolbar if you do desiced to keep it around...
function change_toolbar($wp_toolbar) {
$wp_toolbar->remove_node('comments');
$wp_toolbar->add_node(array(
'id' => 'myhelp',
'title' => 'Help',
'meta' => array('target' => 'help')
));
$wp_toolbar->add_node(array(
@edheltzel
edheltzel / gist:3872419
Created October 11, 2012 13:48 — forked from danielbachhuber/gist:1106704
Wordpress: Admin Improvements
<?php
/**
* Random set of improvements
*/
/**
* Tidy up the admin and remove options we don't need
*/
function db_clean_up_admin() {
@edheltzel
edheltzel / custom-wp-dashboard.php
Created October 11, 2012 13:44 — forked from arod2634/custom-wp-dashboard.php
Wordpress: Customize Admin Dashboard
<?php
//Add a custom admin dashboard welcome widget
function custom_dashboard_widget() {
echo '<h1>Welcome to your new WordPress site built by an awesome developer</h1>';
}
function add_custom_dashboard_widget() {
wp_add_dashboard_widget('custom_dashboard_widget', 'Integrity Welcomes You To WordPress!', 'custom_dashboard_widget');
}
add_action('wp_dashboard_setup', 'add_custom_dashboard_widget');
@edheltzel
edheltzel / gist:3806042
Created September 30, 2012 06:29
CSS: Image Replacement
.ir {
border:0;
font: 0/0 a;
text-shadow: none;
color: transparent;
background-color: transparent;
}
@edheltzel
edheltzel / gist:3163217
Created July 23, 2012 11:47 — forked from padolsey/gist:527683
JS: detect IE
// ----------------------------------------------------------
// A short snippet for detecting versions of IE in JavaScript
// without resorting to user-agent sniffing
// ----------------------------------------------------------
// If you're not in IE (or IE version is less than 5) then:
// ie === undefined
// If you're in IE (>=5) then you can determine which version:
// ie === 7; // IE7
// Thus, to detect IE:
// if (ie) {}