How To Customize/Replace WordPress Post Excerpts

Example: Sometime we need to show content on frontend with adding some prefix or suffix or may be you have enter spelling mistakes in 2000 posts. so it is very difficult to modify 2000 posts so we can modify using filter . SO mistake will be replaced by correction.   For Modifying post content only:   function link_words( $text ) { $replace = ‘Replace with’; $text = str_replace( ‘Want To replace text’, $replace, $text ); return $text; } add_filter( ‘the_content’, ‘link_words’ );   For Modifying post excerpt only   function link_words( $text ) { $replace = ‘Replace with’; $text = str_replace( ‘Want To replace text’, $replace, $text ); return $text; } add_filter( ‘the_excerpt’, ‘link_words’ );   For Modifying post content and excerpt both   function link_words( $text ) { $replace = ‘Replace with’; $text = str_replace( ‘Want To replace text’, $replace, $text ); return $text; } add_filter( ‘the_content’, ‘link_words’ );

Sort A ACF Repeater Field Results

Filters the field $value after being loaded. Sort a repeater field using a function called array_multisort(). Sorting Filtering Modifying ACF results .

Fetch WordPress Categories

Fetch wordpress categories Using inbuilt functions like get_categories(), wp_list_categories(), wp_dropdown_categories().

Categories