Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Add hybrid_base_aside_infinity() to handle a permalink for aside post…

…s. This is a planned Hybrid Core 1.6 function.
  • Loading branch information...
commit 88e1cae4d7eba1f366486a0eead12a68281f089e 1 parent 137a2db
@justintadlock authored
Showing with 18 additions and 0 deletions.
  1. +18 −0 functions.php
View
18 functions.php
@@ -132,6 +132,7 @@ function hybrid_base_theme_setup() {
/** Hybrid Core 1.6 changes **/
add_filter( "{$prefix}_sidebar_defaults", 'hybrid_base_sidebar_defaults' );
add_filter( 'cleaner_gallery_defaults', 'hybrid_base_gallery_defaults' );
+ add_filter( 'the_content', 'hybrid_base_aside_infinity', 9 );
/****************************/
}
@@ -206,6 +207,23 @@ function hybrid_base_gallery_defaults( $defaults ) {
return $defaults;
}
+ /**
+ * Adds an infinity character "∞" to the end of the post content on 'aside' posts. This
+ * is from version 0.1.1 of the Post Format Tools extension.
+ *
+ * @since 0.1.0
+ * @access public
+ * @param string $content The post content.
+ * @return string $content
+ */
+ function hybrid_base_aside_infinity( $content ) {
+
+ if ( has_post_format( 'aside' ) && !is_singular() )
+ $content .= ' <a class="permalink" href="' . get_permalink() . '" title="' . the_title_attribute( array( 'echo' => false ) ) . '">&#8734;</a>';
+
+ return $content;
+ }
+
/* End Hybrid Core 1.6 section. */
?>
Please sign in to comment.
Something went wrong with that request. Please try again.