Wordpress Cheat Sheet PDF
Wordpress Cheat Sheet PDF
Wordpress Cheat Sheet PDF
Use this page for a quick, categorized list of WordPress functions that are commonly used when building, updating and
maintaining templates. Simple, Easy, Copy-Pasta . The quick guide to common WordPress > Template functions.
Navigation
Basic Template Files Header Functions Menu
style.css style sheet file root url for <?php wp_nav_menu(); ?>
<?php site_url(); ?>
website
template
sidebar.php sidebar content file <?php bloginfo('template_url'); ?>
folder path <ul id="menu">
page.php single page file wordpress <li <?php if(is_home()) { ?> class="current-page-item" <?php } ?>>
<?php bloginfo('version'); ?>
blog version
front-page.php latest posts or static page <a href="<?php bloginfo('home'); ?>">Home</a></li>
<?php bloginfo('atom_url'); ?> atom url
tag.php display tags in archive format <?php wp_list_pages('sort_column=menu_order&depth=1&title_li=');?>
<?php bloginfo('rss2_url'); ?> rss2 url
category.php display categories in archive format </ul>
root url for
<?php bloginfo('url'); ?>
website
charset
<?php bloginfo('charset'); ?>
parameter
Template Functions The Loop
<?php if(have_posts()): ?> check if there are posts <?php while(have_posts()) { ?>
<?php endwhile; ?> closes loop <?php // custom post content code for title, excerpt and featured image ?>