links.php
Description: Displays a list of links.
This template includes the following templates:
Template Code
<?php get_header() ?>
<div id="container">
<div id="content">
<?php the_post() ?>
<div id="post-<?php the_ID(); ?>" class="<?php sandbox_post_class() ?>">
<h2 class="entry-title"><?php the_title() ?></h2>
<div class="entry-content">
<?php the_content() ?>
<ul id="links-page" class="xoxo">
<?php wp_list_bookmarks('title_before=<h3>&title_after=</h3>') ?>
</ul>
<?php edit_post_link(__('Edit', 'sandbox'),'<span class="edit-link">','</span>') ?>
</div>
</div><!-- .post -->
<?php if ( get_post_custom_values('comments') ) comments_template() // Add a key/value of "comments" to enable comments on pages! ?>
</div><!-- #content -->
</div><!-- #container -->
<?php get_sidebar() ?>
<?php get_footer() ?>
This template includes the following tags:
__()is a WordPress function used to mark a string for translation to another language. It is similar to_e(), except that__()returns the string while_e()echoes it.comments_template()is a WordPress include tag which includes the filecomments.php.edit_post_link()is a Wordpress tag which displays a link to edit the current post (assuming the user is logged in and has the appropriate permissions).get_footeris a WordPress include tag which includes the filefooter.php.get_headeris a WordPress include tag which includes the fileheader.php.get_post_custom_values()is a WordPress PostMeta internal function used to get the list of values for a particular key on the current post. It should be within The Loop.get_sidebaris a WordPress include tag which includes the filesidebar.php.sandbox_post_class()is a Sandbox-specific class defined in thefunctions.phpfile. According to the Sandbox Readme, "It adds semantic classes to each postdivelement, relative to the actual post it contains."the_content()is a Wordpress tag which displays the contents of the current post. This tag must be used within The Loop.the_ID()is a WordPress tag which displays the numeric ID of the current post. It must be within The Loop.the_post()is aWP_Querymethod: "Advance onto the next post, and set the global $post variable."the_title()is a WordPress tag which displays or returns the title of the current post. This tag must be used within The Loop.wp_list_bookmarks()is a WordPress tag which displays the blogroll.
HTML Skeleton
[HEADER.PHP] <div id="container"> <div id="content"> <div id="post-[#]" class="hentry p1 page publish author-[AUTHOR] category-uncategorized tag- y[YEAR] m[MONTH] d[DAY] h[HOUR]"> <h2 class="entry-title">Links</h2> <div class="entry-content"> </p> <ul id="links-page" class="xoxo"> <li id="linkcat-[#]" class="linkcat"> <h3>Blogroll</h3> <ul> <li>[LINK]</li> </ul> </li> </ul> <span class="edit-link">[EDIT]</span> </div> </div> <!-- .post --> </div> <!-- #content --> </div> <!-- #container --> [SIDEBAR.PHP] [FOOTER.PHP]
Related CSS Styles
Resources
- N/A