plainblack.com
Username Password
search
Bookmark and Share

macro

Related Pages

  • Company Email Macro
    ^e; The email address for your company specified in the settings by your Administrator.
  • Company Name Macro
    ^c; The name of your company, specified in the settings by your Administrator.
  • Company URL Macro
    ^u; - Company URL The URL for your company specified in the settings by your Administrator.
  • Date Macro
    ^D(); ^D([date formatting code],[epoch date]); The current date and time.
  • Editable Toggle Macro
    ^EditableToggle; or ^EditableToggle(); Exactly the same as AdminToggle, except that the toggle is only displayed if the user has the rights to edit the current Asset. This macro takes up to three parameters. The first is a label for "Turn Admin On", the second is a label for "Turn Admin Off", and the third is the name of a template in the Macro/EditableToggle namespace to replace the default template.
  • Environment Variable Macro
    ^Env(); Can be used to display a web server environment variable on a page. The environment variables available on each server are different. Please consult the documentation for your server for a list of them.
  • Execute Macro
    ^Execute(); Allows a content manager or administrator to execute an external program. Takes the format of ^Execute("/this/file.sh");.
  • Extras Macro
    ^Extras; or ^Extras(path/to/something/in/extras/folder); Returns the path to the WebGUI "extras" folder, which contains things like WebGUI icons.
  • Fetch MIME Type Macro
    ^FetchMimeType; ^FetchMimeType(file system path to file); Returns the MIME type for a file. An absolute or relative file path to the file is required. A URL to the file will not work.
  • File URL Macro
    ^FileUrl(); ^FileUrl(Asset URL); This macro is used to return a filesystem URL to an Asset which stores a single file (File, Image, ZipArchive, etc.) identified by its Asset URL. The Macro will not work on Assets which store multiple files, such as the Post or Article Assets.
  • Form Parameter Macro
    ^FormParam(); This macro is mainly used in populating forms with data the user previously submitted so they don't have to retype it. Using this macro, you can pull the value of any form field simply by specifying the name of the form field, like this: ^FormParam(phone);
  • Gateway URL Macro
    ^/; - System URL ^/(/home/page); - System URL The URL to the gateway script (example: /).
  • Group Add Macro
    ^GroupAdd(); Using this macro you can allow users to add themselves to a group. The first parameter is the name of the group this user should be added to. The second parameter is a text string for the user to click on to add themselves to this group. The third parameter allows you to specify the name of a template in the Macro/GroupAdd namespace to replace the default template.
  • Group Delete Macro
    ^GroupDelete(); Using this macro you can allow users to delete themselves from a group. The first parameter is the name of the group this user should be deleted from. The second parameter is a text string for the user to click on to delete themselves from this group. The third parameter allows you to specify the name of a template in the Macro/GroupDelete namespace to replace the default template.
  • Group Text Macro
    ^GroupText(); Displays a small text message to the user if they belong to the specified group. And you can specify an alternate message to those who are not in the group.
  • Home Link Macro
    ^H; or ^H(); - Home Link A link to the home page of this site. In addition you can change the link text by creating a macro like this ^H("Go Home");.
  • If Macro
    N.B. In 7.6.0 the old ^If(); Macro was removed from WebGUI. In 7.6.4 a new macro was introduced, which tests whether a given string is non-empty or not. This new macro is confusingly also called ^If();, so if you upgrade from <7.6.0 to >=7.6.4 and use ^If(); on your site, you're in for a big surprise. None of the examples below work with the new ^If();, which considers all of the given conditions to be always true, because they all contain a non-empty string.
  • Include Macro
    ^Include(); Allows a content manager or administrator to include a file from the local filesystem.
  • International Macro
    ^International(); ^International(key,namespace); Pull a translated message key from the internationalization system.  By default, it looks in the WebGUI namespace.  A different namespace can be specified as a second, optional argument.
  • Spacer Macro
    ^Spacer("width","height"); Create a spacer in your layout. Great for creating blocks of color with divs and tables. It takes two parameters, width and height.
  • SQL Macro
    ^SQL(); A one-line SQL report that can be used on the WebGUI database or any database with which you have established a database link. Sometimes you just need to pull something back from the database quickly. This macro is also useful in extending the SQL Report wobject. It uses the numeric macros (^0; ^1; ^2; etc) to position data and can also use the ^^rownum; macro just like the SQL Report wobject.
  • Thumbnail Macro
    ^Thumbnail(url); This macro will allow you to fetch the filesystem URL for the thumbnail of any File or Image Asset by its Asset URL.
  • User ID Macro
    ^#; - User ID The user id of the currently logged in user.
  • User Macro
    ^User(); This macro will allow you to display any information from the current user's account or profile. For instance, if you wanted to display a user's email address you'd create this macro: ^User("email");
  • User Name Macro
    ^@; - Username The username of the currently logged in user.
Most Popular | Recent Changes | Wiki Home
© 2018 Plain Black Corporation | All Rights Reserved