Skip to content

Instantly share code, notes, and snippets.

View nickhamze's full-sized avatar
:octocat:
Making Stuff

Nick Hamze nickhamze

:octocat:
Making Stuff
View GitHub Profile
body.iframe-hover .wpcc-cursor {
display: none;
}
.no-transition .cursor-el1,
.no-transition .cursor-el2 {
transition: none !important;
}
.no-cursor {
cursor: none;
}
@nickhamze
nickhamze / ef_help_menu.php
Created December 28, 2011 04:33
EF Contextual Help Menus
<?php
if ( !class_exists('EF_Settings') ) {
class EF_Settings {
var $module;
/**
* Register the module with Edit Flow but don't do anything else
@nickhamze
nickhamze / help.php
Created October 30, 2011 04:22
Updated Help for 3.3 for Social Bartender
<?php
// Show the new style contextual help if user is running WP 3.3
if( function_exists('add_option') ) {
function sh_sb_help_page() {
global $sh_sb_settings;
$current_screen = get_current_screen();
if ($current_screen->id != $sh_sb_settings)
return;
@nickhamze
nickhamze / help.php
Created October 30, 2011 03:53
Facebook Comment OTF 3.3 Menus
<?php
// Show the new style contextual help if user is running WP 3.3
if( function_exists('add_option') ) {
function sh_fbc_help_page() {
global $sh_fbc_settings;
$current_screen = get_current_screen();
if ($current_screen->id != $sh_fbc_settings)
return;
@nickhamze
nickhamze / Social Bartender Shortcode
Created September 11, 2011 21:32
Social Bartender Shortcode
function sh_sb_shortcode($atts, $content=null){
return social_bartender();
}
add_shortcode('socialbartender', 'sh_sb_shortcode');
@nickhamze
nickhamze / widget_with_checkbox
Created September 7, 2011 04:56
Widget for Social Bartender with Checkbox
<?php function sh_sb_widget_register_widgets() {
register_widget( 'sh_sb_widget' );
}
class sh_sb_widget extends WP_Widget {
function sh_sb_widget() {
$widget_ops = array(
'classname' => 'sh_sb_widget_class',
'description' => 'Display your Social Bartender links.'
@nickhamze
nickhamze / cpt_contextual_help_starter
Created September 6, 2011 13:01
CPT Contextual Help Starter File
function portfolioposttype_add_help_text($contextual_help, $screen_id, $screen) {
//$contextual_help .= var_dump($screen); // use this to help determine $screen->id
if ('portfolio' == $screen->id ) {
$contextual_help =
'<p>' . __('The title field and the big Post Editing Area are fixed in place, but you can reposition all the other boxes using drag and drop, and can minimize or expand them by clicking the title bar of each box. Use the Screen Options tab to unhide more boxes (Excerpt, Send Trackbacks, Custom Fields, Discussion, Slug, Author) or to choose a 1- or 2-column layout for this screen.') . '</p>' .
'<p>' . __('<strong>Title</strong> - Enter a title for your post. After you enter a title, you&#8217;ll see the permalink below, which you can edit.') . '</p>' .
'<p>' . __('<strong>Post editor</strong> - Enter the text for your post. There are two modes of editing: Visual and HTML. Choose the mode by clicking on the appropriate tab. Visual mode gives you a WYSIWYG editor. Click the last ico
@nickhamze
nickhamze / sb_widget
Created September 5, 2011 02:05
Widget for Social Bartender
function sb_widget_register_widgets() {
register_widget( 'sb_widget' );
}
class sb_widget extends WP_Widget {
function sb_widget() {
$widget_ops = array(
'classname' => 'sb_widget_class',
'description' => 'Display your Social Bartender links.'