reorg theme
This commit is contained in:
parent
9ddb9f3c60
commit
e63af0b7ce
243 changed files with 10 additions and 11506 deletions
19
library/sticky-posts.php
Normal file
19
library/sticky-posts.php
Normal file
|
@ -0,0 +1,19 @@
|
|||
<?php
|
||||
/**
|
||||
* Change the class for sticky posts to .wp-sticky to avoid conflicts with Foundation's Sticky plugin
|
||||
*
|
||||
* @package FoundationPress
|
||||
* @since FoundationPress 2.2.0
|
||||
*/
|
||||
|
||||
if ( ! function_exists( 'foundationpress_sticky_posts' ) ) :
|
||||
function foundationpress_sticky_posts( $classes ) {
|
||||
if ( in_array( 'sticky', $classes, true ) ) {
|
||||
$classes = array_diff( $classes, array( 'sticky' ) );
|
||||
$classes[] = 'wp-sticky';
|
||||
}
|
||||
return $classes;
|
||||
}
|
||||
add_filter( 'post_class', 'foundationpress_sticky_posts' );
|
||||
|
||||
endif;
|
Loading…
Add table
Add a link
Reference in a new issue