Skip to content

Instantly share code, notes, and snippets.

View yojance's full-sized avatar
🏠
Working from home

Yojance Rabelo yojance

🏠
Working from home
View GitHub Profile
@yojance
yojance / gist:c795437c1d40169002e0
Created July 20, 2014 01:48
OptionTree Custom Post Type Select Option Type
// OptionTree Custom Post Type Select Option Type
// Example code when being used as a Metabox or
// Exported OptionTree file to be used in Theme Mode
array(
'id' => 'spyr_demo_custom_post_type_select',
'label' => __( 'Custom Post Type Select', 'text-domain' ),
'desc' => __( 'Your description', 'text-domain' ),
'type' => 'custom-post-type-select',
@yojance
yojance / gist:3d7ce4f884049df279ec
Created July 20, 2014 01:49
OptionTree Category Select Option Type
// OptionTree Category Select Option Type
// Example code when being used as a Metabox or
// Exported OptionTree file to be used in Theme Mode
array(
'id' => 'spyr_demo_category_select',
'label' => __( 'Category Select', 'text-domain' ),
'desc' => __( 'Your description', 'text-domain' ),
'type' => 'category-select',
@yojance
yojance / gist:7ff579c054dd15a0aead
Created July 20, 2014 01:49
OptionTree Tag Select Option Type
// OptionTree Tag Select Option Type
// Example code when being used as a Metabox or
// Exported OptionTree file to be used in Theme Mode
array(
'id' => 'spyr_demo_tag_select',
'label' => __( 'Tag Select', 'text-domain' ),
'desc' => __( 'Your description', 'text-domain' ),
'type' => 'tag-select',
@yojance
yojance / gist:744bcc8047b2311a32c4
Created July 20, 2014 01:50
OptionTree Taxonomy Select Option Type
// OptionTree Taxonomy Select Option Type
// Example code when being used as a Metabox or
// Exported OptionTree file to be used in Theme Mode
array(
'id' => 'spyr_demo_taxonomy_select',
'label' => __( 'Taxonomy Select', 'text-domain' ),
'desc' => __( 'Your description', 'text-domain' ),
'type' => 'taxonomy-select',
@yojance
yojance / gist:857675b29387eb9bc7c3
Created July 20, 2014 01:50
OptionTree Sidebar Select Option Type
// OptionTree Sidebar Select Option Type
// Example code when being used as a Metabox or
// Exported OptionTree file to be used in Theme Mode
// This option type will read all of your available
// Sidebars on your theme, so there is very little work to do here
array(
'id' => 'spyr_demo_sidebar_select',
'label' => __( 'Sidebar Select', 'text-domain' ),
'desc' => __( 'Your description', 'text-domain' ),
jQuery(document).ready(function() {
// Start positioning the #header-ext div
wcs_position_header_ext();
});
jQuery( window ).resize( function() {
wcs_position_header_ext();
});
@yojance
yojance / gist:cec1418a2ed50c641adc
Created July 30, 2014 12:45
OptionTree Date Picker Option Type
array(
'id' => 'spyr_demo_date_picker',
'label' => __( 'Date Picker', 'text-domain' ),
'desc' => __( 'Your description', 'text-domain' ),
'type' => 'date-picker',
'section' => 'your_section',
)
// Get the value saved on Theme Options Page
$spyr_demo_date_picker = ot_get_option( 'spyr_demo_date_picker' );
@yojance
yojance / gist:dc86eeacf1064fe3f8ea
Created July 30, 2014 12:46
OptionTree Date Time Picker Option Type
// OptionTree Date Time Picker Option Type
// Example code when being used as a Metabox or
// Exported OptionTree file to be used in Theme Mode
array(
'id' => 'spyr_demo_date_time_picker',
'label' => __( 'Date Time Picker', 'text-domain' ),
'desc' => __( 'Your description', 'text-domain' ),
'std' => '',
@yojance
yojance / gist:11e8d92861f8ca12b0db
Created July 30, 2014 12:47
OptionTree Measurement Option Type
// OptionTree Measurement Option Type
// Example code when being used as a Metabox or
// Exported OptionTree file to be used in Theme Mode
array(
'id' => 'spyr_demo_measurement',
'label' => __( 'Measurement', 'text-domain' ),
'desc' => __( 'Your description', 'text-domain' ),
'type' => 'measurement',
@yojance
yojance / gist:f47a2425723013113e4a
Created July 30, 2014 12:49
OptionTree Numeric Slider Option Type
// OptionTree Numeric Slider Option Type
// Example code when being used as a Metabox or
// Exported OptionTree file to be used in Theme Mode
array(
'id' => 'spyr_demo_numeric_slider',
'label' => __( 'Numeric Slider', 'text-domain' ),
'desc' => __( 'Your description', 'text-domain' ),
'type' => 'numeric-slider',