[wp-trac] [WordPress Trac] #43254: Link to the Conditional Tags article in the themes handbook from DocBlocks for all conditional tag functions
WordPress Trac
noreply at wordpress.org
Thu Feb 8 00:04:27 UTC 2018
#43254: Link to the Conditional Tags article in the themes handbook from DocBlocks
for all conditional tag functions
----------------------------------------+-------------------
Reporter: DrewAPicture | Owner:
Type: task (blessed) | Status: new
Priority: normal | Milestone: 5.0
Component: Themes | Version:
Severity: normal | Resolution:
Keywords: needs-patch good-first-bug | Focuses: docs
----------------------------------------+-------------------
Description changed by DrewAPicture:
Old description:
> We have a lot of conditional tags in core. And by virtue of being
> conditional, they're therefore all related.
>
> We've recently had some contributions to the Code Reference attempting to
> link those functions together via "Related" lists, and since we've
> already codified a fancy document about them in the themes handbook, we
> should just point interested parties there for more information instead
> of posting giant link lists on DevHub.
>
> I would suggest we link the page in the DocBlock descriptions via an
> inline `@link` tag vs a standalone one (which currently isn't exposed
> anywhere when the Code Reference is parsed from source). Inline link tags
> use the following syntax: `{@link URL Label}`
>
> I'd propose we use the same standard language along the lines of this:
> > For more information on this and similar theme functions, check out the
> [Conditional Tags] article in the Theme Developer Handbook.
>
> The handbook article: https://developer.wordpress.org/themes/basics
> /conditional-tags/
>
> The conditional tags whose docs should reference it:
>
> * comments_open()
> * is_404()
> * is_admin()
> * is_admin_bar_showing()
> * is_archive()
> * is_attachment()
> * is_author()
> * is_category()
> * is_comments_popup()
> * is_date()
> * is_day()
> * is_feed()
> * is_front_page()
> * is_home()
> * is_local_attachment()
> * is_main_query
> * is_multi_author
> * is_month()
> * is_new_day()
> * is_page()
> * is_page_template()
> * is_paged()
> * is_plugin_active()
> * is_plugin_active_for_network()
> * is_plugin_inactive()
> * is_plugin_page()
> * is_post_type_archive()
> * is_preview()
> * is_search()
> * is_single()
> * is_singular()
> * is_sticky()
> * is_tag()
> * is_tax()
> * is_taxonomy_hierarchical()
> * is_time()
> * is_trackback()
> * is_year()
> * in_category()
> * in_the_loop()
> * is_active_sidebar()
> * is_active_widget()
> * is_blog_installed()
> * is_rtl()
> * is_dynamic_sidebar()
> * is_user_logged_in()
> * has_excerpt()
> * has_post_thumbnail()
> * has_tag()
> * pings_open()
> * email exists()
> * post_type_exists()
> * taxonomy_exists()
> * term_exists()
> * username exists()
> * wp_attachment_is_image()
> * wp_script_is()
New description:
We have a lot of conditional tags in core. And by virtue of being
conditional, they're therefore all related.
We've recently had some contributions to the Code Reference from @ahortin
attempting to link those functions together via "Related" lists, and since
we've already codified a fancy document about them in the themes handbook,
we should just point interested parties there for more information instead
of posting giant link lists on DevHub.
I would suggest we link the page in the DocBlock descriptions via an
inline `@link` tag vs a standalone one (which currently isn't exposed
anywhere when the Code Reference is parsed from source). Inline link tags
use the following syntax: `{@link URL Label}`
I'd propose we use the same standard language along the lines of this:
> For more information on this and similar theme functions, check out the
[Conditional Tags] article in the Theme Developer Handbook.
The handbook article: https://developer.wordpress.org/themes/basics
/conditional-tags/
The conditional tags whose docs should reference it:
* comments_open()
* is_404()
* is_admin()
* is_admin_bar_showing()
* is_archive()
* is_attachment()
* is_author()
* is_category()
* is_comments_popup()
* is_date()
* is_day()
* is_feed()
* is_front_page()
* is_home()
* is_local_attachment()
* is_main_query
* is_multi_author
* is_month()
* is_new_day()
* is_page()
* is_page_template()
* is_paged()
* is_plugin_active()
* is_plugin_active_for_network()
* is_plugin_inactive()
* is_plugin_page()
* is_post_type_archive()
* is_preview()
* is_search()
* is_single()
* is_singular()
* is_sticky()
* is_tag()
* is_tax()
* is_taxonomy_hierarchical()
* is_time()
* is_trackback()
* is_year()
* in_category()
* in_the_loop()
* is_active_sidebar()
* is_active_widget()
* is_blog_installed()
* is_rtl()
* is_dynamic_sidebar()
* is_user_logged_in()
* has_excerpt()
* has_post_thumbnail()
* has_tag()
* pings_open()
* email exists()
* post_type_exists()
* taxonomy_exists()
* term_exists()
* username exists()
* wp_attachment_is_image()
* wp_script_is()
--
--
Ticket URL: <https://core.trac.wordpress.org/ticket/43254#comment:1>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list