|
|
Nucleus Popup HelpPlease hold on while the page is being downloaded (about 100KB). Add Later/EarlierAdd LaterThe '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. This date must 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. Allow posting to the pastWhen 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. Change post date/timeThe '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. 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. DraftsDraft 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. When editing drafts, choose the 'Add now' radiobutton and hit the 'Edit item' button to make them visible. Extended partItems 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). If you want to write an introduction only for some of your items, you could use the smartbody template variable to make a selection out of the body text and the extended text. Short Blog NameThe short blog name is used mainly in the admin area to indicate which items are associated with which blog. It can also be used in alternative index files, to make a second weblog available: <? include('./config.php'); selectBlog('myshortblogname'); selector(); ?> Default SkinThe 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) Notify AddressThis 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. If you're using multiple addresses, you should use a semicolon (;) as a separator.
Note: As the maximum length of the settings fields is 128 characters, there's only a limited amount of e-mail addresses you can list.
Note: 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.
Max Amount of CommentsThis is the maximum number of comments that will be shown on the main page. This is NOT a restriction on the total number of comments that can be made. On the detail pages, all comments will be shown, even if there are more than the maximum amount chosen. Note: Inside templates, this variable can be overridden by an optional parameter of the comments templatevar. Time OffsetIf 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. ExampleIf 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 Note: Fractional offsets can be used as well, for people living in half time zones. e.g. an offset of 1.5 equals an offset of 1 hour and 30 minutes. Update FileNucleus 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. When you don't need an update file, just leave the field empty. 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 /path/to/your/website/update.txt). Also make sure the update file already exists and is writable (chmod it to 666 if you want to be sure). Blog AdminBlog administrators have the following extra rights:
A blog can have multiple admins, but there must be at least one admin at all times. Administrator PrivilegesA so called super-admin has full access to all functions and all weblogs, even if she is not on the blog team. 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). Usually, there will be only one super-admin, the site administrator. Default BlogThis is the blog that will be used when no other blog has been specified in the request. Base SkinThe 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. Most users don't need to worry about this setting. CookiesCookie LifetimeWhen 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:
Cookie Path & Cookie DomainThese 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. Secure CookiesNormally, 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. 'Last Visit' CookieYou 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 new items LanguageYou 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, ... There are two places where a language can be chosen: the global site settings include a language option. Next to that, logged in members can override this setting if they want to. When both of these settings are invalid, 'english' is used as the default language. Note: Extra language files can be downloaded from the Nucleus Website. (opens a new window) Account CreationYou 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. New Member: can login ?When you allow creation of member accounts by your visitors, this setting defines whether or not accounts created in that way will have the ability to login to the administration area. Message ServiceFor 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. Non-membersBy 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 From: headers of the e-mail you receive. Disable SiteIt'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 :-) The URL that needs to be configured is an URL to which the visitor will be redirected. Exceptions: the admin-area is still available, and super-admins can still see the entire site. (don't forget to re-enable your site afterwards ;-)) URL ModeUsing this option, you can switch between URL styles:
Note: In order to get the 'Fancy URL' mode working, some extra actions are required. They're described in the Tips & Suggestions (opens in new window) Templates: ItemsWhen items are shown, the following setup is repeated for each item: item header item body item footer These three blocks all refer to a template-part, which define what the result looks like. VariablesWithin these template, a series of so called template variables can be used to insert item data. ExampleTemplates: ItemsAn example for the item body template: <h1><%title%></h1> <p><%body%></p> <div class="metadata"> <a href="<%itemlink%>">link</a> - <%date%> <%time%> - <a href="<%authorlink%>"><%author%></a> - <%comments%> </div> The result would become something like this: Templates: commentsThere are three possible structures for a comments block.
Inside these template-parts, some comments-related variables are available Templates: Comment headers/footersDescriptionWhile the comments-body is repeated for each comment, the header and footer are only displayed once. A typicall structure would look like this: comments header comments body 1 comments body 2 comments body 3 comments footer In these template-parts, comments-related templatevars are available ExamplesHeader: <ul> Body: <li><%user%>: <%body%></li> Footer </ul> Result
Templates: Link to extended entryThis is the template that will be used to format the morelink templatevar that is available in the item templates. Available variables are the same as in the item templates.
When there's no extended part of the item, the Example
Templates: Archive ListsThe archive lists are formatted as listed below: archivelist header archivelist listitem (repeated for each archive) archivelist footer Available variables: (in the header and footer, only blogid is allowed)
A more flexible way to add the date of the archive to the listitem, is to use strftime variables. If you find this too complicated, use the following:
To change the language to your local settings, change the locale. Templates: Category ListsThe category lists are formatted as listed below: categorylist header categorylist listitem (repeated) categorylist footer Available variables: (in the header and footer, only blogid, blogurl and self are allowed)
Templates: Category Lists ExampleHeader
List Item
Footer
Results in:Templates: LocaleThis 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. The possible values depend according to which machine Nucleus is running on. Some possible values are
More info in the Open Group Specification for strftime. (opens a new window) The locale is used for the date and time format, for the dateheaders, and for the archivelist items Templates: Date and Time formats
These are used to format dates and times into the More info on the available vars. If want to get started quickly, use "%x" to format the date and "%X" to format the time. Template: Date headers/footersThe date header and date footer can contain date and time vars. More info on the available vars. 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 locale-setting in the template. In the date header, the template variable <%%daylink%%> is allowed to insert a link to the archive for that day. Note the double '%'! It's necessary to avoid %d to be expanded as the current day of the month. Also, if you just want to add a '%' character somewhere, you should also put it twice ('%%') or it will be gone on your website. Sample for date header: <div class="day"> <h1>%d %B</h1> Sample for date footer: </div> And another example for the date head using daylink <div class="day"> <h1>%d %B</h1> <a href="<%%daylink%%>">(archive)</a> Templates: HighlightThe 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". Example
Templates: nothing foundShown when a search has been performed and no results were found. Available variables:
Example
Templates: Comment bodyThis is the part of the template used to display a single comment. In this template-part, comments-related templatevars are available. Example
Result: Templates: Media & PopupsThese 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 Popup Link Code
Inline Image Code
Media Object Link Code
Templates: Member Extra
This is a template you can use to add an extra indication that a comment-author is a member. It ends up in the Inside this template-part, some comments-related variables are available. Templates: Comments Read More
This is the format of the link that will be added at the end of Inside this template-part, some comments-related variables are available (except for the Example: <a href="<%itemlink%>">[more]</a> Templates: commentword
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
If there is only 1 comment, Typical values are "comment" and "comments". No special variables can be used here. Templates: Edit LinkThis template defines how the edit-templatevar will be marked up. You can use any of the template variables here. Example:
Skins: Main IndexThis skinpart is used to show the most recent entries of your weblog. It's usually the home page of your site. Very basic buildup for a main index: <html> <head> <title>My Weblog</title> </head> <body> <h1>My Weblog</h1> <%blog(mytemplate,20)%> </body> </html> This will show the 20 most recent items of the default weblog (unless overridden), using the 'mytemplate' template. Skins: Detail PagesThese pages are used to show the full items, all comments that were made and a form to add comments. Very basic buildup for a detailed item page: <html> <head> <title>My Weblog :: Item</title> </head> <body> <h1>Item</h1> <%item(detailed)%> <h1>Comments</h1> <%comments(detailed)%> <h1>Add Comment</h1> <%commentform%> </body> </html> This will show the item and comments using the 'detailed' template, and add a standard commentform. Skins: Archive ListAn overview of all the months for which archives are available, and links to those archives Very basic buildup for an archive list: <html> <head> <title>My Weblog :: Archives</title> </head> <body> <h1>Archives</h1> <%archivelist(default)%> </body> </html> This will show the list of all available archive files, using the 'default' template Skins: ArchiveAn archive for one month. Behaves like a main index, but shows all the items from a certain month. Very basic buildup for an archive page: <html> <head> <title>My Weblog :: Archive</title> </head> <body> <h1>Archive</h1> <%archive(default)%> </body> </html> This will show the requested archive using the 'default' template Skins: SearchUsed to show search results. Very basic buildup for a searchresults page: <html> <head> <title>My Weblog :: Search</title> </head> <body> <h1>Search</h1> <%searchform%> <h1>Searchresults</h1> <%searchresults(default)%> </body> </html> This will show search results using the 'default' template. Skins: ErrorsUsed when there is an error <html> <head> <title>My Weblog :: Error</title> </head> <body> <h1>Error!</h1> <%errormessage%> <br /><br /> <a href="javascript:history.back();">Back</a> </body> </html> This will show the error message, plus a link to go back. Skins: MemberUsed to show member details. Very basic buildup for a member-detail page: <html> <head> <title>My Weblog :: Member details</title> </head> <body> <h1>Info about <%member(name)%></h1> Website: <a href="<%member(url)%>"><%member(url)%></a> <h1>Send Message</h1> <%membermailform%> </body> </html> This will show the members name, website address and a mailform. Skins: Image PopupUsed 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. Very basic buildup for an imagepopup page: <html> <head> <title><%imagetext%></title> <style type="text/css"> img { border: none; } </style> </head> <body> <a href="javascript:window.close();"><%image%></a> </body> </html> Shortnames & Display NamesWeblogs, templates and skin should all have a short name next to the full name or description. A short name consists of only the characters a-z and 0-9, and cannot contain spaces 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. Template: 'New' indication
When the 'last visit' cookie 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 When the 'last visit' cookie is disabled, or the item is not 'new', this template part will not be used. Time variables overviewThe following conversion specifiers are recognized in the format string (taken from the PHP documentation for the strftime function). More info in the Open Group Specification
Ping Weblogs.comWhen updating your weblog, you can choose to send an update notification (ping) to weblogs.com. This website 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. Note: For this feature to work correctly, you need to fill out both the weblog URL and the weblog name in the blogsettings. Always include in searchWhen the 'include in search' option is selected, the weblog will always be included in searches, even if the search is done on another weblog. 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' Convert Linebreaks
By default, Nucleus converts linebreaks in your items to Advanced users, or users striving for the semantic web (br tags don't add any information, they're just used for markup), might find this feature annoying, and turn this feature off. MediaNucleus allows you to upload media files (images, video, sound, ...) to your website Some settings are needed to do this:
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). Uploading is only possible when a member is on the team of at least one of the blogs, to prevent abuse. Protect Member NamesWhen this option is enabled, non-logged in members cannot add comments using the same name as registered members. The reason to do this would be to avoid guest impersonating members. Plugin URLThis setting is the base URL for plugin admin areas. Usually it will look like the following http://hostname.com/nucleus/plugins/ Skins URLThis setting is the base URL for the Nucleus skins directory. Usually it will look like the following http://hostname.com/skins/ Action URLThis setting is the absolute URL of the http://hostname.com/actions.php Adding itemsWhen adding items to a weblog, there are four kinds of template variables that you can use in the body text, title or extended part:
Usually, these tags are inserted by the 'insert media' button in the JavaScript toolbar Skinvar: refererInserts the refering URL (can be empty) ArgumentsNone Skintypesall Examples<a href="<%referer%>">back</a> Skinvar: itemidInserts the ID of the currently selected item ArgumentsNone Skintypesitem Examples<%itemid%> Skinvar: itemlinkAdds a permanent link for the item. ArgumentsOptional
Skintypesitem Examples<%itemlink%> Skinvar: itemtitleInserts the title of the item, with HTML-stripped off and entities encoded ArgumentsNone Skintypesitem Examples<%itemtitle%> Skinvar: archivedateInserts a formatted date for an archive date. Using no parameters, this will either insert '15 august 2002' or 'august 2002' if the archive is for august 2002 Arguments
Skintypesarchive ExamplesArchive for <%archivedate%> Archive for <%archivedate(dutch)%> Archive for <%archivedate(en,%B %Y)%> Skinvar: blogInserts the most recently added items of the currently active blog (usually the default one) into the skin. ArgumentsRequired:
Skintypesindex, item, archive, archivelist, search Examples<%blog(default,15)%> <%blog(default,5(15))%> <%blog(mytemplate)%> <%blog(mytemplate,5,mycategory)%> Skinvar: otherblogInserts the most recently added items of a given blog into the skin. ArgumentsRequired:
Skintypesall Examples<%otherblog(myblog,default,15)%> <%otherblog(yourblog,mytemplate)%> <%otherblog(yourblog,mytemplate,15,mycategory)%> <%otherblog(yourblog,mytemplate,5(15),mycategory)%> Skinvar: itemShows the currently selected item (without comments) using a given template Arguments
Skintypesitem Examples<%item(mytemplate)%> Skinvar: commentsShows the comments for the currently selected item using a given template. Arguments
Skintypesitem Examples<%comments(mytemplate)%> Skinvar: archiveShows the archive for the selected month and the selected blog (usually the default one), using a given template ArgumentsRequired
Skintypesarchive Examples<%archive(mytemplate)%> <%archive(mytemplate,mycategory)%> Skinvar: otherarchiveShows the archive for the selected month, using the given blog and template ArgumentsRequired
Skintypesarchive Examples<%otherarchive(myblog,mytemplate)%> <%otherarchive(myblog,mytemplate,mycategory)%> Skinvar: archivelistShows the list of available archives for the currently selected blog (usually the default one), using a given template ArgumentsRequired
Skintypesindex, archive, archivelist, search, item Skinvar: archivedaylistThe same as the archivelist skinvar, but shows an entry for each day instead of for each month ArgumentsRequired
Skintypesindex, archive, archivelist, search, item Examples<%archivedaylist(mytemplate)%> <%archivedaylist(mytemplate,mycategory)%> Skinvar: otherarchivedaylistThe same as the otherarchivelist skinvar, but shows an entry for each day instead of for each month ArgumentsRequired
Skintypesall Examples<%otherarchivedaylist(yourblog,mytemplate)%> <%otherarchivedaylist(yourblog,mytemplate,mycategory)%> Skinvar: otherarchivelistShows the list of available archives for a given blog, using a given template ArgumentsRequired
Skintypesall Examples<%otherarchivelist(yourblog,mytemplate)%> <%otherarchivelist(yourblog,mytemplate,mycategory)%> Skinvar: categorylistInserts a list of categories for a blog (defaults to the currently selected blog), using a given template ArgumentsRequired
Skintypesindex, archive, archivelist, search, item Examples<%categorylist(mytemplate)%> <%categorylist(mytemplate,myweblog)%> Skinvar: categoryInserts some information about the currently selected category. When no category is selected, does nothing. ArgumentsOptional
Skintypesall Examples<%category%> <%category(id)%> <%category(desc)%> <%category(name)%> Skinvar: ifcatDeprecated as of Nucleus v2.0. Use <%if(category)%> instead. ArgumentsNone
Skintypesall Examples<%ifcat(Current Category: )%><%category%> Skinvar: searchresultsShows the searchresult for the current query ArgumentsRequired:
Skintypessearch Examples<%searchresults(mytemplate)%> Skinvar: othersearchresultsShows the searchresult in a give blog for the current query, using the given template ArgumentsRequired:
Skintypessearch Examples<%othersearchresults(myblog,mytemplate)%> Skinvar: versionInserts the current Nucleus version. ArgumentsNone Skintypesall Examples<%version%> Skinvar: previtemInserts the ID of the previous item in the blog ArgumentsNone Skintypesitem Examples<%previtem%> Skinvar: nextitemInserts the ID of the next item in the blog ArgumentsNone Skintypesitem Examples<%nextitem%> Skinvar: nextitemtitleInserts the title of the next item in the blog ArgumentsNone Skintypesitem Examples<%nextitemtitle%> Skinvar: previtemtitleInserts the title of the previous item in the blog ArgumentsNone Skintypesitem Examples<%previtemtitle%> Skinvar: prevarchive
Inserts the
ArgumentsNone Skintypesarchive Examples
Skinvar: nextarchive
Inserts the
ArgumentsNone Skintypesarchive Examples
Skinvar: archivetypeEither day or month, indicating which type of archive is currently being shown ArgumentsNone Skintypesarchive Skinvar: todaylinkInserts a link to the main page of the weblog. Takes into account the currently selected blog and category. ArgumentsOptional
Skintypesall Examples<%todaylink%> Skinvar: archivelinkInserts a link to the archive for the currently selected blog and category (or the default blog when no blog selected) ArgumentsOptional
Skintypesall Examples<%archivelink%> Skinvar: nextlinkInserts a link to the next item (on item pages) or to the next archive (on archive pages) ArgumentsOptional
Skintypesitem, archive, search, index Examples<%nextlink%> Skinvar: prevlinkInserts a link to the previous item (on item pages) or to the previous archive (on archive pages). For search and index pages ArgumentsOptional
Skintypesitem, archive, search, index Examples<%prevlink%> Skinvar: errormessageInserts the message corresponding to the error that occurred ArgumentsNone Skintypeserror Examples<%errormessage%> Skinvar: imagetextThis skinvar is deprecated since Nucleus v2.0. You should use Inserts the caption text for a popup image ArgumentsNone Skintypesimagepopup Examples<%imagetext%> Skinvar: imageInserts the selected image (for popup images) ArgumentsOptional
Skintypesimagepopup Examples<%image%> Skinvar: varsThis skinvar is deprecated since Nucleus v2.0. It's a small pain to insert this HTML yourself using the itemid skinvar Inserts a hidden form-input field with the itemid. <input type="hidden" name="itemid" value="1234" />
ArgumentsNone Skintypesitem Skinvar: sitevarIncludes a site variable Arguments
Skintypesall Examples<%sitevar(name)%> <%sitevar(url)%> <a href="mailto:<%sitevar(email)%>">Admin</a> Skinvar: blogsettingInserts a setting specific to the currently selected blog (usually the default one) Arguments
Skintypesindex, archive, archivelist, search, item, member Examples<%blogsetting(name)%> <%blogsetting(id)%> <%blogsetting(desc)%> <a href="<%blogsetting(url)%>">...</a> Skinvar: memberInserts some info about on the currently logged in member. On member detail pages, extra options are available to show the same information for the requested member. When the visitor is not logged in, the your... parameters will insert nothing Arguments
Skintypesall Examples
Skinvar: previewInserts an item-preview into the page, using a given template (to be used in conjunction with additemform) Arguments
Skintypesindex Examples<%preview(mytemplate)%> Skinvar: adminurlInserts the full URL to the Admin Area ArgumentsNone Skintypesall Examples<a href="<%adminurl%>">Admin Area</a> Skinvar: additemformShows an add-item form for the currently selected blog (usually the default one). Mostly used in conjunction with preview ArgumentsNone Skintypesindex Examples<%additemform%> Skin/Templatevar: includeIncludes a textfile into the output. The contents of the file is not parsed in any way, so you cannot use skin/templatevars or use PHP code (see parsedinclude and phpinclude if you want parsed includes) Arguments
Notes
Skintypesall Examples<%include(filename.txt)%> <%include(/home/user/myself/filename.txt)%> <%include(http://mydomain.com/filename.html)%> Skin/Templatevar: phpincludeIncludes a php-file into the output. The contents of the file is parsed by the PHP parser, so be careful. Nucleus skin/templatevars are not parsed! (see parsedinclude and include for other include options). Arguments
Notes
Skintypesall Examples
Skin/Templatevar: phpinclude : varsThe following global variables are accessible from within files included by the phpinclude skin/templatevar:
$GATEWAY_INTERFACE, $SERVER_NAME, $SERVER_SOFTWARE
For others variables, you'll need to add 'global $varname;' explicitly in your code Skin/Templatevar: parsedincludeIncludes a file into the output. The contents of the file is parsed by the Nucleus skin/template parser, so you can use skin/templatevars. (see phpinclude and include for other include options) Arguments
Notes
Skintypesall Examples<%parsedinclude(filename.txt)%> <%parsedinclude(/home/user/myself/filename.txt)%> Skin/Templatevar: pluginCalls a plugin Arguments
Notes
Skintypesall Examples<%plugin(Calendar)%> <%plugin(LastComments,myweblog)%> <%LastComments(myweblog)%> Skinvar: loginformAdds a loginform, or shows a "You are karma (Log out)" message ArgumentsNone Skintypesall Examples
Skinvar: commentformAdds a commentform to an item page. ArgumentsOptional:
Skintypesitem Examples<%commentform%> <%commentform(http://host/thanks.html)%> Skin/Templatevar: setSets a parser property. Arguments
Skintypesall Examples<%set(IncludeMode,skindir)%> <%set(IncludePrefix,somedir/)%> Skin/Templatevar: skinfileUsed by imported skins to put a link relative to the skins-URL. Use it in conjunction with the IncludePrefix parser property to get the best results Arguments
Skintypesall Examples<%skinfile(mystyle.css)%> Skin/Templatevar: skinnameInserts the name of the skin that's currently being used. ArgumentsNone Skintypesall Examples<%skinname%> Skinvars: if/else/endifInserts a content block only when certain conditions are fullfilled ArgumentsOnly the
Condition types
Skintypesall Examples<%if(loggedin)%> Welcome back! <%else%> Welcom guest! <%endif%> <%if(category,catname,Off Topic)%> Welcome to the 'Off Topic' category. <%endif%> NotesIf you want something to be displayed only if a condition is not fullfilled, you can use a construct like this: <%if(skintype,error)%><%else%> <%blogsetting(name)%> <%endif%> Skinvar: membermailformShows a form through which a logged-in member can send a message to the member which details are being shown (on member detail pages) ArgumentsOptional:
Skintypesmember Examples<%membermailform%> Skinvar: searchformShows a search form for the current blog. ArgumentsOptional:
Skintypesindex, archive, archivelist, search, item Examples<%searchform%> <%searchform(otherweblog)%> Skinvar: nucleusbuttonInserts a nucleus button, with link to the Nucleus website. ArgumentsOptional:
Notes
Skintypesall Examples<%nucleusbutton%> <%nucleusbutton(nucleus/nucleus.gif,46,43)%> Skinvar: selfInserts the filename of the page currently being displayed (index.php or whatever you changed it to) ArgumentsNone Skintypesall Examples<%self%> Template variables: OverviewWhat?Template variables largely work in exact the same way as skin variables, with the only difference that they are being used inside templates. The variables are called using Available variablesThese template variables be used in the following template-parts: item header, item body, item footer, date header, date footer, morelink, editlink (The variables image, popup and media can also be used inside weblog items.)
Comments-related template-parts (comments header, comments body, comments footer, one comment, two comments, comments read more, no comments, too much comments) have a different set of available variables: Template variables: Basic variablesAll these variables concern the item that's currently being parsed.
Template variables: Advanced variables
Template variables: Comments
Templatevar: karmaInserts karma votes data. Karma votes are a method to vote the 'karma' of an item. With a single click, the visitor can vote either positive or negative. The total of all these votes gives an idea of how much an item is liked by the visitors Arguments
Examples
Templatevar: templateitemtitleOn comments-releated templateparts, inserts the title of the associated item. Arguments
Templatevar: authorInserts the name of the author Arguments
Examples
Templatevar: smartbodyExamines the current item and then decides to show either the body text or the expanded text. When the extended part is empty, the body part is chosen. Otherwise the extended part is shown.
Example useThe body text could be interpreted as your full text, and the extended part could be interpreted as an 'introduction' or 'exerpt', which you want to show on the front page. In the template used on the front page, you would use <%smartbody%> to insert an excerpt (if there is one), or the full text (if no excerpt). In the template for detailed items, <%body%> can then be used instead of the usual <%body%> + <%more%>, since <%body%> will contain the full item anyway. Templatevar: morelinkInserts a link to the detail page for the item, as defined in the template (link to extended entry). This is empty when there is no extended part. Note that the contents of the 'link to extended entry' templatepart is also parsed and can thus also contain templatevariables. Templatevar: dateInserts a date using the date format specified in the template. Optionally, a custom date format can be given as a parameter. Arguments
SpecialsFour special parameters are possible:
Examples<%date%> <%date(%x)%> <%date(rfc822)%> <%date(rfc822GMT)%> Templatevar: timeInserts a time using the time format specified in the template. Optionally, a custom time format can be given as a parameter. Arguments
Examples<%time%> <%time(%X)%> Templatevar: commentsInserts a comments 'block'. More information about the structure of this block. ArgumentsOptional:
Examples<%comments%> <%comments(5)%> Templatevar: syndicate_titleInserts the title of the item, with HTML tags-stripped off, and shortened to 100 characters. When the text needs to be shortened, "..." is added at the end of the text. This variable was originally intended for use in the XML-RSS skin that comes with Nucleus, but can also be of use in other situations. Arguments
Examples<%syndicate_title%> <%syndicate_title(25)%> Templatevar: syndicate_descriptionInserts the body of the item, with HTML tags-stripped off, and shortened to 250 characters. When the text needs to be shortened, "..." is added at the end of the text. This variable was originally intended for use in the XML-RSS skin that comes with Nucleus, but can also be of use in other situations. Arguments
Examples<%syndicate_description%> <%syndicate_description(25)%> Templatevar: imageInserts an inline image into an item body or template. In normal use, the image-templatevar is generated automatically when adding images through the media library. You can call it from within templates too, though. Note that in this last case, the image will come out of the media dir of the current item's author. Arguments
Examples<%image(myphoto.jpg|100|200|this is me)%> <%image(myphoto.jpg|50%|50%|this is me, but smaller)%> Templatevar: popupInserts a popup image into an item body or template. In normal use, the popup-templatevar is generated automatically when adding images through the media library. You can call it from within templates too, though. Note that in this last case, the image will come out of the media dir of the current item's author. Arguments
Examples<%popup(myphoto.jpg|100|200|this is me)%> <%popup(myphoto.jpg|50%|50%|this is me, but smaller)%> Templatevar: mediaInserts a media object into an item body or template. In normal use, the media-templatevar is generated automatically when adding images through the media library. You can call it from within templates too, though. Note that in this last case, the object will come out of the media dir of the current item's author. Arguments
Examples
Templatevar: editFrom within your template, you can add an 'edit item' link by using this template variable. By default, it will link to a popup-bookmarklet-window, but that behaviour can be changed through the editlink template. Note: only logged in members that are allowed to edit the item will see this link. In other cases, the edit-templatevar does nothing at all. ExampleAn example for the item body template
Results inTemplatevar: editlinkInsert a link to the 'edit item' bookmarklet. This can be used in the editlink template for simplicity. ExampleThe 'edit link'-template could look like this: <a href="<%editlink%>" onclick="<%editpopupcode%>">edit</a> - Templatevar: editpopupcodeTo open a popup window for the 'edit link' window, you'll need to add some javascript code to your link. To avoid having to enter this code in the 'edit link'-template, you can insert it using the editpopupcode-templatevar. ExampleSee the example for the editlink templatevar PluginsNucleus allows you to install custom plugins, adding extra functionality. Plugins can do different things:
Note that the responsibility for plugins is entirely with the plugin author. He should make sure that everything works fine. Parser PropertiesThe available parser options are described below.
The IncludePrefix and IncludeMode properties can be set globally for a skin in the general settings of a skin. Also note that from the moment a property is set, it applies to all parsed data, thus also for templates. |
|
|