The internal implementation details of that feature are of questionable sanity.
- If you take a look at said
featured-content.php
template you would see - that it get posts from
twentyfourteen_get_featured_posts()
however - the only thing that function has is
twentyfourteen_get_featured_posts
filter - from quick look at which in peculiar fashion nothing is actually getting hooked
- because
twentyfourteen_setup()
declaresfeatured-content
feature - with configuration defining
featured_content_filter
as the one above - to which
Featured_Content
class hooks itsget_featured_posts()
method - which burrows further to
get_featured_posts_ids()
method - which calculates, caches, and returns those IDs
So there are a… few points at which you can work with… this. 🙂
From practical point of view you would probably want to hook into twentyfourteen_get_featured_posts
filter and conditionally return different set of posts as you need.
Related Posts:
- Error when adding excerpt to the content through functions.php
- Is it possible to display a DIV to not logged in users and then change it for users who are logged in?
- Before & After Content – After Content directly below Before Content when using require_once
- Add end mark at the end of every article
- WordPress 2014 Theme – Featured Content with multiple tags?
- Overwriting a Shortcode
- How to make a image-size selected by default in Media upload – WP v3.5
- Hide main div if wp_nav_menu is empty
- How to draw media details for Isotope gallery using Photoswipe
- Change the footer text on the login page
- Remove wp-mediaelement.css from wp_head
- add_filter to post-gallery and remove all ‘s?
- Setting up the child theme so as to enable right-to-left WordPress?
- Design view breaking on Pages
- Hooking new functions to actions + passing parameters
- Execute only on a certain page
- How do I know what variables are passed in a filter/action and what their meaning is?
- Replace comment avatars and links at the same time
- Check if Product is in a Specific Category in Functions.php
- Adding ads code between comments
- Create Logout Link WordPress Admin Menu
- How to Display Image Meta underneath EVERY image in EVERY post
- Calculations in functions.php [closed]
- Limiting woocommerce line_total decimal length
- Shortcode content filter?
- only show container with next/prev links if they exist?
- JS file work only in index page
- Error in custom php function doesn’t exist
- Custom shortcode outputs plain text instead of HTML at top of post
- how can i use $_COOKIE[] + PostID to execute the below code?
- register_taxonomy() take much queries
- Can anyone offer any help with this function?
- Shortcode with PHP issue “Undefined index”
- height should be set to auto to avoid pixelation in the post thumbnail function
- Can i put my shortcode inside a variable in php files?
- Override a function defined in wp-includes/comment-template.php
- Show meta box only for default page template
- Can’t access site after making changes to the functions.php [closed]
- Is it possible to define variables in a wordpress shortcode, and then call the shortcode using a specific variable?
- Countdown to date function?
- calling a custom field value inside functions.php
- Custom meta box values are not getting saved for my custom post type
- Simple AJAX notification when the new post is added to the database
- Upload multiple files in randomly generated folder using wp_upload_bits
- Personalize checkout text
- WordPress check if current taxonomy has child
- get post id from wp_insert_post for get_template_part
- This function is deprecated; use mysql_real_escape_string() instead
- get_theme_mod outputs number when using WP_Customize_Cropped_Image_Control
- Adding an interior ‘hero’ area with some added php title customization
- Call to undefined function error in plugin
- Custom Taxonomy Select Menu: Setting default option value?
- How to add author’s posts link (HTML + PHP) inside a function to output it
- Creating customized php files in theme folder
- Conditional On custom field plugin metabox
- WordPress Twenty Eleven PhP – forcing php code to skip first post on homepage?
- Post Views Code Hacks
- Closing WP_LINK_PAGES DIV ID w/After Argmuent
- Exclude function from running on a certain page
- Menu not styling. New menus functionality giving me a headache
- How to set value selected using select2 jquery plugin
- For some time, some of my pages do not display the content anymore. Any idea where this could be coming from?
- Workaround for og:image unsupported webp image type, Yoast SEO?
- Disclaimer that will show every refresh of the page
- Dynamically switch file in get_template_directory_uri() | Function [closed]
- Using ACF Relationship field to set post type to draft or published status
- Providin exception to WordPress wp_nav_menu Custom CSS Classes
- Woocommerce My acount page
- How can i avoid duplicate same post in wp?
- Child theme overirde template-tags in a theme built on underscores in inc/template-tags
- Custom meta box is not displaying value showing tag as empty
- Menu not updating for logged in users after redirect
- PHP/CSS: Shortcode won’t display correctly, and only displays in the head (before content)
- All categories options or All categories not Populating
- WordPress load javascript file if something… (after the page is loaded)
- Add class for the_post_thumbnail_caption()
- Getting page / post URL on publish and / or update
- Wrapping shortcode content in a span or link
- Weird Behaviour: Not all WordPress Posts appearing
- Save the outputted image into the Media Library, with a different filename and extension
- Custom Taxonomy as Link
- Permission functions within wordpress
- Adding ID to a Listing but not inside WP_Query while
- adsense code showing on random post thumb
- WordPress display name string manipulation
- How to extend the page editor?
- which table updated after logout?
- Accessing WordPress Functions get_permalink() in Vanilla PHP?
- How to return a Boolean for a page that is a subpage thru its name?
- I need a button to appear when not loged in and another when logged in, I need help fixing code PLEASE!
- Saving User Input to PHP Variable
- Undefined variable notice [closed]
- How to hide .js files on wordpress website using php or wp plugins or any? [closed]
- Dynamic Email Handler with ‘header (“Location: …’
- WooCommerce: write featured image dimensions to custom fields in product’
- Generate and upload screenshot as featured image for user-submitted post
- a problem in class in class-wp-hook.php
- transition_post_status hook, works – but not if the post is new
- change title of page dynamically
- Custom plugin doesn’t show in admin menu – when code added, displays an empty page