getSidebar( $name = '' )

Includes 'sidebar.php' from the primary theme directory. If 'sidebar.php' does not exist in the primary theme directory, this function attempts to load the file from the core theme directory. If the file does not exist in the core theme directory, nothing is loaded. This function is the same as calling getFile('sidebar.php')

  • string $name: (optional) If a value is entered for $name, the function includes 'sidebar_$name.php'. For example, if you pass the value "left" to the function, it attempts to load 'sidebar_left.php'.

Example:

<?php getSidebar('left'); ?>
See also: get_sidebar(), getFile(), get_file()
Last modified on Wednesday, 31 March 2010 23:04

1 Comment

  • Comment Link ルームウェア Tuesday, 27 March 2012 03:16 posted by ルームウェア

    Thanks for your great post.I like this very much, please write more about these,wait for your update.


Add comment