add_theme_support('menus')
to the plugin, so that this doesn’t need to be added by the theme or by other custom code.
]]>function mytheme_format_support() {
add_theme_support( 'post-formats', ['video', 'audio' ] );
}
add_action( 'after_setup_theme' , 'mytheme_format_support' );
add_post_type_support( 'page' , 'post-formats' );
When I go to create a new page, happily, the format options for Audio, Standard, and Video are present. Unhappily, however, when I select either Audio or Video, WP saves the page as Standard; for posts, though, WP saves the selected format just fine.
Am I missing something? Thanks in advance.
]]>I noticed that if I have some colors added in the palette via my theme.json the add_theme_support(“editor-color-palette”); doesn’t work.
Is it a normal behavior or bug?
Best regards
]]>I checked my functions.php and everything is still fine:
add_theme_support( ‘post-thumbnails’ );
I have tried all kind of stuff, but nothing that solves the problem, where it used to work perfectly before the upgrade.
I also tried:
function theme_setup(){
/** post thumbnail **/
add_theme_support( ‘post-thumbnails’ );
}
add_action(‘after_setup_theme’,’theme_setup’);
Any ideas?
]]><title>childsRI7; play</title>
It should be like:
<title>child's play</title>
I don’t know how to fix it. Please help!
I can fix the_title()
tag with remove_filter( 'the_title', 'wptexturize' );
But it’s not working for wp_title neither add_theme_support.
In my theme the featured image is declared for posts only:
add_theme_support( 'post-thumbnails', array( 'post') );
I have a plugin that’s using a custom post type.
How to add the featured image box for this custom post type as well?
Because adding it to the supports
array while registering the post type doesn’t work.
In codex I’m reading this:
Note: When you use custom post type that use thumbnails remember to check that the theme also supports thumbnails or use add_theme_support
function.
But add_theme_support
must be called in the theme’s functions file to work (link).
So what’s the proper way to include this in my plugin?
Guido
]]>i discovered infinite_scroll looking at the _s starter theme.
i understand how add_theme_support works but didn’t realize a theme could add something like this on its own.
is this feature still supported and used? i have a jetpack plugin install and am not finding it to examine the code.
it’s kinda blowing my mind and i’d like to see the code but i’m confused that i can’t find it.
thank you <3
]]>array( 'post' )
to array( 'page' )
to re-enable the feature for just pages.remove_theme_support( 'post-thumbnails' );
to functions.php inside a setup function. add_theme_support
to be sure it wasn’t enabled somewhere else, this is the only instanceadd_theme_support
from functions.phpremove_theme_support( 'post-thumbnails' );
directly below add_theme_support( 'post-thumbnails' );
add_theme_support( 'post-thumbnails' );
NOT commented outI don’t get it. It’s like the feature is permanent. I’ve played around with the priority, but the more direct method seems like it doesn’t work anyway. Anything that points me in the direction of what I’m missing would be greatly appreciated.
The only other thing to mention is that I am not looking for a CSS fix. This is a site for a client, I don’t want to have a meta box on the admin side that doesn’t do anything. As a last resort, I can hide it with CSS on the admin side, but I’d rather find the right way to do it.
Swani
]]>$defaults = array(
'default-color' => '',
'default-image' => '',
'default-repeat' => 'no-repeat',
'default-position-x' => 'center',
'default-position-y' => 'fixed',
'default-size' => 'fixed',
'default-attachment' => 'scroll',
'wp-head-callback' => '_custom_background_cb',
'admin-head-callback' => '',
'admin-preview-callback' => ''
);
add_theme_support( 'custom-background', $defaults );
but these codes changed my design which created with css.the theme is based on parallax so if css doesnt work, all theme will waste.
here is the css:
/* parallax */ #home {
background: url(<?php get_background_image(); ?>) no-repeat center center fixed;
display: table;
height: 100%;
position: relative;
width: 100%;
-webkit-background-size: cover;
-moz-background-size: cover;
-o-background-size: cover;
background-size: cover;
}
so how can shape the function with css? thank you for your helps
]]>
add_theme_support ('align-wide');
I got this error in the editor “Error Null”
Thanks
]]>