Menu Adam R Brown

WP hooks navigation: Home/browseActions indexFilters index

Source View: get_footer

To save our bandwidth, we show only a snippet of code around each occurence of the hook. View complete file in SVN (without highlighting).

Understanding Source Code

The best way to understand what a hook does is to look at where it occurs in the source code.

Remember, this hook may occur in more than one file. Moreover, the hook's context may change from version to version.

Source View

Line Code
65       * The hook allows a specific footer template file to be used in place of the
66       * default footer template file. If your file is called footer-new.php,
67       * you would specify the filename in the hook as get_footer( 'new' ).
68       *
69       * @since 2.1.0
70       * @since 2.8.0 $name parameter added.
71       *
72       * @param string $name Name of the specific footer file to use.
73       */
74      do_action( 'get_footer', $name );
75
76      $templates = array();
77      $name = (string) $name;
78      if ( '' !== $name ) {
79           $templates[] = "footer-{$name}.php";
80      }
81
82      $templates[]    = 'footer.php';
83