| [ Index ] |
PHP Cross Reference of Nucleus CMS 3.32 |
[Summary view] [Print] [Text view]
1 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> 2 <html xmlns="http://www.w3.org/1999/xhtml"> 3 <head> 4 <!-- $Id: help.html 1175 2007-06-16 22:14:16Z kaigreve $ --> 5 6 <title>Nucleus Admin Help</title> 7 <style type="text/css"> 8 <!-- 9 body { 10 font-family: verdana, arial; 11 font-size: small; 12 } 13 14 h1 { 15 font-size: large; 16 border-bottom: 1px gray dashed; 17 color: #596d9d; 18 text-align: left; 19 } 20 21 h2 { 22 font-size: medium; 23 border: 1px solid #ddd; 24 background-color: whitesmoke; 25 text-align: left; 26 } 27 28 .page { 29 height: 800px; 30 text-align: justify; 31 margin-bottom: 100px; 32 } 33 34 pre { 35 background-color: #ddd; 36 padding: 5px; 37 font-size: small; 38 } 39 40 .example { 41 background-color: #ddd; 42 padding: 5px; 43 } 44 45 ul.templates { 46 font-size: x-small; 47 line-height: 1.1; 48 list-style: none; 49 text-indent: -20px; 50 margin-left: 20px; 51 } 52 53 ul { 54 text-align: left; 55 } 56 57 a:link, a:visited { 58 color: #1D3565; 59 font-weight: bold; 60 text-decoration: underline; 61 } 62 63 a:hover { 64 background-color: whitesmoke; 65 } 66 67 .deprecated { 68 border: 3px solid red; 69 padding: 5px; 70 font-size: medium; 71 } 72 73 tt, code { 74 font-size: small; 75 } 76 77 table { 78 border: 1px solid #ccc; 79 } 80 81 th { 82 background-color: #eee; 83 } 84 85 td { 86 vertical-align: top; 87 } 88 89 .note { 90 background-color: #eee; 91 padding: 5px; 92 } 93 --> 94 </style> 95 </head> 96 <body> 97 98 <div class="page"> 99 <h1>Nucleus Popup Help</h1> 100 <p>Please hold on while the page is being downloaded (about 100KB).</p> 101 </div> 102 103 104 <div class="page"> 105 <a name="future"></a> 106 <a name="allowpastposting"></a> 107 <h1>Add Later/Earlier</h1> 108 <h2>Add Later</h2> 109 <p>The 'Add Later' option on add-item forms allows you to mark an item to become visible only at the exact time you've specified. Before that time has come, the item will not be viewable anywhere in the public part of your site.</p> 110 <p>This date <strong>must</strong> be in the future, unless the 'Allow posting to the past' option is enabled for the blog to which you want to add the item.</p> 111 <h2>Allow posting to the past</h2> 112 <p>When enabled, you'll be allowed to specify the date on which an item should be added, and to edit the timestamp of already existing items.</p> 113 </div> 114 115 <div class="page"><a name="changedate"></a> 116 <h1>Change post date/time</h1> 117 <p> 118 The 'Update Timestamp' option allows you to change the posting date and/or time of an item. If you changed the content of an item, this is a way bring the story back to the top of your front page.</p> 119 <p>But, the unique id connected to the item will not change, so your visitors can still find out that the item was originally posted later than items with a lower id.</p> 120 </div> 121 122 123 <div class="page"><a name="draft"></a> 124 <h1>Drafts</h1> 125 <p> 126 Draft items are not yet viewable in the public blog. They might come in handy when you are working on a story, and something comes in between. Your draft items will be listed on the main page, so you can continue your work when you have the time to do so.</p> 127 <p>When editing drafts, choose the '<strong>Add now</strong>' radiobutton and hit the 'Edit item' button to make them visible. 128 </p> 129 </div> 130 131 <div class="page"><a name="extended"></a> 132 <h1>Extended part</h1> 133 <p> 134 Items have an optional extended part that you can use for continued stories. e.g. when a story is too long to put on the main page of your blog, you can write an introduction in the body part and the rest in the extended part. When viewing your main blog page, you will then see 'read more' links (as defined by the templates). 135 </p> 136 <p> 137 If you want to write an introduction only for <em>some</em> of your items, you could use the <a href="#templatevar-smartbody">smartbody</a> template variable to make a selection out of the body text and the extended text. 138 </p> 139 </div> 140 141 <div class="page"><a name="shortblogname"></a> 142 <h1>Short Blog Name</h1> 143 <p> 144 The short blog name is used mainly in the admin area to indicate which items are associated with which blog. 145 </p> 146 <p> 147 It can also be used in alternative index files, to make a second weblog available: 148 </p> 149 <pre> 150 <? 151 include ('./config.php'); 152 selectBlog('myshortblogname'); 153 selector(); 154 ?> 155 </pre> 156 </div> 157 158 <div class="page"><a name="blogdefaultskin"></a> 159 <h1>Default Skin</h1> 160 <p> 161 The default skin selected in the blog settings is the skin that should be used when the blog is displayed, and there is no other skin selected (through arguments in the URL) 162 </p> 163 </div> 164 165 166 <div class="page"><a name="blognotify"></a> 167 <h1>Notify Address</h1> 168 <p> 169 This option contains one or multiple e-mail addresses to which notification e-mails should be sent when new comments are added. Leave empty if you don't want notification. The given e-mail addresses must, of course, be valid. 170 </p> 171 <p> 172 If you're using multiple addresses, you should use a semicolon (<strong>;</strong>) as a separator. 173 </p> 174 <div class="note"> 175 <b>Note:</b> As the maximum length of the settings fields is 128 characters, there's only a limited amount of e-mail addresses you can list. 176 </div> 177 <div class="note"> 178 <b>Note:</b> When you set up your own e-mail address as notification address, you won't get notified of the items/comments that you wrote yourself. Assuming that you know what you wrote, that shouldn't be a problem. 179 </div> 180 </div> 181 182 <div class="page"><a name="blogmaxcomments"></a> 183 <h1>Max Amount of Comments</h1> 184 <p> 185 This is the maximum number of comments that will be shown on the <em>main page</em>. <strong>This is NOT a restriction on the total number of comments that can be made</strong>. On the detail pages, all comments will be shown, even if there are more than the maximum amount chosen. 186 </p> 187 <p class="note"><strong>Note:</strong> 188 Inside templates, this variable can be overridden by an optional parameter of the <a href="#templatevar-comments">comments</a> templatevar. 189 </p> 190 </div> 191 192 <div class="page"><a name="blogtimeoffset"></a> 193 <h1>Time Offset</h1> 194 <p> 195 If the time on your server is not equal to the time where you live, you might want to add an offset to the server time in order to get the correct time. Use negative values to subtract (negation sign). The current server time is listed as a reference. 196 </p> 197 <h2>Example</h2> 198 <p>If your local time is 20:35 and the server time is listed as 14:35, you'll need to set the time offset equal to 6 in order to get your blog time to 20:35 199 </p> 200 <p class="note"><strong>Note:</strong> Fractional offsets can be used as well, for people living in half time zones. e.g. an offset of <strong>1.5</strong> equals an offset of 1 hour and 30 minutes.</p> 201 </div> 202 203 <div class="page"><a name="blogupdatefile"></a> 204 <h1>Update File</h1> 205 <p> 206 Nucleus can edit a file for you whenever a new item is added to the blog. The contents of that file will be a timestamp of the last change. The use of such a file could be useful for services which check a file on your server once in a while to see if there were updates, and generate 'updated weblogs' from that. Pointing them to your main blog could cause false update warnings to be sent out when visitors add comments or when you change something to the skins or templates. 207 </p> 208 <p> 209 When you don't need an update file, just leave the field empty. 210 </p> 211 <p> 212 Please note that the location of the update file is relative to the admin-area, so you might want to use an absolute path (something like <tt>/path/to/your/website/update.txt</tt>). Also make sure the update file already exists and is writable (<a href="tips.html#filepermissions" onclick="window.open(this.href);return false;" class="out" title="quick guide on changing file permissions">chmod it to 666</a> if you want to be sure). 213 </p> 214 </div> 215 216 <div class="page"><a name="teamadmin"></a> 217 <h1>Blog Admin</h1> 218 <p> 219 Blog administrators have the following extra rights: 220 </p> 221 222 <ul> 223 <li>They can manage the team</li> 224 <li>They can edit blog settings</li> 225 <li>They can edit/delete all items by all authors (from the blog of which they are admin)</li> 226 <li>They can delete the blog</li> 227 </ul> 228 229 <p> 230 A blog can have multiple admins, but there must be at least one admin at all times. 231 </p> 232 </div> 233 234 235 <div class="page"><a name="superadmin"></a> 236 <h1>Administrator Privileges</h1> 237 238 <p> 239 A so called <em>super-admin</em> has <strong>full access</strong> to all functions and all weblogs, even if she is not on the blog team. 240 </p> 241 242 <p> 243 On top of that: a super-admin has the right to create new weblogs, to change general settings, to change templates, to change skins and to manage the members (creation/ manipulation/ deletion of members). 244 </p> 245 246 <p> 247 Usually, there will be only one super-admin, the site administrator. 248 </p> 249 250 </div> 251 252 <div class="page"><a name="canlogin"></a> 253 <h1>Can Login?</h1> 254 <p> 255 As a <a href="#superadmin" title="Administrator Privileges">superadmin</a>, you can disallow individual members to login to the admin area. 256 </p> 257 </div> 258 259 <div class="page"><a name="defaultblog"></a> 260 <h1>Default Blog</h1> 261 <p> 262 This is the blog that will be used when no other blog has been specified in the request. 263 </p> 264 </div> 265 266 <div class="page"><a name="baseskin"></a> 267 <h1>Base Skin</h1> 268 269 <p>The option tells Nucleus which skin to fall back to when no such decision can be automatically made. This happens when skin parts are empty, when no blog or skin is implicitly/explicitly selected.</p> 270 <p>Most users don't need to worry about this setting.</p> 271 </div> 272 273 <div class="page"><a name="cookies"></a> 274 <h1>Cookies</h1> 275 276 <h2>Cookie Lifetime</h2> 277 <p> 278 When a member logs in, a cookie is stored in his browser, so she doesn't need to log in again when she comes back the next day. The lifetime of this cookie decided when it will become invalid:</p> 279 <ul> 280 <li><strong>Session cookies</strong> get deleted when you exit the browser</li> 281 <li>Cookies with a lifetime of <strong>one month</strong> will stay on the computer until you don't use/visit the site for a month. Using this option, you'll never have to login again (unless you've logged out yourself, or logged in from another computer)</li> 282 </ul> 283 284 <h2>Cookie Path & Cookie Domain</h2> 285 <p> 286 These settings are advanced settings. Normally, you shouldn't change them at all. In that case, cookie path is a simple slash ('/') and cookie domain is empty. 287 </p> 288 289 <h2>Secure Cookies</h2> 290 <p> 291 Normally, this should be set to 'no'. You should only set it to 'yes' when you have a HTTPS url and want cookies only to be sent over such a https connection. 292 </p> 293 294 <h2>'Last Visit' Cookie</h2> 295 <p> 296 You can setup Nucleus to store a cookie in which the time of the visitors last visit is stored. This can be used to put indications next to <a href="#templatenew">new items</a> 297 </p> 298 299 </div> 300 301 302 <div class="page"><a name="language"></a> 303 <h1>Language</h1> 304 <p> 305 You can choose a language to be used when nucleus creates content for you. The content generated by Nucleus includes the admin-area, the error messages, forms in skins, ... 306 </p> 307 308 <p> 309 There are two places where a language can be chosen: the global site settings include a language option. 310 Next to that, logged in members can override this setting if they want to. 311 </p> 312 313 <p> 314 When both of these settings are invalid, 'english' is used as the default language. 315 </p> 316 317 <p class="note"><strong>Note:</strong> Extra language files can be downloaded from the <a href="http://www.nucleuscms.org/" onclick="window.open(this.href);return false;" class="out" title="Nucleus CMS Website">Nucleus Website</a>. (opens a new window)</p> 318 319 </div> 320 321 <div class="page"><a name="allowaccountcreation"></a> 322 <h1>Account Creation</h1> 323 <p> 324 You can either allow or disallow your visitors to create their own 'member' account. They won't be allowed to add items to a blog (unless the admin adds them to a team), but they can login to the administration area and change their settings, and even delete or modify the comments they made. 325 </p> 326 </div> 327 328 <div class="page"><a name="allownewmemberlogin"></a> 329 <h1>New Member: can login ?</h1> 330 <p> 331 When you allow <a href="#allowaccountcreation">creation of member accounts</a> by your visitors, this setting defines whether or not accounts created in that way will have the ability to <a href="#canlogin">login to the administration area</a>. 332 </p> 333 </div> 334 335 336 <div class="page"><a name="messageservice"></a> 337 <h1>Message Service</h1> 338 339 <p> 340 For the privacy of your members, you can hide all e-mail addresses and allow members to send an e-mail message to each other through the script. The message that will be sent out will however contain the e-mail addresses of both users, so they can then do continued communication through regular e-mail. This service can be disabled. 341 </p> 342 343 <h2>Non-members</h2> 344 <p> 345 By default, non members cannot use the message service (because there's no way to check the validity of the e-mail address they enter). You can relax this restriction by allowing non-members to use the message service too. When submitting a message, they will be asked to enter their e-mail address, which will show up in the <tt>From:</tt> headers of the e-mail you receive. 346 </p> 347 348 </div> 349 350 <div class="page"><a name="disablesite"></a> 351 <h1>Disable Site</h1> 352 <p> 353 It's possible to disable your entire Nucleus site. You might want to do this when you are doing some configuration, or when something went horribly wrong :-) 354 </p> 355 <p> 356 The URL that needs to be configured is an URL to which the visitor will be redirected. 357 </p> 358 <p> 359 Exceptions: the <strong>admin-area</strong> is still available, and <strong><a href="#superadmin">super-admins</a></strong> can still see the entire site. (don't forget to re-enable your site afterwards ;-)) 360 </p> 361 </div> 362 363 364 <div class="page"><a name="urlmode"></a> 365 <h1>URL Mode</h1> 366 <p>Using this option, you can switch between URL styles:</p> 367 <ul> 368 <li><strong>Normal</strong>: URLs looking like <code>http://host/index.php?itemid=1234</code></li> 369 <li><strong>Fancy</strong>: URLs looking like <code>http://host/item/1234</code></li> 370 </ul> 371 <p class="note"><strong>Note:</strong> In order to get the 'Fancy URL' mode working, some extra actions are required. They're described in the <a href="tips.html" class="out" onclick="window.open(this.href);return false;">Tips & Suggestions</a> (opens in new window)</p> 372 373 </div> 374 375 <div class="page"><a name="templateitems"></a> 376 <h1>Templates: Items</h1> 377 <p> 378 When items are shown, the following setup is repeated for each item: 379 </p> 380 381 <pre> 382 item header 383 item body 384 item footer 385 </pre> 386 387 <p>These three blocks all refer to a template-part, which define what the result looks like.</p> 388 389 <h2>Variables</h2> 390 391 <p>Within these template, a series of so called <a href="#templatevars-overview" title="Find out which variables are available">template variables can be used</a> to insert item data.</p> 392 393 <h2>Example</h2> 394 <p><a href="#templateitemsexample">An example</a></p> 395 396 </div> 397 398 <div class="page"><a name="templateitemsexample"></a> 399 <h1>Templates: Items</h1> 400 <p> 401 An example for the <b>item body</b> template: 402 </p> 403 404 <pre><h1><%title%></h1> 405 406 <p><%body%></p> 407 408 <div class="metadata"> 409 <a href="<%itemlink%>">link</a> - 410 <%date%> <%time%> - 411 <a href="<%authorlink%>"><%author%></a> - 412 <%comments%> 413 </div></pre> 414 415 <p>The result would become something like this:</p> 416 417 <div class="example"> 418 <h4 style="margin: 2px;">This is an item</h4> 419 <p style="margin: 2px; padding: 0px;">This is the text for the item</p> 420 <div style="font-style: italic; margin: 2px;"> 421 <a href="#templateitemsexample">link</a> - 422 August 8th 2002 18:51 - 423 <a href="#templateitemsexample">karma</a> - 424 <a href="#templateitemsexample">no comments</a> 425 </div> 426 </div> 427 428 </div> 429 430 431 <div class="page"><a name="templatecomments"></a> 432 <h1>Templates: comments</h1> 433 434 <p>There are three possible structures for a comments block.</p> 435 436 <ol> 437 <li> 438 When comments are displayed (like on detail pages, or on the main page when there are less than the maximum allowed amount of comments) 439 <pre>comments header 440 comments body (repeated) 441 comments footer</pre> 442 </li> 443 <li> 444 When there are no comments at all 445 <pre> 446 no comments 447 </pre> 448 </li> 449 <li> 450 When there are comments, but there are more than the maximum allowed number. (only applies when not on a detailed item page) 451 <pre> 452 too much comments 453 </pre> 454 </li> 455 </ol> 456 457 <p>Inside these template-parts, some <a href="#templatevars-comments" title="Overview of comments-related template variables">comments-related variables</a> are available</p> 458 459 </div> 460 461 <div class="page"> 462 <a name="templatecommentheaders"></a> 463 <a name="templatecommentfooters"></a> 464 <h1>Templates: Comment headers/footers</h1> 465 466 <h2>Description</h2> 467 468 <p>While the comments-body is repeated for each comment, the header and footer are only displayed once. A typicall structure would look like this:</p> 469 <pre>comments header 470 comments body 1 471 comments body 2 472 comments body 3 473 comments footer</pre> 474 <p>In these template-parts, <a href="#templatevars-comments" title="Overview of comments-related template variables">comments-related templatevars</a> are available</p> 475 476 <h2>Examples</h2> 477 478 <p>Header:</p> 479 <pre><ul></pre> 480 <p>Body:</p> 481 <pre><li><%user%>: <%body%></li></pre> 482 <p>Footer</p> 483 <pre></ul></pre> 484 <p>Result</p> 485 486 <ul class="example"> 487 <li>karma: nice!</li> 488 <li>xiffy: yes indeed!</li> 489 </ul> 490 491 </div> 492 493 <div class="page"><a name="templatemorelink"></a> 494 <h1>Templates: Link to extended entry</h1> 495 <p> 496 This is the template that will be used to format the <a href="#templatevar-morelink">morelink templatevar</a> that is available in the item templates. <a href="#templatevars-overview">Available variables</a> are the same as in the item templates. 497 </p> 498 <p> 499 When there's no extended part of the item, the <code><%morelink%></code> templatevar will have no effect. 500 </p> 501 502 <h2>Example</h2> 503 <pre><code><a href="<%itemlink%>">[Read More!]</a></code></pre> 504 505 </div> 506 507 <div class="page"><a name="templatearchivelists"></a> 508 509 <h1>Templates: Archive Lists</h1> 510 511 <p>The archive lists are formatted as listed below:</p> 512 513 <pre>archivelist header 514 archivelist listitem (repeated for each archive) 515 archivelist footer</pre> 516 517 <p> 518 Available variables: (in the header and footer, only <tt>blogid</tt> is allowed) 519 </p> 520 521 <table><tr> 522 <th>Name</th> 523 <th>Description</th> 524 </tr><tr> 525 <td>blogid</td> 526 <td>ID of the weblog</td> 527 </tr><tr> 528 <td>archivelink</td> 529 <td>link to the archive, which you can embed in a <code><a href=".."></code> tag.</td> 530 </tr><tr> 531 <td>month</td> 532 <td>Number of the month (2 digits: 01-12)</td> 533 </tr><tr> 534 <td>year</td> 535 <td>Year (4 digits)</td> 536 </tr><tr> 537 <td>day</td> 538 <td>Day of month (2 digits; only when in day mode)</td> 539 </tr></table> 540 541 <p>A more flexible way to add the date of the archive to the listitem, is to use <a href="#strftime">strftime</a> variables. If you find this too complicated, use the following:</p> 542 543 <pre><code><a href="<%archivelink%>">%B, %Y</a><br /></code></pre> 544 545 546 <p>To change the language to your local settings, change the <a href="#templatelocale">locale</a>.</p> 547 548 </div> 549 550 551 552 553 <div class="page"><a name="templatecategorylists"></a> 554 <h1>Templates: Category Lists</h1> 555 556 <p>The category lists are formatted as listed below:</p> 557 558 <pre>categorylist header 559 categorylist listitem (repeated) 560 categorylist footer</pre> 561 562 <p>Available variables: (in the header and footer, only <tt>blogid</tt>, <tt>blogurl</tt> and <tt>self</tt> are allowed)</p> 563 564 <table><tr> 565 <th>Name</th> 566 <th>Description</th> 567 </tr><tr> 568 <td>blogid</td> 569 <td>ID of the weblog</td> 570 </tr><tr> 571 <td>blogurl</td> 572 <td>URL of the blog (as defined in blogsettings)</td> 573 </tr><tr> 574 <td>self</td> 575 <td>Current page, without parameters (e.g. <tt>index.php</tt>)</td> 576 </tr><tr> 577 <td>catlink</td> 578 <td>a link to the most recent items for a category, which you can embed in a <a href=".."> tag.</td> 579 </tr><tr> 580 <td>catid</td> 581 <td>Category ID</td> 582 </tr><tr> 583 <td>catname</td> 584 <td>Category name</td> 585 </tr><tr> 586 <td>catdesc</td> 587 <td>Category description</td> 588 </tr></table> 589 590 <p><a href="#categorylistexample">View an example</a></p> 591 592 </div> 593 594 <div class="page"><a name="categorylistexample"></a> 595 <h1>Templates: Category Lists Example</h1> 596 <p> 597 <a href="#templatecategorylists">(go back)</a> 598 </p> 599 600 <h2>Header</h2> 601 <pre><code><ul> 602 <li><a href="<blogurl%>">All</a></li></code></pre> 603 604 <h2>List Item</h2> 605 <pre><code><li><a href="<%catlink%>"><%catname%></a></li></code></pre> 606 607 <h2>Footer</h2> 608 <pre><code></ul></code></pre> 609 610 <h2>Results in:</h2> 611 612 <ul class="example"> 613 <li><a href="#categorylistexample">All</a></li> 614 <li><a href="#categorylistexample">myCategory</a></li> 615 <li><a href="#categorylistexample">yourCategory</a></li> 616 </ul> 617 618 </div> 619 620 621 622 623 624 625 626 <div class="page"><a name="templatelocale"></a> 627 <h1>Templates: Locale</h1> 628 <p> 629 This is actually not a template-part, it's a setting. Setting it allows the date and time preferences when to be localized. Names of months and days will be in the desired language, etc. 630 </p> 631 632 <p> 633 The possible values depend according to which machine Nucleus is running on. Some possible values are 634 </p> 635 636 <ul> 637 <li><strong>en</strong>: English</li> 638 <li><strong>dutch</strong>: Dutch</li> 639 <li>...</li> 640 </ul> 641 642 <p> 643 More info in the <a href="http://www.opengroup.org/onlinepubs/7908799/xsh/strftime.html" onclick="window.open(this.href);return false;" class="out" title="Open Group specification">Open Group Specification</a> for strftime. (opens a new window) 644 </p> 645 646 <p> 647 The locale is used for the <a href="#templatedatetime">date and time format</a>, for the <a href="#templatedateheads">dateheaders</a>, and for the <a href="#templatearchivelists">archivelist items</a> 648 </p> 649 650 </div> 651 652 <div class="page"><a name="templatedatetime"></a> 653 <h1>Templates: Date and Time formats</h1> 654 <p> 655 These are used to format dates and times into the <code><%date%></code> and <code><%time%></code> vars (see <a href="#templatevars-overview">template vars</a>). The formatting is done according to the <a href="#templatelocale">locale</a> 656 </p> 657 658 <p> 659 <a href="#strftime">More info on the available vars</a>. If want to get started quickly, use "%x" to format the date and "%X" to format the time. 660 </p> 661 662 </div> 663 664 <div class="page"><a name="templatedateheads"></a> 665 <h1>Template: Date headers/footers</h1> 666 667 <p> 668 The date header and date footer can contain date and time vars. <a href="#strftime">More info on the available vars</a>. If you want to get started quickly, use "%x" to format the date. The language which is used to format the date, is determined by the <a href="#templatelocale">locale-setting</a> in the template.</p> 669 670 <p> 671 In the date header, the template variable <%%daylink%%> is allowed to insert a link to the archive for that day. <strong>Note the double '%'! It's necessary to avoid %d to be expanded as the current day of the month.</strong> Also, if you just want to add a '%' character somewhere, you should also put it twice ('%%') or it will be gone on your website. 672 </p> 673 674 <p> 675 Sample for date header: 676 </p> 677 678 <pre> 679 <div class="day"> 680 <h1>%d %B</h1> 681 </pre> 682 683 <p> 684 Sample for date footer: 685 </p> 686 687 <pre> 688 </div> 689 </pre> 690 691 <p>And another example for the date head using daylink</p> 692 693 <pre> 694 <div class="day"> 695 <h1>%d %B</h1> 696 <a href="<%%daylink%%>">(archive)</a> 697 </pre> 698 699 </div> 700 701 <div class="page"><a name="templatehighlight"></a> 702 <h1>Templates: Highlight</h1> 703 <p> 704 The highlighting is used when performing searches. This is actually used in a regular expression, so you might want to escape some characters by putting a backslash before them. The place where the highlighted word will come, is indicated by "\0". 705 </p> 706 707 <h2>Example</h2> 708 709 <pre><code><span style='background-color:yellow'>\0</span></code></pre> 710 711 </div> 712 713 <div class="page"><a name="templatenothingfound"></a> 714 <h1>Templates: nothing found</h1> 715 716 <p> 717 Shown when a search has been performed and no results were found. 718 </p> 719 720 <p>Available variables:</p> 721 722 <table><tr> 723 <th>Name</th> 724 <th>Description</th> 725 </tr><tr> 726 <td>blogid</td> 727 <td>ID of the weblog</td> 728 </tr><tr> 729 <td>query</td> 730 <td>the query that was used in the search</td> 731 </tr></table> 732 733 <h2>Example</h2> 734 735 <pre><code>No search results found for <b><%query%></b></code></pre> 736 737 </div> 738 739 <div class="page"><a name="templatecommentbody"></a> 740 <h1>Templates: Comment body</h1> 741 <p> 742 This is the part of the template used to display a single comment. In this template-part, <a href="#templatevars-comments" title="Overview of comments-related template variables">comments-related templatevars</a> are available.</p> 743 744 <h2>Example</h2> 745 <pre><code><h2>Comment by <%userlink%>:</h2> 746 747 <p><%body%></p> 748 749 <div class="metadata"> 750 (from <%host%> on <%date%> at <%time%>) 751 </div></code></pre> 752 753 <p>Result:</p> 754 755 <div class="example"> 756 <h4 style="margin: 2px;">Comment by <a href="#templatecommentbody">karma</a>:</h4> 757 <p style="margin: 2px;">Nice!</p> 758 <div style="margin:2px;font-size:smaller;">(from host.example.org on 2003-03-02 at 13:30)</div> 759 </div> 760 761 </div> 762 763 <div class="page"><a name="templatepopups"></a> 764 <h1>Templates: Media & Popups</h1> 765 <p> 766 These templates are used to format links to popup image windows and media objects (non-pictures). The available variables for each of the templates are described below 767 </p> 768 769 <h2>Popup Link Code</h2> 770 771 <table><tr> 772 <th>Name</th> 773 <th>Description</th> 774 </tr><tr> 775 <td>popuplink</td> 776 <td>an <a href... link ready to use</td> 777 </tr><tr> 778 <td>rawpopuplink</td> 779 <td>only the url inside href="..."</td> 780 </tr><tr> 781 <td>popupcode</td> 782 <td>javascript code to open window</td> 783 </tr><tr> 784 <td>text</td> 785 <td>the alternate text (link text)</td> 786 </tr><tr> 787 <td>width</td> 788 <td>image width</td> 789 </tr><tr> 790 <td>height</td> 791 <td>image width</td> 792 </tr><tr> 793 <td>popuptext</td> 794 <td>(=same as text)</td> 795 </tr><tr> 796 <td>link</td> 797 <td>direct link to the image (URL)</td> 798 </tr><tr> 799 <td>media</td> 800 <td>a non-popup A-tag to the image, ready to use.</td> 801 </tr></table> 802 803 804 <h2>Inline Image Code</h2> 805 806 <table><tr> 807 <th>Name</th> 808 <th>Description</th> 809 </tr><tr> 810 <td>image</td> 811 <td>an IMG-tag, ready to use</td> 812 </tr><tr> 813 <td>link</td> 814 <td>direct link to the image (URL)</td> 815 </tr><tr> 816 <td>text</td> 817 <td>the alternate text (link text)</td> 818 </tr><tr> 819 <td>width</td> 820 <td>image width</td> 821 </tr><tr> 822 <td>height</td> 823 <td>image width</td> 824 </tr><tr> 825 <td>media</td> 826 <td>an A-tag to the image, ready to use.</td> 827 </tr></table> 828 829 <h2>Media Object Link Code</h2> 830 831 <table><tr> 832 <th>Name</th> 833 <th>Description</th> 834 </tr><tr> 835 <td>media</td> 836 <td>an A-tag, ready to use</td> 837 </tr><tr> 838 <td>link</td> 839 <td>direct link to the file (URL)</td> 840 </tr><tr> 841 <td>text</td> 842 <td>the alternate text (link text)</td> 843 </tr></table> 844 845 </div> 846 847 <div class="page"><a name="templatememberextra"></a> 848 <h1>Templates: Member Extra</h1> 849 <p> 850 This is a template you can use to add an extra indication that a comment-author is a member. It ends up in the <code><%authtext%></code> variable for use in the <a href="#templatecommentbody">comment body</a> 851 </p> 852 853 <p>Inside this template-part, some <a href="#templatevars-comments" title="Overview of comments-related template variables">comments-related variables</a> are available.</p> 854 855 </div> 856 857 <div class="page"><a name="templatecommentcontinued"></a> 858 <h1>Templates: Comments Read More</h1> 859 <p> 860 This is the format of the link that will be added at the end of <code><%short%></code>, which is a variable for use in the <a href="#templatecommentbody">comment body</a> 861 </p> 862 863 <p>Inside this template-part, some <a href="#templatevars-comments" title="Overview of comments-related template variables">comments-related variables</a> are available (except for the <code><%short%></code> variable).</p> 864 865 <p>Example:</p> 866 867 <pre> 868 <a href="<%itemlink%>">[more]</a> 869 </pre> 870 871 </div> 872 873 <div class="page"><a name="templatecommentwords"></a> 874 <h1>Templates: commentword</h1> 875 <p> 876 Most likely, you'll rather want to write "1 comment" than "1 comment(s)". The "One comment" and "Many comments" template parts can be used for this purpose. They will be used to fill the <code><%commentword%></code> variable that you can use elsewhere. 877 </p> 878 879 <p> 880 If there is only 1 comment, <code><%commentword%></code> will be equal to the contents of the "one comment" part. If there are many comments (more than one), <code><%commentword%></code> will be equal to the contents of the "two (or more) comments" part. 881 </p> 882 883 <p> 884 Typical values are "comment" and "comments". <strong>No special variables can be used here</strong>. 885 </p> 886 </div> 887 888 889 890 <div class="page"><a name="templateeditlink"></a> 891 <h1>Templates: Edit Link</h1> 892 <p> 893 This template defines how the <a href="#templatevar-edit">edit-templatevar</a> will be marked up. You can use any of the <a href="#templatevars-overview">template variables</a> here. 894 </p> 895 896 <h2>Example:</h2> 897 898 <pre><code><a href="<%editlink%>" 899 onclick="<%editpopupcode%>">edit</a></code></pre> 900 901 </div> 902 903 904 905 906 <div class="page"><a name="skinpartindex"></a> 907 <h1>Skins: Main Index</h1> 908 <p> 909 This skinpart is used to show the most recent entries of your weblog. It's usually the home page of your site. 910 </p> 911 912 <p> 913 Very basic buildup for a main index: 914 </p> 915 916 <pre> 917 <html> 918 <head> 919 <title>My Weblog</title> 920 </head> 921 <body> 922 923 <h1>My Weblog</h1> 924 <%blog(mytemplate,20)%> 925 926 </body> 927 </html> 928 </pre> 929 930 <p> 931 This will show the 20 most recent items of the default weblog (unless overridden), using the 'mytemplate' template. 932 </p> 933 </div> 934 935 936 <div class="page"><a name="skinpartitem"></a> 937 <h1>Skins: Detail Pages</h1> 938 <p> 939 These pages are used to show the full items, all comments that were made and a form to add comments. 940 </p> 941 942 <p> 943 Very basic buildup for a detailed item page: 944 </p> 945 946 <pre> 947 <html> 948 <head> 949 <title>My Weblog :: Item</title> 950 </head> 951 <body> 952 953 <h1>Item</h1> 954 <%item(detailed)%> 955 956 <h1>Comments</h1> 957 <%comments(detailed)%> 958 959 <h1>Add Comment</h1> 960 <%commentform%> 961 962 </body> 963 </html> 964 </pre> 965 966 <p> 967 This will show the item and comments using the 'detailed' template, and add a standard commentform. 968 </p> 969 970 971 </div> 972 973 <div class="page"><a name="skinpartarchivelist"></a> 974 <h1>Skins: Archive List</h1> 975 <p> 976 An overview of all the months for which archives are available, and links to those archives 977 </p> 978 979 <p> 980 Very basic buildup for an archive list: 981 </p> 982 983 <pre> 984 <html> 985 <head> 986 <title>My Weblog :: Archives</title> 987 </head> 988 <body> 989 990 <h1>Archives</h1> 991 <%archivelist(default)%> 992 993 </body> 994 </html> 995 </pre> 996 997 <p> 998 This will show the list of all available archive files, using the 'default' template 999 </p> 1000 1001 </div> 1002 1003 <div class="page"><a name="skinpartarchive"></a> 1004 <h1>Skins: Archive</h1> 1005 <p> 1006 An archive for one month. Behaves like a main index, but shows all the items from a certain month. 1007 </p> 1008 1009 <p> 1010 Very basic buildup for an archive page: 1011 </p> 1012 1013 <pre> 1014 <html> 1015 <head> 1016 <title>My Weblog :: Archive</title> 1017 </head> 1018 <body> 1019 1020 <h1>Archive</h1> 1021 <%archive(default)%> 1022 1023 </body> 1024 </html> 1025 </pre> 1026 1027 <p> 1028 This will show the requested archive using the 'default' template 1029 </p> 1030 1031 1032 </div> 1033 1034 1035 <div class="page"><a name="skinpartsearch"></a> 1036 <h1>Skins: Search</h1> 1037 <p> 1038 Used to show search results. 1039 </p> 1040 1041 <p> 1042 Very basic buildup for a searchresults page: 1043 </p> 1044 1045 <pre> 1046 <html> 1047 <head> 1048 <title>My Weblog :: Search</title> 1049 </head> 1050 <body> 1051 1052 <h1>Search</h1> 1053 <%searchform%> 1054 1055 <h1>Searchresults</h1> 1056 <%searchresults(default)%> 1057 1058 </body> 1059 </html> 1060 </pre> 1061 1062 <p> 1063 This will show search results using the 'default' template. 1064 </p> 1065 1066 </div> 1067 1068 <div class="page"><a name="skinparterror"></a> 1069 <h1>Skins: Errors</h1> 1070 <p> 1071 Used when there is an error 1072 </p> 1073 1074 <pre> 1075 <html> 1076 <head> 1077 <title>My Weblog :: Error</title> 1078 </head> 1079 <body> 1080 1081 <h1>Error!</h1> 1082 <%errormessage%> 1083 1084 <br /><br /> 1085 1086 <a href="javascript:history.back();">Back</a> 1087 1088 </body> 1089 </html> 1090 </pre> 1091 1092 <p> 1093 This will show the error message, plus a link to go back. 1094 </p> 1095 1096 </div> 1097 1098 <div class="page"><a name="skinpartmember"></a> 1099 <h1>Skins: Member</h1> 1100 <p> 1101 Used to show member details. 1102 </p> 1103 1104 <p> 1105 Very basic buildup for a member-detail page: 1106 </p> 1107 1108 <pre> 1109 <html> 1110 <head> 1111 <title>My Weblog :: Member details</title> 1112 </head> 1113 <body> 1114 1115 <h1>Info about <%member(name)%></h1> 1116 Website: 1117 <a href="<%member(url)%>"><%member(url)%></a> 1118 1119 <h1>Send Message</h1> 1120 <%membermailform%> 1121 1122 </body> 1123 </html> 1124 </pre> 1125 1126 <p> 1127 This will show the members name, website address and a mailform. 1128 </p> 1129 1130 </div> 1131 1132 1133 <div class="page"><a name="skinpartimagepopup"></a> 1134 <h1>Skins: Image Popup</h1> 1135 <p> 1136 Used when a media file (image) needs to be shown in a popup window. This skin defines the layout that will be used in that case. 1137 </p> 1138 1139 <p> 1140 Very basic buildup for an imagepopup page: 1141 </p> 1142 1143 <pre> 1144 <html> 1145 <head> 1146 <title><%imagetext%></title> 1147 <style type="text/css"> 1148 img { border: none; } 1149 </style> 1150 </head> 1151 <body> 1152 <a href="javascript:window.close();"><%image%></a> 1153 </body> 1154 </html> 1155 </pre> 1156 1157 </div> 1158 1159 1160 1161 1162 1163 <div class="page"><a name="shortnames"></a> 1164 <h1>Shortnames & Display Names</h1> 1165 <p> 1166 Weblogs, templates and skin should all have a short name next to the full name or description. 1167 </p> 1168 1169 <p> 1170 A short name consists of <strong>only</strong> the characters a-z and 0-9, and <strong>cannot</strong> contain spaces 1171 </p> 1172 1173 <p> 1174 Display names are used for members. They can contain a-z, A-Z, 0-9 and spaces, but the spaces cannot be placed at the beginning or end of the name. 1175 </p> 1176 </div> 1177 1178 1179 1180 1181 1182 1183 <div class="page"><a name="templatenew"></a> 1184 <h1>Template: 'New' indication</h1> 1185 <p> 1186 When the <a href="#cookies">'last visit' cookie</a> option is activated, the contents of the 'Indication of new item'-template is copied into the <%new%> variable for items that have been added since the last visit. The <code><%new%></code> variable can e.g. be used in the <a href="#templateitems">item body</a>-template. 1187 </p> 1188 1189 <p> 1190 When the 'last visit' cookie is disabled, or the item is not 'new', this template part will not be used. 1191 </p> 1192 </div> 1193 1194 1195 <div class="page"><a name="strftime"></a> 1196 <h1>Time variables overview</h1> 1197 1198 <p>The following conversion specifiers are recognized in the format string <small>(taken from the PHP documentation for the strftime function)</small>. More info in the <a href="http://www.opengroup.org/onlinepubs/7908799/xsh/strftime.html" onclick="window.open(this.href);return false;" class="out" title="Open Group specification">Open Group Specification</a></p> 1199 1200 <ul> 1201 <li><strong>%a</strong> - abbreviated weekday name according to the current locale</li> 1202 <li><strong>%A</strong> - full weekday name according to the current locale</li> 1203 <li><strong>%b</strong> - abbreviated month name according to the current locale</li> 1204 <li><strong>%B</strong> - full month name according to the current locale</li> 1205 <li><strong>%c</strong> - preferred date and time representation for the current locale</li> 1206 <li><strong>%d</strong> - day of the month as a decimal number (range 00 to 31)</li> 1207 <li><strong>%H</strong> - hour as a decimal number using a 24-hour clock (range 00 to 23)</li> 1208 <li><strong>%I</strong> - hour as a decimal number using a 12-hour clock (range 01 to 12)</li> 1209 <li><strong>%j</strong> - day of the year as a decimal number (range 001 to 366)</li> 1210 <li><strong>%m</strong> - month as a decimal number (range 1 to 12)</li> 1211 <li><strong>%M</strong> - minute as a decimal number</li> 1212 <li><strong>%p</strong> - either `am' or `pm' according to the given time value, or the corresponding strings for the current locale</li> 1213 <li><strong>%S</strong> - second as a decimal number</li> 1214 <li><strong>%U</strong> - week number of the current year as a decimal number, starting with the first Sunday as the first day of the first week</li> 1215 <li><strong>%W</strong> - week number of the current year as a decimal number, starting with the first Monday as the first day of the first week</li> 1216 <li><strong>%w</strong> - day of the week as a decimal, Sunday being 0</li> 1217 <li><strong>%x</strong> - preferred date representation for the current locale without the time</li> 1218 <li><strong>%X</strong> - preferred time representation for the current locale without the date</li> 1219 <li><strong>%y</strong> - year as a decimal number without a century (range 00 to 99)</li> 1220 <li><strong>%Y</strong> - year as a decimal number including the century</li> 1221 <li><strong>%Z</strong> - time zone or name or abbreviation</li> 1222 <li><strong>%%</strong> - a literal `%' character</li> 1223 </ul> 1224 1225 </div> 1226 1227 <div class="page"><a name="sendping"></a> 1228 <h1>Ping weblog listing services</h1> 1229 <p> 1230 When updating your weblog, you can choose to send an update notification (ping) to various weblog listing services. They provides a list of recently updated weblogs to everyone who requests it. Lots of websites are using this data, so you might receive some extra hits when enabling the ping. 1231 </p> 1232 <p class="note"><strong>Note:</strong> For this feature to work correctly, you need to fill out both the weblog URL and the weblog name in the blogsettings. 1233 </p> 1234 1235 </div> 1236 1237 <div class="page"><a name="blogsearchable"></a> 1238 1239 <h1>Always include in search</h1> 1240 1241 <p>When the 'include in search' option is selected, the weblog will <strong>always</strong> be included in searches, even if the search is done on another weblog.</p> 1242 1243 <p>As an example, suppose you have two blogs called 'lifelog' and 'linkdump', with the 'include in search' enabled for 'linkdump'. Now, a search query on 'lifelog' will also search through 'linkdump', while a search query on 'linkdump' will only search entries in 'linkdump'</p> 1244 1245 1246 </div> 1247 1248 1249 <div class="page"><a name="convertbreaks"></a> 1250 <h1>Convert Linebreaks</h1> 1251 <p> 1252 By default, Nucleus converts linebreaks in your items to <code><br /></code> tags, so a linebreak will also show up in your (X)HTML output 1253 </p> 1254 <p> 1255 Advanced users, or users striving for the semantic web (<tt>br</tt> tags don't add any information, they're just used for markup), might find this feature annoying, and turn this feature off. 1256 </p> 1257 </div> 1258 1259 1260 <div class="page"><a name="media"></a> 1261 <h1>Media</h1> 1262 <p> 1263 Nucleus allows you to upload media files (images, video, sound, ...) to your website 1264 </p> 1265 <p> 1266 Some settings are needed to do this: 1267 </p> 1268 <ul> 1269 <li><strong>Media dir</strong>: location on the server where the media files will be saved (local filesystem)</li> 1270 <li><strong>Media URL</strong>: location of the media files</li> 1271 <li><strong>Allow upload</strong>: It's possible to disable file upload</li> 1272 <li><strong>Allowed filetypes for upload</strong>: a bunch of extensions uploaded files can have (seperated by commas, case insensitive)</li> 1273 <li><strong>Max. upload file size</strong>: Puts a limit on the size of uploaded files</li> 1274 <li><strong>Prefix Media Files</strong>: When this option is turned on, uploaded file will be prefixed with the current date. Uploading a file named 'bunny.jpg' on April 8, 2003 will then result in a file named 20030408-bunny.jpg. The reason why you might want to do this, is when you're uploading tons of files, and don't want problems with duplicate names.</li> 1275 </ul> 1276 1277 <p> 1278 Each member has his own private collection of media files. Next to that, subdirectories that are under the media dir are seen as global collections (shared between members). 1279 </p>