User Tools

Site Tools


themes:template_tags

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
Last revision Both sides next revision
themes:template_tags [2014/03/08 15:49]
Bertrand [Echo / output functions]
themes:template_tags [2014/06/30 22:56]
shawn_a [Echo / output functions]
Line 59: Line 59:
 ==get_header( $full=true )== ==get_header( $full=true )==
 <​code><?​php get_header();​ ?></​code>​ <​code><?​php get_header();​ ?></​code>​
-Echos the page's header. No options. This automatically creates the <​del>​4</​del> ​2 meta tags (<​del>'​description',</​del>​ '​keywords',​ '​canonical'<​del>​ and '​generated'</​del>​). If ''​$full''​ is FALSE, will not generate the ''<​link rel="​canonical"​ ...>''​. Place this code within your theme'​s ''<​head>''​ ''</​head>''​ tags.  **Many plugins need this tag to be in place.**+Echos the page's header. No options. This automatically creates the 2 meta tags (<​del>'​description',</​del>​ '​keywords',​ '​canonical'<​del>​ and '​generated'</​del>​). If ''​$full''​ is FALSE, will not generate the ''<​link rel="​canonical"​ ...>''​. Place this code within your theme'​s ''<​head>''​ ''</​head>''​ tags.  **Many plugins need this tag to be in place.**
  
 ==get_footer()== ==get_footer()==
Line 93: Line 93:
 ==get_navigation( $currentpage = get_page_slug(false),​ $classPrefix = ""​ )== ==get_navigation( $currentpage = get_page_slug(false),​ $classPrefix = ""​ )==
 <​code><?​php get_navigation( '​tour'​ ); ?></​code>​ <​code><?​php get_navigation( '​tour'​ ); ?></​code>​
-Returns a list of pages that are added to the main menu from each of their edit screens. Required option is what is shown above. This creates a class of '​current'​ on the ''<​li>''​ element that is currently the active page. You need to supply the ''<​ul>''​ or ''<​ol>'' ​+Returns a list of pages that are added to the main menu from each of their edit screens. Required option is what is shown above. This creates a class of '​current'​ on the ''<​li>''​ element that is currently the active page. You need to supply the ''<​ul>''​ or ''<​ol>''​. get_navigation will add a class to each menu ''<​li>''​ with the id of the menu items slug, if these slug classes conflict with other css rules, say generic ones such as .menu .main then you can add an optional prefix that will be prepended to the class names to make them more unique and less likely to conflict with other classes.
  
 ==menu_data( $id = null, $xml=false )== ==menu_data( $id = null, $xml=false )==
themes/template_tags.txt · Last modified: 2014/06/30 22:59 by shawn_a