[ Index ]

PHP Cross Reference of WordPress

title

Body

[close]

/wp-content/themes/twentyfifteen/ -> functions.php (summary)

Twenty Fifteen functions and definitions Set up the theme and provides some helper functions, which are used in the theme as custom template tags. Others are attached to action and filter hooks in WordPress to change core functionality.

File Size: 559 lines (17 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 11 functions

  twentyfifteen_setup()
  twentyfifteen_widgets_init()
  twentyfifteen_fonts_url()
  twentyfifteen_javascript_detection()
  twentyfifteen_scripts()
  twentyfifteen_block_editor_styles()
  twentyfifteen_resource_hints()
  twentyfifteen_post_nav_background()
  twentyfifteen_nav_description()
  twentyfifteen_search_form_modify()
  twentyfifteen_widget_tag_cloud_args()

Functions
Functions that are not part of a class:

twentyfifteen_setup()   X-Ref
Sets up theme defaults and registers support for various WordPress features.

Note that this function is hooked into the after_setup_theme hook, which
runs before the init hook. The init hook is too late for some features, such
as indicating support for post thumbnails.

since: Twenty Fifteen 1.0

twentyfifteen_widgets_init()   X-Ref
Register widget area.

since: Twenty Fifteen 1.0

twentyfifteen_fonts_url()   X-Ref
Register Google fonts for Twenty Fifteen.

since: Twenty Fifteen 1.0
return: string Google fonts URL for the theme.

twentyfifteen_javascript_detection()   X-Ref
JavaScript Detection.

Adds a `js` class to the root `<html>` element when JavaScript is detected.

since: Twenty Fifteen 1.1

twentyfifteen_scripts()   X-Ref
Enqueue scripts and styles.

since: Twenty Fifteen 1.0

twentyfifteen_block_editor_styles()   X-Ref
Enqueue styles for the block-based editor.

since: Twenty Fifteen 2.1

twentyfifteen_resource_hints( $urls, $relation_type )   X-Ref
Add preconnect for Google Fonts.

since: Twenty Fifteen 1.7
return: array URLs to print for resource hints.
param: array   $urls          URLs to print for resource hints.
param: string  $relation_type The relation type the URLs are printed.

twentyfifteen_post_nav_background()   X-Ref
Add featured image as background image to post navigation elements.

since: Twenty Fifteen 1.0

twentyfifteen_nav_description( $item_output, $item, $depth, $args )   X-Ref
Display descriptions in main navigation.

since: Twenty Fifteen 1.0
return: string Menu item with possible description.
param: string  $item_output The menu item output.
param: WP_Post $item        Menu item object.
param: int     $depth       Depth of the menu.
param: array   $args        wp_nav_menu() arguments.

twentyfifteen_search_form_modify( $html )   X-Ref
Add a `screen-reader-text` class to the search form's submit button.

since: Twenty Fifteen 1.0
return: string Modified search form HTML.
param: string $html Search form HTML.

twentyfifteen_widget_tag_cloud_args( $args )   X-Ref
Modifies tag cloud widget arguments to display all tags in the same font size
and use list format for better accessibility.

since: Twenty Fifteen 1.9
return: array The filtered arguments for tag cloud widget.
param: array $args Arguments for tag cloud widget.



Generated: Tue Jul 23 01:00:03 2019 Cross-referenced by PHPXref 0.7.1