php – add_post_type_support but for front_page only

Question

I want to enable excerpt for pages, but for front_page only.
Using add_post_type_support('page','excerpt') enables it for all pages, since the first argument is $post_type.
How can I narrow down it to front_page? Various ifs in functions.php like is_front_page() doesn’t work since I’ve read WordPress, on functions.php loading, doesn’t know yet about post types.

Prefer not to use css to hide excerpt field.

0
qfwfq 1 month 2022-12-24T05:05:59-05:00 0 Answers 0 views 0

Leave an answer

Browse
Browse