On a Twentyeleven child theme's functions.php file I attempted to add video post format support using:

add_theme_support('post-formats', array( 'aside', 'chat', 'gallery', 'image', 'link', 'quote', 'status', 'video', 'audio'));

...adding the 'video' format to the array. But it would not work until I deleted the function in the parent theme. Obviously, when the theme is updated and functions.php is overwritten, I will lose the change.

Whats the best way to avoid this and add support to my child theme?



try running your code with a lower priority:

add_action( 'after_setup_theme', 'my_twentyeleven_setup', 20 );

function my_twentyeleven_setup(){
  add_theme_support('post-formats',  array( 
| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.