Ready to get started?Download WordPress


[resolved] parameters for add_theme_support (2 posts)

  1. shazdeh
    Posted 3 years ago #

    The default WP comes with some awesome features like 'post-formats' and 'post-thumbnails'. When you declare that your theme supports these features you can add another parameter to define which areas of WP these will apply on. example: add_theme_support('post-formats',array('aside','gallery','link'));
    Now, I have added some other features in my theme and by using require_if_theme_supports load them in the WP. How can my registered theme_features accept parameter like the default post-thumbnails and 'post-formats' do?

  2. shazdeh
    Posted 3 years ago #

    Found it. use get_theme_support( $feature ) function which will return the parameter passed to add_theme_support.

Topic Closed

This topic has been closed to new replies.

About this Topic