Make WordPress Core

Changeset 461 for trunk/readme.html


Ignore:
Timestamp:
10/22/2003 09:26:20 PM (22 years ago)
Author:
emc3
Message:

Updated docs for dropdown_cats(), list_cats(), and get_archives()

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/readme.html

    r426 r461  
    297297    <li>0 or 1, depending if you want to have an option to display all categories (default is 1)</li>
    298298    <li>text to display for the option to show all categories (default is "All")</li>
     299    <li>sort by: possible values are 'name' and 'ID' (default is 'ID')</li>
     300    <li>sorting order: possible values are 'asc' for ascending or 'desc' for descending (default is 'asc')</li>
     301    <li>0 or 1. 1 means to display the date of the last post in each category (default is 0)</li>
     302    <li>0 or 1. 1 means to display a count of posts in each category (default is 0)</li>
     303    <li>0 or 1. 1 means to hide empty categories (default is 1)</li>
    299304  </ul>
    300305</div>
     
    309314<strong>&lt;?php list_cats() ?&gt; <br />
    310315</strong>This tag is out of the WordPress loop.<br />
    311 It will display a list of the categories, with links to them. like in b2archive.php, each category is on a line, the only way you can change this is by editing b2.template.functions.php<br />
    312 <div class="params">Parameters:
    313   <ul>
    314     <li>0 or 1, depending if you want to have an option to display all categories (default is 1)</li>
     316It will display a list of the categories, with links to them.
     317<div class="params">Parameters:
     318  <ul>
     319    <li>0 or 1. 1 means to display all an extra 'all' category (default is 1)</li>
    315320    <li>text to display for the option to show all categories (default is 'All')</li>
    316321    <li>sort by: possible values are 'name' and 'ID' (default is 'ID')</li>
    317322    <li>sorting order: possible values are 'asc' for ascending or 'desc' for descending (default is 'asc')</li>
    318323    <li>filename, in case you want to display the categories' posts in another template (default is current template)</li>
     324    <li>0 or 1. 1 means to generate the items inside &lt;li&gt; tags, to build an HTML list. 0 means to just follow each link with a &lt;br /&gt; tag. (default is 1)</li>
     325    <li>0 or 1. 1 means to display the date of the last post in each category (default is 0)</li>
     326    <li>0 or 1. 1 means to display a count of posts in each category (default is 0)</li>
     327    <li>0 or 1. 1 means to hide empty categories (default is 1)</li>
    319328  </ul>
    320329</div>
     
    507516It will output the URL to TrackBack the post, that other people can copy and use in b2's posting interface to trackback this post.<br />
    508517<p>  In b2comments.php, like in the main template file, please keep the first PHP lines, the "while" lines, and the "}" lines.</p>
    509 <p>You can modify the form, but do not remove "&lt;?php echo ... ?&gt;" and all the name="..." attributes.<br />
    510   <br />
    511 To <strong>include your archives:</strong><br />
    512 <br />
    513 <strong>&lt;?php get_archives('archivetype') ?&gt;</strong></p>
    514 <p>&quot;archivetype&quot; can be any of the following:</p>
    515 <ul>
    516   <li>postbypost</li>
    517   <li>daily</li>
    518   <li>weekly</li>
    519   <li>monthly</li>
    520 </ul>
    521 <p>To <strong>include the calendar:</strong></p>
     518<p>You can modify the form, but do not remove "&lt;?php echo ... ?&gt;" and all the name="..." attributes.</p>
     519<br />
     520<p><strong>To include your archives:</strong></p>
     521<p><strong>&lt;?php get_archives() ?&gt;</strong></p>
     522<div class="params">Parameters for <strong>get_archives()</strong>:
     523  <ul>
     524    <li>archivetype: 'postbypost', 'daily', 'weekly', or 'monthly' (default is to use the archive_mode setting from the admin interface)</li>
     525    <li>limit: how many archive links to display (default is to show all)</li>
     526    <li>format:
     527      <ul>
     528        <li>'html': create as &lt;li&gt; items for an HTML list (default)</li>
     529        <li>'option': create option values for a &lt;select&gt; dropdown menu</li>
     530        <li>'link': create &lt;link&gt; elements for the &lt;head&gt; section of a page</li>
     531        <li>'custom': use before and after values to format links</li>
     532      </ul>
     533    </li>
     534    <li>before: text to prepend to link</li>
     535    <li>after: text to append to link</li>
     536    <li>0 or 1: 1 means to display link counts</li>
     537  </ul>
     538</div>
     539<br />
     540<p><strong>To include the calendar:</strong></p>
    522541<p><strong>&lt;?php include("b2calendar.php") ?&gt;</strong><br />
    523542  this will include a table with the current month's calendar, each day when you posted shows a link to this day's posts. You can customise this table with CSS classes: </p>
Note: See TracChangeset for help on using the changeset viewer.