Here is the solution that seemed to work. Thanks Tom
function new_excerpt_more($more) {
global $post;
$thePostID = $post->ID;
if($thePostID == 1128) {
return '...<a class="readmore" href="'. get_permalink($post->ID) . '">Watch Video »</a>';
} else {
return '...<a class="readmore" href="'. get_permalink($post->ID) . '">Read more »</a>';
}
}
add_filter('excerpt_more', 'new_excerpt_more');
Related Posts:
- opening links in new tab using – add_filter( ‘the_content’, ‘make_clickable’);
- Default or Preset Content for Custom Post Types
- How would go about if I just want a temporary function?
- How to filter out shortcode when displaying the_excerpt() in the loop?
- str_replace function in theme
- Insert image in WordPress with HTML5 tag and caption function
- Setting a default text for excerpts of a particular category
- login_headertitle is deprecated since version 5.2.0
- The_content and Preg_replace in loaded Iframe [closed]
- Problem with images URL after filter applying
- Save_post – Warning: Cannot modify header information
- Appending „read more” to the excerpt conditionally
- Hide disclaimer from summary excerpts
- Shortcode to eliminate and replace with
- child_of not working while searching
- Can’t change excerpt length and more tag
- function to show youtube videos within excerpt – if condition and apply_filters
- Adding an external HTML link to a post thumbnail
- Replace a menu with widget or a custom template file programmatically
- woocommerce change currency per category [closed]
- Move Custom Fields on General Settings Page to New Location
- new_excerpt_more link not working properly
- Skeleton Child Theme Add Icon Bar to Header Flex Grid
- Run wp_kses_decode_entities on atom feed?
- Filtering out the #more anchor link that gets produced by
- Can’t filter wp_get_attachment_link
- Excerpts are not displayed by a shortcode on category pages
- Redirect to another page using contact form 7? [closed]
- append to existing parent theme function
- different style sheet for just one page template
- Add Element as a Filter to the_content
- Override the WordPress core function wp_referer_field
- Modify post filter to set custom number of posts per page and exclude child posts
- Make wp_link_pages() suitable for Twitter Bootstrap markup
- How to display retweet count and likes in the meta above the excerpt
- How can I add a filter for specific categories on functions.php?
- How to add custom JavaScript in functions?
- How to edit the Tags within the image file URLs?
- How would I go about replacing this function in my child theme located in inc/template-tags.php
- Condition OR for current user ID
- Retrieve a value from Yoast SEO to use to set a default twitter card image honoring overrides
- Can’t properly set the_title add_filter to show short_URL
- Add_filter when value is no variable?
- How to retrieve the current post’s generated featured image size?
- How to add_filter html template to middle of content
- (Woocommerce) Order by price when entering specific category
- Filter an WordPress Function in (general-template.php)
- Remove links from the_content when using filters wp_trim_excerpt
- Custom Behavior when Adding New Custom Post Type in Dashboard
- Where do I store custom functions that call custom page template files?
- Excerpt for pages not showing
- Redefine function arguments before rendering
- Why There Is No “get content by ID” Function
- How to edit classes in body tag?
- Custom HTML markup
- Use a shortcode to display custom meta box contents
- How do I pull excerpts from pages?
- Filter nav menu items HTML tags and wrap inner text with span
- Wp-query Order By problem
- Possible to hook into Media Library preview File column and use a custom image?
- WordPress Excerpt – How to remove the first link using functions.php
- How can I add a class to a nav li depending on URL?
- Create page template via functions.php?
- Create custom function for hero image
- Randomizing wp_tag_cloud() in child theme
- Modify gform_other_choice_value for specific form and specific field in Gravity Forms
- Combine embed_oembed_html and oembed_result
- Set “woocommerce_is_purchasable” to false for specific “$product->is_stock_status”
- How to append classname to body tag if guest user
- How to display the_archive_title() and the_archive_description() – “weird” interaction
- Where do I go to edit this area? [closed]
- Filter to wp_list_authors
- Strip div From Excerpt
- How to add custom li item to wordpress menu
- Replace plugin function with a custom function?
- Add attribute only to first image of every post via functions.php
- Native gallery custom html output
- How to change value of variable in theme file with functions.php WordPress?
- Different favicon on different pages
- first paragraph of the_content as meta description
- How to edit/replace Parent functions.php function in Child Theme to add “Walker” class
- Functions Filter Question [closed]
- Is it possible to use add_filter in an included file in the child theme’s functions.php?
- Insert Content Before div#main from the functions.php File
- Add Adsense code between job listings – wp job manager plugin
- remove_action not working, even after changing priority [duplicate]
- remove/hide wp-editor
- two search forms on the same page
- Function to replace comment’s accented characters before posting
- Replace header image on all other pages but home – URL issue
- Insert a field with PREG_REPLACE – strange behaviour
- How to echo Widget Title in Custom Frontend-Template Box
- Add a class to post if it has been recently updated
- Adding Read More to Custom excerpts
- New checkbox in custom widget isn’t saving data
- Linking Javascript in functions.php file
- how to display a page before the home page
- search form leads to 404
- loginout function customization
- Limit number of characters in different excerpts