plainblack.com
Username Password
search
Bookmark and Share

macro

Related Pages

  • Account Macro
    ^a(); ^a([link text], [template name]); This macro creates a link to the current user's account information. The Macro takes two optional arguments, the text that is displayed with the link and a template from the Macro/a_account namespace to be used to display the link and text. If the link text is set to the word "linkonly" then only the URL will be returned.
  • Admin Bar Macro
    ^AdminBar; ^AdminBar(custom template ID); Places the administrative tool bar on the page. Omitting this macro will prevent you from adding content, pasting content from the clipboard, accessing the help system and other administrative functions.
  • Admin Text Macro
    ^AdminText(text message); Displays a small text message to a user who is in admin mode. Example: ^AdminText("You are in admin mode!");
  • Admin Toggle Macro
    ^AdminToggle(); ^AdminToggle([enable admin], [disable admin], [template name]); Places a link on the page which is only visible to content managers and administrators. The link toggles on/off admin mode. You can optionally specify other messages to display like this: ^AdminToggle("Edit On","Edit Off"); This macro optionally takes a third parameter that allows you to specify an alternate template name in the Macro/AdminToggle namespace.
  • AdSpace Macro
    ^AdSpace; ^AdSpace(adName); This macro is used to display advertisements from the AdSpace system on a page. The macro takes a single argument, which is the name of the Ad Space from the AdSpace manager to display from the AdSpace manager. As a convenience, the AdSpace manager will display the macro code to put into a page to display each Ad Space.
  • Areas of Interest Rank Macro
    ^AOIRank(metadata property, [rank]); This macro is for displaying which Assets are the most frequently viewed on your site, based on Metadata and Passive Profiling. To use the macro, you will need to enable Passive Profiling in the WebGUI Settings admin screen, and then add Metadata to the Assets in your site.
  • Asset Proxy Macro
    ^AssetProxy(Asset URL or Asset ID, [type]); This macro is used to render an Asset and display it inline according to its template. Any Asset can be displayed, including Navigations, images, links to files for downloading or for snippets.
  • Can Edit Text Macro
    ^CanEditText(text message); Display a message to a user that can edit the current Asset.
  • Macro Development Tutorial
    A macro is a small Perl package that sits in the lib/WebGUI/Macro folder of your WebGUI install. You enable it by adding a line to your WebGUI config file.  Here is an example of a macro: package WebGUI::Macro::HelloWorld;
  • Product Macro
    *this is the macro used to display products in pre-7.5.11, after that the Product asset should be used.
  • Quote Macro
    ^Quote(); Use this to escape a string before using it in a database query.
  • Random Asset Proxy Macro
    ^RandomAssetProxy(); ^RandomAssetProxy(Asset URL); This macro works similarly to the ^AssetProxy(); macro except instead of displaying the Asset, it picks a random Asset from the descendants of the Asset whose URL is supplied as the argument.
  • Random Macro
    ^*; or ^*(); - Random Number A randomly generated, whole number between 0 and the number you send the Macro. This is often used on images (such as banner ads) that you want to ensure do not cache. You may configure this macro like this ^*(100); to create a random number between 0 and 100. If no number is sent a default of 1 billion (1,000,000,000) will be used.
  • Random Thread Macro
    ^RandomThread( [ startURL, relatives, templateURL ] ); The Collaboration System can be used for much more than just a forum. A few examples of its possible usages are an FAQ, photo gallery, job listings, quotes database or weblog. For these applications (and others that you might think of) it can be nice to display a random entry from such a CS somewhere on your site. That is exactly the functionality that this macro provides.
  • Root Title Macro
    ^RootTitle; Returns the title of the root of the current page. For instance, the main root in WebGUI is the "Home" page. Many advanced sites have many roots and thus need a way to display to the user which root they are in.
Most Popular | Recent Changes | Wiki Home
© 2018 Plain Black Corporation | All Rights Reserved