Hello SuperSka - thanks for your help the other day.
This message is a spin off from a thread concerning tokenising of HTML output and a request for amendments to the module in Bo Norgaards blog.
My preference for a tokenizing system would not be at the module level, but at the rendering stage for all modules. As that will not happen then I am happy that this feature is embedded in the most flexible module.
The syntax is irrelevant but I will assume this
{dnn:(optional if clause) value[;default]}
Type 1 System Data
{dnn:portal} would be replaced by the portal name. This is a system value for which there would be no default as a value would always be returned. Suitable tokens are
date/time, moduletitle/name, pagetitle/name, sitetitle/name, domain, adminemail , hostemail
Type 2 User Data
{dnn:username;Visitor} = Replace token with account user name. Not logged on use the default string Visitor.
userfirstname, userlastname,username,useremail
(and maybe all other account data although I cannot see the use of the rest)
A more complex example
{dnn: if(loggedin) } Hello {dnn: userfirstname} {dnn:endif }
Type 3 Simple Database Data
I can add a token to my site's list of tokens via TextHtml maintenance. It will be replaced at run-time in ALL TextHTML modules that refer to that token. Examples of when I might use this facility could be:
{dnn:webmaster} I can universally replace the web master email address if I start getting spam
{dnn:MaintenanceMessage} - normally empty unless you are doing something.
Type 4 User-based Database data
This is where the data is dependent on the user, but is not stored in the standard account. This is probably too complex to implement as it would need the user to supply the values and probably needs implementing in another module.
Type 5 TextHTML instructions
{dnn:cease} Stop outputting. Allows me to work on a new block of text which will not display until we reach
{dnn:resume}
And a few other thoughts...
{dnn:if (culture==xxx)} Some stuff {dnn:endif}
{dnn:if(culture!=xxx)} iets anders , quelque chose, {dnn:end if}
Good {dnn:if (time < 12:00) } morning {dnn:else} afternoon {dnn:end if}
And finally - I really would like it if TextHTML did not reformat my native HTML.