Skip to content

Instantly share code, notes, and snippets.

@omidgharib
Forked from anonymous/jsbin.osexor.html
Created July 12, 2013 11:31
Show Gist options
  • Save omidgharib/5983774 to your computer and use it in GitHub Desktop.
Save omidgharib/5983774 to your computer and use it in GitHub Desktop.
These are useful WordPress functions
@omidgharib
Copy link
Author

get_template_part : Load a template part into a template
bloginfo : Displays information about your site
wp_title : Displays or returns the title of the page
wp_list_pages : Displays a list of WordPress Pages as links
have_posts : This function checks to see if the current WordPress query has any results to loop over.
the_post : Iterate the post index in The Loop
the_title : Displays or returns the title of the current post
the_content : Displays the contents of the current post
wp_nav_menu : Displays a navigation menu created in the Appearance → Menus panel

@omidgharib
Copy link
Author

functions.php

a specific file for configuring more theme details on wordpress
add_theme_support : Allows a theme or plugin to register support of a certain theme feature
register_nav_menu : Registers a menu location to use with navigation menus

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment