Skip to content

Instantly share code, notes, and snippets.

View richtabor's full-sized avatar

Rich Tabor richtabor

View GitHub Profile
<li><?php the_terms($post->ID, 'portfolio_tag', '', ', ', ''); ?></li>
<li class="port-pagination">
<span class="page-previous">
<?php previous_post_link('%link', __('Prev', 'bean')); ?>
</span><!-- END .page-previous -->
<span class="page-next">
<?php next_post_link('%link', __(' / Next', 'bean')); ?>
</span><!-- END .page-next -->
</li><!-- END .port-pagination -->
#media-container li.stacked-image {
text-align: center;
}
#media-container li.stacked-image {
width: auto!important;
}
.single-portfolio .slides li img {
width: auto!important;
$args = array(
'post_type'=> 'portfolio',
'orderby'=> 'menu_order',
'order'=> 'ASC',
'paged'=> $paged,
'posts_per_page'=> $portfolio_posts_count,
);
<?php $args = array(
'orderby' => 'date',
'order' => 'DSC',
'posts_per_page'=> 3,
'meta_key' => '_thumbnail_id',
'tax_query' => array( //DO NOT ALLOW IMAGE POST FORMATS
array(
'taxonomy' => 'post_format',
'field' => 'slug',
'terms' => 'post-format-image',
Simply add buttons, icon buttons, alerts, tabs, toggle, highlights and more – all with a nice shortcode generator in our next WordPress plugin for theme shortcodes.
<h6>Buttons</h6>
The <a href="http://themebeans.com/plugin/bean-shortcodes-plugin">Bean Shortcodes Plugin</a> has a powerful button shortcode generator, which lets you choose what size (small, medium, or large) color, type (rounded, squared) and even an icon selection.
[button url="#" color="purple" size="small"]Button[/button]
[button url="#" color="green" size="small"]Button[/button]
[button url="#" color="blue" size="small"]Button[/button]
[button url="#" color="red" size="small"]Button[/button]
[button url="#" color="orange" size="small"]Button[/button]
<?php if( !is_page_template('page-portfolio-slider.php') && get_theme_mod( 'hello_bar' ) == true) {
get_template_part( 'content', 'hellobar' );
} //END if( get_theme_mod( 'hello_bar' ) == true) ?>
<?php the_content( __( '<span>Read More</span>', 'bean' ) ); ?>
@richtabor
richtabor / Macho Filter Blank Spaces Fix
Created April 29, 2014 17:18
Fix for adding "-" in lieu of spaces for categories with multiple words
<li class="isotope-item filter <?php if ( $terms && !is_wp_error( $terms ) ) { foreach ( $terms as $term ) { $cat = strtolower($term->name);$id = preg_replace('/[^a-zA-Z]+/', '-', $cat);echo $id; echo ' ';} } ?>">
@richtabor
richtabor / CSS @font-face template
Created May 6, 2014 16:03
Just a quick css guide of hooking in your custom loaded fonts. Simply add a fonts folder with your font files into the theme's assets folder.
@font-face {
font-family: 'FullerSansDTBold';
src: url('assets/fonts/fullersansdt-bold-webfont.eot');
src: url('assets/fonts/fullersansdt-bold-webfont.eot?#iefix') format('embedded-opentype'),
url('assets/fonts/fullersansdt-bold-webfont.woff') format('woff'),
url('assets/fonts/fullersansdt-bold-webfont.ttf') format('truetype'),
url('assets/fonts/fullersansdt-bold-webfont.svg#FullerSansDTBold') format('svg');
font-weight: normal;
font-style: normal;
}