You are stomping on the global wordpress posts with your plugin.
Doing your wp_query call and then calling
$recent_articles_wtb->the_post();
means that later (after your loop), you will want to call
wp_reset_postdata(); # Thanks Milo
That should reset the global $current_post and $post objects.
Related Posts:
- How to target the default Recent Posts and Recent Comments widgets with pre_get_posts?
- Most commented last 24h, week, month, year and all time – posts_where
- WP_Comment_Query pagination, delving into the unknown
- Exclude comments from a WP_Query object?
- Get posts with condition on comment meta value
- WP_Query sort by comment meta data
- Get number of comments after modifying comment query
- using wp_query to return posts w/ comment count > 0
- Pass the same object to multiple widgets in a template with one query
- How can i make WP_Query return post image and categories?
- Query posts with more than 20 comments
- How can I retrieve comments from last 5 minutes for a post?
- Retrieving list of a custom post type in a widget without using WP_Query?
- Sorting posts DESC based on the number of comments using WP_Query
- How to detect if query is runned from widget?
- Most commented post showing 2 records
- WordPress Comments sort by custom meta key
- Show post number in widget loop
- Query posts by last comments
- How to list posts with disabled/closed comments, with pagination?
- Error with function in functions.php?
- I need help using pre_get_comments to limit comments in the comments admin screen
- How to create a widget like this?
- Widget only in first post
- How to add a recent post function to a text widget I created for practice?
- Widgets: Show Recent Posts Only if the Posts Have Both Categories X and Y
- prevent get_comments() from returning comments not in comment__in
- Is it possible to give a classname to specific comments in the WordPress admin?
- How to get_comments() ordered by date and parent?
- How can I show only last year posts in wordpress archive?
- wp_query in form method of widget breaks customizer
- Comments orderby comment date not working
- How to display comments list by order when clicking on newest or oldest link?
- Get comment number by date range?
- Wp_query to get woocomerce product categorys [closed]
- WP_Query orderby post__in remains ineffective in the Loop [closed]
- Using get_posts vs. WP_Query
- Way to include posts both with & without certain meta_key in args for wp_query?
- How to Access Global $multipage or Global $numpages outside the loop?
- How can I use WP-CLI commands without –allow-root
- Calling a wp_query $posts causes a 500 error
- WP_query taxonomy + get all posts with two terms from same taxonomy
- Merging a complex query with post_rewind and splitting posts into two columns
- How do I create my own nested meta_query using posts_where / posts_join?
- WP_Query in a shortcode
- ‘posts_where’ filter not applying ‘WP_Query’ in `wp_ajax`
- meta_query not working properly
- Best Practice For Querying Grandchildren?
- Get all posts without tags
- Filter wp_query to search post title in function
- Two queries on the same page with pagination
- Using tax_query reverses my post_type argument in a custom WP_Query
- Best approach to create Hot and Trending sections
- creating wp query with posts with specific category
- $wp_query->current_post restarts from zero on paged pages
- get complex results set according to category structure
- wp_get_post_terms of cpt but not duplicates if they are used more than once in the loop
- How to prevent queried posts from being added to cache?
- Setup of taxonomy term template pages
- Ignore post by meta value in the main query
- Display posts in 3 days chunk
- Hide Post comments when displayed via WP_Query
- How to make orderby ‘meta_value_num’ OPTIONAL?
- how to get the id for a post from within a post and return post meta for it
- WP_Query’s “request” SQL Query
- How to do a query on custom taxonomies that is uncategorised?
- How to make this WP_Query run faster on a WordPress website?
- Order taxonomy terms in alphabetical order
- is_search was called incorrectly
- Empty tax_query array returns an empty array
- How can I query posts with newly uploaded images?
- Conditional arguments WP_Query for post custom fields
- How do I sort posts with multiple pages
- Sorting By Custom Posts With Attachments
- Random loop with code to prevent duplicate output returns no output at all from time to time
- Single meta_query query using OR instead of AND in request’s WHERE statement
- How to choose between hooking into per_get_posts or into parse_query
- Woocommerce returns Product post_status as published even tho it is in status draft
- remove query arg from url after set query
- How to loop for every result found in the_content() when using the search query?
- How to set pagination to work with ‘/page/’?
- How to do meta_query for attachments?
- How can I fix: “Notice: Undefined offset: 0”?
- SQL: What is wrong with the following query (generated by WordPress WP_Query, ordering prices)
- Order By table field comment_status in WordPress > 4.0
- Slow WP_Query for custom post type
- WP_Query Pagination on multiple-loop page breaks WP or doesn’t show up
- Why isn’t my `meta_query` array functioning properly?
- Using hook to use DISTINCT in a wp_query
- Overwrite YoastSEO meta-tags with another page’s [closed]
- How to duplicate 5 posts out of WP_Query results?
- Import wp users via one click demo option
- How to restrict the search fields for a specific post type
- WP_query sorting can’t sort danish letters (æ, ø, å)
- Dynamic User Id
- Slow queries on a huge database
- Multisite pagination issue by multi query archive 404
- Query with relation and one without relation using multiple taxonomies?
- get_post_meta slowing down my page load (in a plugin)
- Automatically Query Parent Taxonomy