'glm_foundation',
get_template_directory_uri() . '/js/app.js',
'jquery',
- '1.0',
+ '1.1',
true
);
wp_enqueue_script('jquery-ui-datepicker');
$page = get_post( $post->ID );
return has_shortcode( $page->post_content, $shortcode );
}
-function ca_only_add_more_when_required( $default, $text, $options ) {
- $text = strip_tags( $text );
- if ( 'words' === $options['length_type'] ) {
- $excerpt_length = str_word_count( $text );
- } else {
- $excerpt_length = strlen( $text );
- }
- if ( $excerpt_length > $options['length'] ) return $default;
- return true;
-}
+function ca_only_add_more_when_required( $default, $text, $options ) {
+ $text = strip_tags( $text );
+ if ( 'words' === $options['length_type'] ) {
+ $excerpt_length = str_word_count( $text );
+ } else {
+ $excerpt_length = strlen( $text );
+ }
+ if ( $excerpt_length > $options['length'] ) return $default;
+ return true;
+}
add_filter( 'advanced_excerpt_disable_add_more', 'ca_only_add_more_when_required', 10, 3 );
?>