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 | |
// Add the following to your theme's functions.php file | |
add_action( 'plugins_loaded', 'add_categories_to_cpt', 15 ); | |
function add_categories_to_cpt(){ | |
register_taxonomy_for_object_type( 'category', 'faq'); | |
// 'faq' can be changed to any registered post type | |
} |
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 | |
$cpt = new Arconix_CPT_Register(); | |
$cpt->add( 'books' ); | |
$tax = new Arconix_Taxonomy_Register(); | |
$tax->add( 'genres', 'books' ); |
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 // DO NOT include the opening php tag | |
// Replace 4.6.0 with whatever version you'd like | |
add_filter( 'arconix_fontawesome_version', '4.6.0' ); |
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 // DO NOT include the opening php tag | |
add_filter( 'arconix_shortcodes_list', 'add_gmap' ); | |
function add_gmap( $list ) { | |
$list[] = 'googlemap'; | |
return $list; | |
} |
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
[code]get_the_content()[/code] |
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 | |
/** | |
* Adds Post Tag support to a custom post type. | |
* | |
* This code is set to work with Arconix Portfolio, however | |
* the code should work with any of my plugins, simply | |
* change the 1st filter argument to match, i.e. | |
* 'arconix_testimonials_defaults' as I structure my | |
* defaults pretty much the same across all my plugins | |
*/ |
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 | |
// In your theme's functions.php file | |
// To add 1 post type to the exclude list | |
add_filter( 'arconix_flexslider_exclude_post_types', 'exclude_pt' ); | |
function exclude_pt( $post_types ) { | |
$post_types[] = 'post_type_name'; | |
return $post_types; |
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 | |
// In your theme's functions.php file | |
add_filter( 'arconix_flexslider_loop_args', 'thumbnail_meta' ); | |
function thumbnail_meta( $args ) { | |
$args['meta_key'] = "_thumbnail_id"; | |
return $args; | |
} |
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(){ | |
jQuery( "ul.arconix-portfolio-grid a.portfolio-image" ).attr( 'target', '_blank' ); | |
}); |
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 // DO NOT include the opening php tag | |
add_action( 'init', 'arconix_post_type_supports' ); | |
function arconix_post_type_supports() { | |
add_post_type_support( 'portfolio', 'comments' ); | |
} |
NewerOlder