| 162 | | <blockquote> <strong><?php the_date() ?></strong> <span style="font-family: 'Courier New',Courrier,mono; color: #ff9900; font-weight: bold;">*</span><br /> |
|---|
| 163 | | the date of the post. example: 03.07.01 (default is dd.mm.yy).<br /> |
|---|
| 164 | | the date is displayed only on new days. for example if you got 10 posts |
|---|
| 165 | | on the same day, the date for this day is displayed only once.<br /> |
|---|
| 166 | | <div class="params">Parameters: |
|---|
| 167 | | <ul> |
|---|
| 168 | | <li>format string (default: "d.m.y")</li> |
|---|
| 169 | | <li>string to display before the date (default is blank)</li> |
|---|
| 170 | | <li>string to display after the date (default is blank)</li> |
|---|
| 171 | | </ul> |
|---|
| 172 | | </div> |
|---|
| 173 | | <br /> |
|---|
| 174 | | <strong><?php the_time() ?></strong><br /> |
|---|
| 175 | | the time of the post. example: 18:37:00 (default is hh:mm:ss)<br /> |
|---|
| 176 | | <div class="params">Parameters: |
|---|
| 177 | | <ul> |
|---|
| 178 | | <li>format string (default: "H:i:s")</li> |
|---|
| 179 | | </ul> |
|---|
| 180 | | </div> |
|---|
| 181 | | <br /> |
|---|
| 182 | | <strong>Note:</strong> you can change the way the date & time are |
|---|
| 183 | | displayed in the Options page.<br /> |
|---|
| 184 | | once you understand the format strings for the date & time (explained |
|---|
| 185 | | in the Options page), you can change the display right on the template: |
|---|
| 186 | | for example, <strong>the_date(</strong><em>"d.m.Y"</em><strong>)</strong> |
|---|
| 187 | | to have dates like 25.12.2001, <strong>the_time(</strong><em>"B"</em><strong>)</strong> |
|---|
| 188 | | to have Swatch Internet Time.<br /> |
|---|
| 189 | | If you change the display of the date on the template, changing it from |
|---|
| 190 | | the options page won't have any effect.br /> <br /> |
|---|
| 191 | | <strong>Note about the_date():</strong> if you want all your posts to |
|---|
| 192 | | bear the date, you'll have to use the_time() instead, with a date format |
|---|
| 193 | | string. for example, to have all your posts show like "25.12.2001 |
|---|
| 194 | | @ 8:04:50 AM" you'll have the_time("d.m.Y @ g:i:s A"). |
|---|
| 195 | | you can also repeat this template tag 2 times with 2 different formats: |
|---|
| 196 | | the_time("d.m.Y") for the date, and then later the_time("g:i:s |
|---|
| 197 | | A") for the time of the day.<br /> |
|---|
| 198 | | <br /> |
|---|
| 199 | | <strong><?php the_weekday() ?></strong><br /> |
|---|
| 200 | | This displays the day of the week when the post was made. It works like |
|---|
| 201 | | the_time(), in that it would appear at every post. Weekdays can be obtained |
|---|
| 202 | | with a custom date format string in the_time() or the_date(), but for |
|---|
| 203 | | non-english weekdays you have to edit day-month-trans.php<br /> |
|---|
| 204 | | <strong>Note: this tag is OBSOLETE, the_time() and the_date() now use |
|---|
| 205 | | weekdays/months from day-month-trans.php</strong><br /> |
|---|
| 206 | | <br /> |
|---|
| 207 | | <strong><?php the_weekday_date() ?></strong> <span style="font-family: Courier New, Courrier, mono; color: #ff9900; font-weight:bold;">*</span><br /> |
|---|
| 208 | | Like the_weekday(), but works like the_date(), in that it would appear |
|---|
| 209 | | only on new days.<br /> |
|---|
| 210 | | <strong>Note: this tag is OBSOLETE, the_time() and the_date() now use |
|---|
| 211 | | weekdays/months from day-month-trans.php</strong><br /> |
|---|
| 212 | | <div class="params">Parameters: |
|---|
| 213 | | <ul> |
|---|
| 214 | | <li>string to display before the weekday_date (default is blank)</li> |
|---|
| 215 | | <li>string to display after the weekday_date (default is blank)</li> |
|---|
| 216 | | </ul> |
|---|
| 217 | | </div> |
|---|
| 218 | | <br /> |
|---|
| 219 | | <br /> |
|---|
| 220 | | <strong><?php the_ID() ?><br /> |
|---|
| 221 | | </strong>the ID (number) of the post.<br /> |
|---|
| 222 | | <br /> |
|---|
| 223 | | <strong><?php the_title() ?><br /> |
|---|
| 224 | | </strong>The title of the post.<br /> |
|---|
| 225 | | <div class="params">Parameters: |
|---|
| 226 | | <ul> |
|---|
| 227 | | <li>string to display before the title (default is blank)</li> |
|---|
| 228 | | <li>string to display after the title (default is blank)</li> |
|---|
| 229 | | </ul> |
|---|
| 230 | | </div> |
|---|
| 231 | | <br /> |
|---|
| 232 | | <br /> |
|---|
| 233 | | <strong><?php the_content() ?> <span style="font-family: Courier New, Courrier, mono; color: #ff9900; font-weight:bold;">*</span><br /> |
|---|
| 234 | | </strong>The text of the post.<br /> |
|---|
| 235 | | <div class="params">Parameters: |
|---|
| 236 | | <ul> |
|---|
| 237 | | <li>text to display for the link to the complete entry (default is |
|---|
| 238 | | <em>'(more...)'</em>)</li> |
|---|
| 239 | | <li>0 or 1, whether you want to show the teaser message or not, when |
|---|
| 240 | | showing the complete text (default is 1)</li> |
|---|
| 241 | | <li>a filename of another template, if you want the 'more' link to |
|---|
| 242 | | link to a different template for the complete text of the extended |
|---|
| 243 | | entry (default is the current template)</li> |
|---|
| 244 | | </ul> |
|---|
| 245 | | </div> |
|---|
| 246 | | <br /> |
|---|
| 247 | | For example <em><?php the_content("read more","0","blah.php") |
|---|
| 248 | | ?></em> would display a link to <em>blah.php</em>, with the link text |
|---|
| 249 | | <em>read more</em>, and won't display the teaser message.<br /> |
|---|
| 250 | | <br /> |
|---|
| 251 | | <span style="font-family: Courier New, Courrier, mono; color: #ff9900; font-weight:bold;">*</span> |
|---|
| 252 | | To enter an extended entry, just type <em><!--more--></em> in your |
|---|
| 253 | | entry. The part before that comment is the teaser, the part after it is |
|---|
| 254 | | the extended entry. To force the extended entry not to show the teaser |
|---|
| 255 | | message, type <em><!--noteaser--></em> somewhere in your entry.<br /> |
|---|
| 256 | | <br /> |
|---|
| 257 | | <span style="font-family: Courier New, Courrier, mono; color: #ff9900; font-weight:bold;">*</span> |
|---|
| 258 | | To enter an entry with several pages, just type <em><!--nextpage--></em> |
|---|
| 259 | | in your entry to start a new page.<br /> |
|---|
| 260 | | <br /> |
|---|
| 261 | | <br /> |
|---|
| 262 | | <strong><?php next_post() ?> <span style="font-family: Courier New, Courrier, mono; color: #ff9900; font-weight:bold;">*</span><br /> |
|---|
| 263 | | </strong>Displays a link to the next post(s). (Generally you might want |
|---|
| 264 | | to use that tag only in single-post templates)<br /> |
|---|
| 265 | | <div class="params">Parameters: |
|---|
| 266 | | <ul> |
|---|
| 267 | | <li>format string for the link (default is "%", where % is replaced |
|---|
| 268 | | with the title of the next post)</li> |
|---|
| 269 | | <li>text to display to announce the link (default is "next post: ")</li> |
|---|
| 270 | | <li>"yes" or "no": display the title of the post, or no (default is |
|---|
| 271 | | "yes")</li> |
|---|
| 272 | | <li>"yes" or "no": display a link to the next post only if the next |
|---|
| 273 | | post is in the same category (default is "no")</li> |
|---|
| 274 | | <li>number: which next post ? if you make it '2', the 2nd next post |
|---|
| 275 | | is linked instead of the 1st next one (default is "1", which means |
|---|
| 276 | | first next post)</li> |
|---|
| 277 | | </ul> |
|---|
| 278 | | </div> |
|---|
| 279 | | <br /> |
|---|
| 280 | | <br /> |
|---|
| 281 | | <strong><?php previous_post() ?> <span style="font-family: Courier New, Courrier, mono; color: #ff9900; font-weight:bold;">*</span><br /> |
|---|
| 282 | | </strong>Displays a link to the previous post(s). (Generally you might |
|---|
| 283 | | want to use that tag only in single-post templates)<br /> |
|---|
| 284 | | <div class="params">Parameters: |
|---|
| 285 | | <ul> |
|---|
| 286 | | <li>format string for the link (default is "%", where % is replaced |
|---|
| 287 | | with the title of the previous post)</li> |
|---|
| 288 | | <li>text to display to announce the link (default is "previous post: |
|---|
| 289 | | ")</li> |
|---|
| 290 | | <li>"yes" or "no": display the title of the post, or no (default is |
|---|
| 291 | | "yes")</li> |
|---|
| 292 | | <li>"yes" or "no": display a link to the next post only if the previous |
|---|
| 293 | | post is in the same category (default is "no")</li> |
|---|
| 294 | | <li>number: which previous post ? if you make it '2', the 2nd previous |
|---|
| 295 | | post is linked instead of the 1st previous post (default is "1", |
|---|
| 296 | | which means first previous post)</li> |
|---|
| 297 | | </ul> |
|---|
| 298 | | </div> |
|---|
| 299 | | <br /> |
|---|
| 300 | | <br /> |
|---|
| 301 | | <strong><?php next_posts() ?> <span style="font-family: Courier New, Courrier, mono; color: #ff9900; font-weight:bold;">*</span><br /> |
|---|
| 302 | | </strong>Display the URL portion of a link to the next set of posts. <br /> |
|---|
| 303 | | Generally you would use this in a template to navigate to the next "set" |
|---|
| 304 | | of posts when the "Show Options" settings for the site is set to "posts |
|---|
| 305 | | paged". The displayed string can be used to construct a link. When the |
|---|
| 306 | | site options are not set to 'posts paged", the next and previous functions |
|---|
| 307 | | will display nothing.<br /> |
|---|
| 308 | | <div class="params">Parameters: |
|---|
| 309 | | <ul> |
|---|
| 310 | | <li>Max page number to use. Default "0"; no limit</li> |
|---|
| 311 | | </ul> |
|---|
| 312 | | </div> |
|---|
| 313 | | <br /> |
|---|
| 314 | | <br /> |
|---|
| 315 | | <strong><?php next_posts_link() ?> <span style="font-family: Courier New, Courrier, mono; color: #ff9900; font-weight:bold;">*</span><br /> |
|---|
| 316 | | </strong> Displays a full link to the next "set" of posts only if show |
|---|
| 317 | | options set to "posts paged" and only if there is another page or partial |
|---|
| 318 | | page of data.<br /> |
|---|
| 319 | | <div class="params">Parameters: |
|---|
| 320 | | <ul> |
|---|
| 321 | | <li>A user supplied string. Default "Next Page >>"</li> |
|---|
| 322 | | </ul> |
|---|
| 323 | | </div> |
|---|
| 324 | | <br /> |
|---|
| 325 | | <br /> |
|---|
| 326 | | <strong><?php previous_posts() ?> <span style="font-family: Courier New, Courrier, mono; color: #ff9900; font-weight:bold;">*</span><br /> |
|---|
| 327 | | </strong>Displays the URL portion of a link to the previous posts.<br /> |
|---|
| 328 | | Generally you would use this in a template to navigate to the previous |
|---|
| 329 | | "set" of posts when the "Show Options" settings for the site is set to |
|---|
| 330 | | "posts paged". The displayed string can then be used to construct a link. |
|---|
| 331 | | When the site options are not set to 'posts paged", the next and previous |
|---|
| 332 | | functions will display nothing.<br /> |
|---|
| 333 | | <div class="params">Parameters: |
|---|
| 334 | | <ul> |
|---|
| 335 | | <li>No parameters.</li> |
|---|
| 336 | | </ul> |
|---|
| 337 | | </div> |
|---|
| 338 | | <br /> |
|---|
| 339 | | <br /> |
|---|
| 340 | | <strong><?php previous_posts_link() ?> <span style="font-family: Courier New, Courrier, mono; color: #ff9900; font-weight:bold;">*</span><br /> |
|---|
| 341 | | </strong> Displays a full link to the previous "set" of posts only if |
|---|
| 342 | | show options set to "posts paged" and if there is a previous set, otherwise |
|---|
| 343 | | nothing is displayed.<br /> |
|---|
| 344 | | <div class="params">Parameters: |
|---|
| 345 | | <ul> |
|---|
| 346 | | <li>A user supplied string. Default "<< Previous Page"</li> |
|---|
| 347 | | </ul> |
|---|
| 348 | | </div> |
|---|
| 349 | | <br /> |
|---|
| 350 | | <br /> |
|---|
| 351 | | <strong><?php posts_nav_link() ?> <span style="font-family: Courier New, Courrier, mono; color: #ff9900; font-weight:bold;">*</span><br /> |
|---|
| 352 | | </strong>The function displays a complete navigation set of links including |
|---|
| 353 | | a user definable "separator" with the ability to supply a the text string |
|---|
| 354 | | to be used for the "previous" and "next" links.<br /> |
|---|
| 355 | | The default result will produce the following string:<br /> |
|---|
| | 175 | <blockquote> <strong><?php the_date() ?></strong> <span |
|---|
| | 176 | style="font-family: 'Courier New',Courrier,mono; color: rgb(255, 153, 0); font-weight: bold;">*</span><br> |
|---|
| | 177 | the date of the post. example: 03.07.01 (default is dd.mm.yy).<br> |
|---|
| | 178 | the date is displayed only on new days. for example if you got 10 posts |
|---|
| | 179 | on the same day, the date for this day is displayed only once.<br> |
|---|
| | 180 | <div class="params">Parameters: |
|---|
| | 181 | <ul> |
|---|
| | 182 | <li>format string (default: "d.m.y")</li> |
|---|
| | 183 | <li>string to display before the date (default is blank)</li> |
|---|
| | 184 | <li>string to display after the date (default is blank)</li> |
|---|
| | 185 | </ul> |
|---|
| | 186 | </div> |
|---|
| | 187 | <br> |
|---|
| | 188 | <strong><?php the_time() ?></strong><br> |
|---|
| | 189 | the time of the post. example: 18:37:00 (default is hh:mm:ss)<br> |
|---|
| | 190 | <div class="params">Parameters: |
|---|
| | 191 | <ul> |
|---|
| | 192 | <li>format string (default: "H:i:s")</li> |
|---|
| | 193 | </ul> |
|---|
| | 194 | </div> |
|---|
| | 195 | <br> |
|---|
| | 196 | <strong>Note:</strong> you can change the way the date & |
|---|
| | 197 | time are displayed in the Options page.<br> |
|---|
| | 198 | once you understand the format strings for the date & time |
|---|
| | 199 | (explained in the Options page), you can change the display right on |
|---|
| | 200 | the template: for example, <strong>the_date(</strong><em>"d.m.Y"</em><strong>)</strong> |
|---|
| | 201 | to have dates like 25.12.2001, <strong>the_time(</strong><em>"B"</em><strong>)</strong> |
|---|
| | 202 | to have Swatch Internet Time.<br> |
|---|
| | 203 | If you change the display of the date on the template, changing it from |
|---|
| | 204 | the options page won't have any effect.br /> <br> |
|---|
| | 205 | <strong>Note about the_date():</strong> if you want all your |
|---|
| | 206 | posts to bear the date, you'll have to use the_time() instead, with a |
|---|
| | 207 | date format string. for example, to have all your posts show like |
|---|
| | 208 | "25.12.2001 @ 8:04:50 AM" you'll have the_time("d.m.Y @ g:i:s A"). you |
|---|
| | 209 | can also repeat this template tag 2 times with 2 different formats: |
|---|
| | 210 | the_time("d.m.Y") for the date, and then later the_time("g:i:s A") for |
|---|
| | 211 | the time of the day.<br> |
|---|
| | 212 | <br> |
|---|
| | 213 | <strong><?php the_weekday() ?></strong><br> |
|---|
| | 214 | This displays the day of the week when the post was made. It works like |
|---|
| | 215 | the_time(), in that it would appear at every post. Weekdays can be |
|---|
| | 216 | obtained with a custom date format string in the_time() or the_date(), |
|---|
| | 217 | but for non-english weekdays you have to edit day-month-trans.php<br> |
|---|
| | 218 | <strong>Note: this tag is OBSOLETE, the_time() and the_date() |
|---|
| | 219 | now use weekdays/months from day-month-trans.php</strong><br> |
|---|
| | 220 | <br> |
|---|
| | 221 | <strong><?php the_weekday_date() ?></strong> <span |
|---|
| | 222 | style="font-family: Courier New,Courrier,mono; color: rgb(255, 153, 0); font-weight: bold;">*</span><br> |
|---|
| | 223 | Like the_weekday(), but works like the_date(), in that it would appear |
|---|
| | 224 | only on new days.<br> |
|---|
| | 225 | <strong>Note: this tag is OBSOLETE, the_time() and the_date() |
|---|
| | 226 | now use weekdays/months from day-month-trans.php</strong><br> |
|---|
| | 227 | <div class="params">Parameters: |
|---|
| | 228 | <ul> |
|---|
| | 229 | <li>string to display before the weekday_date (default is |
|---|
| | 230 | blank)</li> |
|---|
| | 231 | <li>string to display after the weekday_date (default is |
|---|
| | 232 | blank)</li> |
|---|
| | 233 | </ul> |
|---|
| | 234 | </div> |
|---|
| | 235 | <br> |
|---|
| | 236 | <br> |
|---|
| | 237 | <strong><?php the_ID() ?><br> |
|---|
| | 238 | </strong>the ID (number) of the post.<br> |
|---|
| | 239 | <br> |
|---|
| | 240 | <strong><?php the_title() ?><br> |
|---|
| | 241 | </strong>The title of the post.<br> |
|---|
| | 242 | <div class="params">Parameters: |
|---|
| | 243 | <ul> |
|---|
| | 244 | <li>string to display before the title (default is blank)</li> |
|---|
| | 245 | <li>string to display after the title (default is blank)</li> |
|---|
| | 246 | </ul> |
|---|
| | 247 | </div> |
|---|
| | 248 | <br> |
|---|
| | 249 | <br> |
|---|
| | 250 | <strong><?php the_content() ?> <span |
|---|
| | 251 | style="font-family: Courier New,Courrier,mono; color: rgb(255, 153, 0); font-weight: bold;">*</span><br> |
|---|
| | 252 | </strong>The text of the post.<br> |
|---|
| | 253 | <div class="params">Parameters: |
|---|
| | 254 | <ul> |
|---|
| | 255 | <li>text to display for the link to the complete entry |
|---|
| | 256 | (default is <em>'(more...)'</em>)</li> |
|---|
| | 257 | <li>0 or 1, whether you want to show the teaser message or |
|---|
| | 258 | not, when showing the complete text (default is 1)</li> |
|---|
| | 259 | <li>a filename of another template, if you want the 'more' |
|---|
| | 260 | link to link to a different template for the complete text of the |
|---|
| | 261 | extended entry (default is the current template)</li> |
|---|
| | 262 | </ul> |
|---|
| | 263 | </div> |
|---|
| | 264 | <br> |
|---|
| | 265 | For example <em><?php the_content("read more","0","blah.php") ?></em> |
|---|
| | 266 | would display a link to <em>blah.php</em>, with the link text <em>read |
|---|
| | 267 | more</em>, and won't display the teaser message.<br> |
|---|
| | 268 | <br> |
|---|
| | 269 | <span |
|---|
| | 270 | style="font-family: Courier New,Courrier,mono; color: rgb(255, 153, 0); font-weight: bold;">*</span> |
|---|
| | 271 | To enter an extended entry, just type <em><!--more--></em> in |
|---|
| | 272 | your entry. The part before that comment is the teaser, the part after |
|---|
| | 273 | it is the extended entry. To force the extended entry not to show the |
|---|
| | 274 | teaser message, type <em><!--noteaser--></em> somewhere in your |
|---|
| | 275 | entry.<br> |
|---|
| | 276 | <br> |
|---|
| | 277 | <span |
|---|
| | 278 | style="font-family: Courier New,Courrier,mono; color: rgb(255, 153, 0); font-weight: bold;">*</span> |
|---|
| | 279 | To enter an entry with several pages, just type <em><!--nextpage--></em> |
|---|
| | 280 | in your entry to start a new page.<br> |
|---|
| | 281 | <br> |
|---|
| | 282 | <br> |
|---|
| | 283 | <strong><?php next_post() ?> <span |
|---|
| | 284 | style="font-family: Courier New,Courrier,mono; color: rgb(255, 153, 0); font-weight: bold;">*</span><br> |
|---|
| | 285 | </strong>Displays a link to the next post(s). (Generally you |
|---|
| | 286 | might want to use that tag only in single-post templates)<br> |
|---|
| | 287 | <div class="params">Parameters: |
|---|
| | 288 | <ul> |
|---|
| | 289 | <li>format string for the link (default is "%", where % is |
|---|
| | 290 | replaced with the title of the next post)</li> |
|---|
| | 291 | <li>text to display to announce the link (default is "next |
|---|
| | 292 | post: ")</li> |
|---|
| | 293 | <li>"yes" or "no": display the title of the post, or no |
|---|
| | 294 | (default is "yes")</li> |
|---|
| | 295 | <li>"yes" or "no": display a link to the next post only if |
|---|
| | 296 | the next post is in the same category (default is "no")</li> |
|---|
| | 297 | <li>number: which next post ? if you make it '2', the 2nd |
|---|
| | 298 | next post is linked instead of the 1st next one (default is "1", which |
|---|
| | 299 | means first next post)</li> |
|---|
| | 300 | </ul> |
|---|
| | 301 | </div> |
|---|
| | 302 | <br> |
|---|
| | 303 | <br> |
|---|
| | 304 | <strong><?php previous_post() ?> <span |
|---|
| | 305 | style="font-family: Courier New,Courrier,mono; color: rgb(255, 153, 0); font-weight: bold;">*</span><br> |
|---|
| | 306 | </strong>Displays a link to the previous post(s). (Generally |
|---|
| | 307 | you might want to use that tag only in single-post templates)<br> |
|---|
| | 308 | <div class="params">Parameters: |
|---|
| | 309 | <ul> |
|---|
| | 310 | <li>format string for the link (default is "%", where % is |
|---|
| | 311 | replaced with the title of the previous post)</li> |
|---|
| | 312 | <li>text to display to announce the link (default is |
|---|
| | 313 | "previous post: ")</li> |
|---|
| | 314 | <li>"yes" or "no": display the title of the post, or no |
|---|
| | 315 | (default is "yes")</li> |
|---|
| | 316 | <li>"yes" or "no": display a link to the next post only if |
|---|
| | 317 | the previous post is in the same category (default is "no")</li> |
|---|
| | 318 | <li>number: which previous post ? if you make it '2', the 2nd |
|---|
| | 319 | previous post is linked instead of the 1st previous post (default is |
|---|
| | 320 | "1", which means first previous post)</li> |
|---|
| | 321 | </ul> |
|---|
| | 322 | </div> |
|---|
| | 323 | <br> |
|---|
| | 324 | <br> |
|---|
| | 325 | <strong><?php next_posts() ?> <span |
|---|
| | 326 | style="font-family: Courier New,Courrier,mono; color: rgb(255, 153, 0); font-weight: bold;">*</span><br> |
|---|
| | 327 | </strong>Display the URL portion of a link to the next set of |
|---|
| | 328 | posts. <br> |
|---|
| | 329 | Generally you would use this in a template to navigate to the next |
|---|
| | 330 | "set" of posts when the "Show Options" settings for the site is set to |
|---|
| | 331 | "posts paged". The displayed string can be used to construct a link. |
|---|
| | 332 | When the site options are not set to 'posts paged", the next and |
|---|
| | 333 | previous functions will display nothing.<br> |
|---|
| | 334 | <div class="params">Parameters: |
|---|
| | 335 | <ul> |
|---|
| | 336 | <li>Max page number to use. Default "0"; no limit</li> |
|---|
| | 337 | </ul> |
|---|
| | 338 | </div> |
|---|
| | 339 | <br> |
|---|
| | 340 | <br> |
|---|
| | 341 | <strong><?php next_posts_link() ?> <span |
|---|
| | 342 | style="font-family: Courier New,Courrier,mono; color: rgb(255, 153, 0); font-weight: bold;">*</span><br> |
|---|
| | 343 | </strong> Displays a full link to the next "set" of posts only |
|---|
| | 344 | if show options set to "posts paged" and only if there is another page |
|---|
| | 345 | or partial page of data.<br> |
|---|
| | 346 | <div class="params">Parameters: |
|---|
| | 347 | <ul> |
|---|
| | 348 | <li>A user supplied string. Default "Next Page >>"</li> |
|---|
| | 349 | </ul> |
|---|
| | 350 | </div> |
|---|
| | 351 | <br> |
|---|
| | 352 | <br> |
|---|
| | 353 | <strong><?php previous_posts() ?> <span |
|---|
| | 354 | style="font-family: Courier New,Courrier,mono; color: rgb(255, 153, 0); font-weight: bold;">*</span><br> |
|---|
| | 355 | </strong>Displays the URL portion of a link to the previous |
|---|
| | 356 | posts.<br> |
|---|
| | 357 | Generally you would use this in a template to navigate to the previous |
|---|
| | 358 | "set" of posts when the "Show Options" settings for the site is set to |
|---|
| | 359 | "posts paged". The displayed string can then be used to construct a |
|---|
| | 360 | link. When the site options are not set to 'posts paged", the next and |
|---|
| | 361 | previous functions will display nothing.<br> |
|---|
| | 362 | <div class="params">Parameters: |
|---|
| | 363 | <ul> |
|---|
| | 364 | <li>No parameters.</li> |
|---|
| | 365 | </ul> |
|---|
| | 366 | </div> |
|---|
| | 367 | <br> |
|---|
| | 368 | <br> |
|---|
| | 369 | <strong><?php previous_posts_link() ?> <span |
|---|
| | 370 | style="font-family: Courier New,Courrier,mono; color: rgb(255, 153, 0); font-weight: bold;">*</span><br> |
|---|
| | 371 | </strong> Displays a full link to the previous "set" of posts |
|---|
| | 372 | only if show options set to "posts paged" and if there is a previous |
|---|
| | 373 | set, otherwise nothing is displayed.<br> |
|---|
| | 374 | <div class="params">Parameters: |
|---|
| | 375 | <ul> |
|---|
| | 376 | <li>A user supplied string. Default "<< Previous Page"</li> |
|---|
| | 377 | </ul> |
|---|
| | 378 | </div> |
|---|
| | 379 | <br> |
|---|
| | 380 | <br> |
|---|
| | 381 | <strong><?php posts_nav_link() ?> <span |
|---|
| | 382 | style="font-family: Courier New,Courrier,mono; color: rgb(255, 153, 0); font-weight: bold;">*</span><br> |
|---|
| | 383 | </strong>The function displays a complete navigation set of |
|---|
| | 384 | links including a user definable "separator" with the ability to supply |
|---|
| | 385 | a the text string to be used for the "previous" and "next" links.<br> |
|---|
| | 386 | The default result will produce the following string:<br> |
|---|
| 357 | | <div class="params">Parameters: |
|---|
| 358 | | <ul> |
|---|
| 359 | | <li>A user supplied "separator" string. Default " :: "</li> |
|---|
| 360 | | <li>A user supplied "previous" string. Default "<< Previous |
|---|
| 361 | | Page"</li> |
|---|
| 362 | | <li>A user supplied "next" string. Default "Next Page >>"</li> |
|---|
| 363 | | </ul> |
|---|
| 364 | | </div> |
|---|
| 365 | | <br /> |
|---|
| 366 | | <br /> |
|---|
| 367 | | <strong><?php link_pages() ?> <span style="font-family: Courier New, Courrier, mono; color: #ff9900; font-weight:bold;">*</span><br /> |
|---|
| 368 | | </strong>Displays links to the pages of the post if it's a multiple pages |
|---|
| 369 | | post.<br /> |
|---|
| 370 | | <div class="params">Parameters: |
|---|
| 371 | | <ul> |
|---|
| 372 | | <li>string to display before the tag (default is "<br />", a newline)</li> |
|---|
| 373 | | <li>string to display after the tag (default is "<br />", a newline)</li> |
|---|
| 374 | | <li>"next" or "number": display links like "next/previous page" or |
|---|
| 375 | | links to each page with the number of the page "1 2 3 4 etc" (default |
|---|
| 376 | | is "number")</li> |
|---|
| 377 | | <li>string to display the "next page" link (default is "next page")</li> |
|---|
| 378 | | <li>string to display the "previous page" link (default is "previous |
|---|
| 379 | | page")</li> |
|---|
| 380 | | <li>format string for the "number of page" link (default is "%", where |
|---|
| 381 | | % is replaced by the number of the page)</li> |
|---|
| 382 | | <li>file name, in case you want to load the posts with multiple pages |
|---|
| 383 | | in a different template (default is the current template)</li> |
|---|
| 384 | | </ul> |
|---|
| 385 | | </div> |
|---|
| 386 | | <br /> |
|---|
| 387 | | <br /> |
|---|
| 388 | | <strong><?php the_author() ?></strong><br /> |
|---|
| 389 | | The author of the post.<br /> |
|---|
| 390 | | Depending on the user's profile settings, it can display whether their |
|---|
| 391 | | nickname, login name, first name, last name, both first& last name, |
|---|
| 392 | | or last & first name. look below for more author-related template |
|---|
| 393 | | tags. <br /> |
|---|
| 394 | | <br /> |
|---|
| 395 | | <strong><?php the_category() ?><br /> |
|---|
| 396 | | </strong>the name of the category the post belongs to. you can as an admin |
|---|
| 397 | | add categories, and rename them if needed. default category is 'General', |
|---|
| 398 | | you can rename it too.<br /> |
|---|
| 399 | | <br /> |
|---|
| 400 | | <strong><?php the_category_ID() ?><br /> |
|---|
| 401 | | </strong>The ID (number) of the category the post belongs to. This is |
|---|
| 402 | | static data thatyou can use, for example to associate a category to an |
|---|
| 403 | | image, or a css style.<br /> |
|---|
| 404 | | <br /> |
|---|
| 405 | | <strong><?php trackback_rdf() ?> <span style="font-family: Courier New, Courrier, mono; color: #ff9900; font-weight:bold;">*</span></strong><br /> |
|---|
| 406 | | This will include the RDF data that can be used by some weblog tools to |
|---|
| 407 | | locate your posts' trackback URLs.<br /> |
|---|
| 408 | | You should put this tag after the <?php the_content() ?> tag in |
|---|
| 409 | | your template, or just before the end of the loop.<br /> |
|---|
| 410 | | <br /> |
|---|
| 411 | | <strong><?php dropdown_cats() ?><br /> |
|---|
| 412 | | </strong>this is a special tag, meant to be used in the template, but |
|---|
| 413 | | outside of the b2 loop. it will display a list of <option name="<em>x</em>"><em>category-name</em></option>, |
|---|
| 414 | | where <em>x</em> is the number of the category and <em>category-name</em> |
|---|
| 415 | | is the name of it.<br /> |
|---|
| 416 | | <div class="params">Parameters: |
|---|
| 417 | | <ul> |
|---|
| 418 | | <li>0 or 1, depending if you want to have an option to display all |
|---|
| 419 | | categories (default is 1)</li> |
|---|
| 420 | | <li>text to display for the option to show all categories (default |
|---|
| 421 | | is "All")</li> |
|---|
| 422 | | </ul> |
|---|
| 423 | | </div> |
|---|
| 424 | | <br /> |
|---|
| 425 | | you can use it like this: <br /> |
|---|
| 426 | | <br /> |
|---|
| 427 | | <code><form action="<?php echo $PHP_SELF ?>" method="get"><br /> |
|---|
| 428 | | <?php dropdown_cats() ?><br /> |
|---|
| 429 | | <input type="submit" name="submit" value="view" /><br /> |
|---|
| 430 | | </form></code> <br /> |
|---|
| 431 | | <br /> |
|---|
| 432 | | <strong><?php list_cats() ?> <span style="font-family: Courier New, Courrier, mono; color: #ff9900; font-weight:bold;">*</span><br /> |
|---|
| 433 | | </strong>this is a special tag, meant to be used in the template, but |
|---|
| 434 | | outside of the b2 loop. it will display a list of the categories, with |
|---|
| 435 | | links to them. like in b2archive.php, each category is on a line, the |
|---|
| 436 | | only way you can change this is by editing b2.template.functions.php<br /> |
|---|
| 437 | | <div class="params">Parameters: |
|---|
| 438 | | <ul> |
|---|
| 439 | | <li>0 or 1, depending if you want to have an option to display all |
|---|
| 440 | | categories (default is 1)</li> |
|---|
| 441 | | <li>text to display for the option to show all categories (default |
|---|
| 442 | | is 'All')</li> |
|---|
| 443 | | <li>sort by: possible values are 'name' and 'ID' (default is 'ID')</li> |
|---|
| 444 | | <li>sorting order: possible values are 'asc' for ascending or 'desc' |
|---|
| 445 | | for descending (default is 'asc')</li> |
|---|
| 446 | | <li>filename, in case you want to display the categories' posts in |
|---|
| 447 | | another template (default is current template)</li> |
|---|
| 448 | | </ul> |
|---|
| 449 | | </div> |
|---|
| 450 | | <br /> |
|---|
| 451 | | <strong><?php bloginfo() ?></strong> <span style="font-family: 'Courier New',Courrier,mono; color: #ff9900; font-weight: bold;">*</span><br /> |
|---|
| 452 | | This tag is out of the b2 loop.<br /> |
|---|
| 453 | | It outputs info about your weblog.<br /> |
|---|
| 454 | | <div class="params">Parameters: |
|---|
| 455 | | <ul> |
|---|
| 456 | | <li>string: can be 'name' to display the name of your weblog (you |
|---|
| 457 | | set it in the options page), 'url', 'description', 'admin_email', 'rss_url' |
|---|
| 458 | | to display the URL of your b2rss.xml file, 'pingback_url' to display |
|---|
| 459 | | the URL of your xmlrpc.php file<br /> |
|---|
| 460 | | (default string is 'name')</li> |
|---|
| 461 | | </ul> |
|---|
| 462 | | </div> |
|---|
| 463 | | <br /> |
|---|
| 464 | | <strong><?php single_post_title() ?></strong> <span style="font-family: 'Courier New',Courrier,mono; color: #ff9900; font-weight: bold;">*</span><br /> |
|---|
| 465 | | This tag is out of the b2 loop.<br /> |
|---|
| 466 | | It outputs the title of the post when you load the page with ?p= (see |
|---|
| 467 | | 'Usage' section for explanation). When the weblog page is loaded without |
|---|
| 468 | | ?p=, this tag doesn't display anything. Generally, you could use it like |
|---|
| 469 | | this:<br /> |
|---|
| 470 | | <title><?php bloginfo('name') ?><?php single_post_title() |
|---|
| 471 | | ?></title><br /> |
|---|
| 472 | | <div class="params">Parameters: |
|---|
| 473 | | <ul> |
|---|
| 474 | | <li>prefix string that will appear before the post's title (default |
|---|
| 475 | | is ' :: ')</li> |
|---|
| 476 | | </ul> |
|---|
| 477 | | </div> |
|---|
| 478 | | <br /> |
|---|
| 479 | | <strong><?php single_cat_title() ?></strong> <span style="font-family: 'Courier New',Courrier,mono; color: #ff9900; font-weight: bold;">*</span><br /> |
|---|
| 480 | | This tag is out of the b2 loop.<br /> |
|---|
| 481 | | It outputs the title of the category when you load the page with ?cat= |
|---|
| 482 | | (see 'Usage' section for explanation). When the weblog page is loaded |
|---|
| 483 | | without ?cat=, this tag doesn't display anything. Generally, you could |
|---|
| 484 | | use it like this:<br /> |
|---|
| 485 | | <title><?php bloginfo('name') ?><?php single_cat_title() |
|---|
| 486 | | ?></title><br /> |
|---|
| 487 | | <div class="params">Parameters: |
|---|
| 488 | | <ul> |
|---|
| 489 | | <li>prefix string that will appear before the category's title (default |
|---|
| 490 | | is ' :: ')</li> |
|---|
| 491 | | </ul> |
|---|
| 492 | | </div> |
|---|
| 493 | | <br /> |
|---|
| 494 | | <strong><?php single_month_title() ?></strong> <span style="font-family: 'Courier New',Courrier,mono; color: #ff9900; font-weight: bold;">*</span><br /> |
|---|
| 495 | | This tag is out of the b2 loop.<br /> |
|---|
| 496 | | It outputs the name of the month when you load the page with ?m= (see |
|---|
| 497 | | 'Usage' section for explanation). When the weblog page is loaded without |
|---|
| 498 | | ?m=, this tag doesn't display anything. Generally, you could use it like |
|---|
| 499 | | this:<br /> |
|---|
| 500 | | <title><?php bloginfo('name') ?><?php single_month_title() |
|---|
| 501 | | ?></title><br /> |
|---|
| 502 | | <div class="params">Parameters: |
|---|
| 503 | | <ul> |
|---|
| 504 | | <li>prefix string that will appear before the month's name (default |
|---|
| 505 | | is ' :: ')</li> |
|---|
| 506 | | </ul> |
|---|
| 507 | | </div> |
|---|
| 508 | | <br /> |
|---|
| 509 | | <strong>Note:</strong> The above three functions can be used together |
|---|
| 510 | | to produce the Title of the page:<br> |
|---|
| 511 | | <title><?php bloginfo('name') ?><?php single_post_title(' |
|---|
| 512 | | :: ') ?><?php single_cat_title(' :: ') ?><?php single_month_title(' |
|---|
| 513 | | :: ') ?></title><br /> |
|---|
| 514 | | Only one, if any, of these functions will produce output, thus the page |
|---|
| 515 | | Title can be customize to the task being done. <br /> |
|---|
| 516 | | <br /> |
|---|
| 517 | | <br /> |
|---|
| 518 | | <strong>More about the author</strong> of the post ? Here goes:<br /> |
|---|
| 519 | | <br /> |
|---|
| 520 | | <strong><?php the_author_email() ?> - </strong> the author's email.<br /> |
|---|
| 521 | | <strong><?php the_author_url() ?></strong> - the author's url.<br /> |
|---|
| 522 | | <strong><?php the_author_email() ?></strong> - the author's number |
|---|
| 523 | | of posts.<br /> |
|---|
| 524 | | <strong><?php the_author_icq() ?></strong> - the author's ICQ number.<br /> |
|---|
| 525 | | <strong><?php the_author_aim() ?></strong> - the author's AIM handle.<br /> |
|---|
| 526 | | <strong><?php the_author_yim() ?></strong> - the author's Yahoo |
|---|
| 527 | | Messenger handle.<br /> |
|---|
| 528 | | <strong><?php the_author_msn() ?></strong> - the author's MSN Messenger |
|---|
| 529 | | handle.<br /> |
|---|
| 530 | | <strong><?php the_author_posts() ?></strong> - the author's post |
|---|
| 531 | | count.<br /> |
|---|
| 532 | | <strong><?php the_author_login() ?></strong> - the author's login |
|---|
| 533 | | name in b2. If you want some static data about the author, this is what |
|---|
| 534 | | you're searching for. You can, for example, associate a picture with an |
|---|
| 535 | | author, like this: <em><img src="pictures/<?php the_author_login() |
|---|
| 536 | | ?>.jpg" border="0"></em><br /> |
|---|
| 537 | | <strong><?php the_author_ID() ?></strong> - the author's ID number |
|---|
| 538 | | in b2. This number is automatically set when the user registers: to see |
|---|
| 539 | | the ID of an user, go to the Team page. This is static data too, so you |
|---|
| 540 | | can use it like the_author_login() in associating stuff with authors.<br /> |
|---|
| 541 | | <br /> |
|---|
| 542 | | <strong><br /> |
|---|
| 543 | | Tags for permalinks</strong> are:<br /> |
|---|
| 544 | | <br /> |
|---|
| 545 | | <strong><?php permalink_anchor() ?> <span style="font-family: Courier New, Courrier, mono; color: #ff9900; font-weight:bold;">*</span></strong><br /> |
|---|
| 546 | | this will display <a name="..."></a>, replacing |
|---|
| 547 | | "..." with the ID or the title of the post in the database.<br /> |
|---|
| 548 | | <br /> |
|---|
| 549 | | <div class="params">Parameters: |
|---|
| 550 | | <ul> |
|---|
| 551 | | <li>string for kind of anchor: either 'id' that displays '50', or |
|---|
| 552 | | 'title' that displays 'title_of_post_50' (default is 'id')</li> |
|---|
| 553 | | </ul> |
|---|
| 554 | | </div> |
|---|
| 555 | | <br /> |
|---|
| 556 | | <strong><?php permalink_link() ?> <span style="font-family: Courier New, Courrier, mono; color: #ff9900; font-weight:bold;">*</span><br /> |
|---|
| 557 | | </strong>this will display the name of the file followed by #ID to link |
|---|
| 558 | | to the post, in the month archive if archive-mode is "monthly".<br /> |
|---|
| 559 | | note: this tag does not display the link, for this you've got to type |
|---|
| 560 | | <a href="<?php permalink_link() ?>">text of the |
|---|
| 561 | | link</a>.<br /> |
|---|
| 562 | | <div class="params">Parameters: |
|---|
| 563 | | <ul> |
|---|
| 564 | | <li>file name, in case you want to link the archive to a different |
|---|
| 565 | | template (default is the current template)</li> |
|---|
| 566 | | <li>string for kind of link: either 'id' that appends '#50' to the |
|---|
| 567 | | link, or 'title' that appends '#title_of_post_50' (default is 'id')</li> |
|---|
| 568 | | </ul> |
|---|
| 569 | | </div> |
|---|
| 570 | | <br /> |
|---|
| 571 | | <br /> |
|---|
| 572 | | <strong><?php permalink_single() ?> <span style="font-family: Courier New, Courrier, mono; color: #ff9900; font-weight:bold;">*</span><br /> |
|---|
| 573 | | </strong>this will display the name of the file followed by #ID to link |
|---|
| 574 | | to the entire |
|---|