1. Getting Started
      1. Basic Installation
      2. What is MODx
    2. Content Editing
      1. Editing Documents
      2. MODx Tags
        1. Document Variables
      3. Terminology
      4. The Manager
      5. Who Should Read This
    3. Designing
      1. Adding Chunks
      2. Adding MODx Tags
        1. Resource Fields
      3. Adding Snippets
      4. Document Caching
      5. Template Basics
    4. Administration
      1. Friendly URL Solutions
      2. Manager Users
        1. Manager Roles And Groups
        2. Reset your Password - Unblock your User
        3. Why Manager Users, Roles and Groups
      3. Moving Site
      4. Taking sites down for maintenance
      5. Upgrading
      6. Web Users
        1. Creating a Web User
        2. Web User Groups and Document Groups
        3. Why Web Users and Groups
    5. Developer's Guide
      1. API Reference
        1. DBAPI
          1. delete
          2. escape
          3. getInsertId
          4. query
          5. select
          6. update
        2. Document Object
        3. DocumentParser Object
          1. addEventListener
          2. changeWebUserPassword
          3. documentContent
          4. documentGenerated
          5. documentIdentifier
          6. documentListing
          7. documentMethod
          8. documentObject
          9. getAllChildren
          10. getCachePath
          11. getChildIds
          12. getDocumentChildren
          13. getDocumentChildrenTVarOutput
          14. getDocumentChildrenTVars
          15. getLoginUserID
          16. getLoginUserName
          17. getLoginUserType
          18. getManagerPath
          19. getParent
          20. getParentIds
          21. getUserData
          22. hasPermission
          23. isBackend
          24. isFrontend
          25. logEvent
          26. maxParserPasses
          27. minParserPasses
          28. regClientCSS
          29. runSnippet
          30. table_prefix
          31. tstart
          32. webAlert
      2. Chunks
      3. Modules
        1. How to create and run a module from within the Content Manager
        2. Managing module dependencies
        3. Setting up configuration parameters
        4. Writing the module code
      4. Plugins
      5. Snippets
      6. Template Variables
        1. (at) Binding
          1. (at)CHUNK
          2. (at)DIRECTORY
          3. (at)DOCUMENT
          4. (at)EVAL
          5. (at)FILE
          6. (at)INHERIT
          7. (at)SELECT
          8. What are (at) Bindings
        2. Creating a Template Variable
        3. What are Template Variables
        4. Widgets
          1. Misc. Widget
          2. DataGrid Widget
          3. Floater Widget
          4. Hyperlink Widget
          5. Marquee Widget
          6. RichTextBox Widget
          7. Ticker Widget
          8. Viewport Widget
          9. What are Widgets

Resource Fields

This is a listing of all of the (currently) available document-specific resource fields. Each one is a field in the MODX site_content table. They are accessed with [*resource-field-name*] tags. These values can also usually be retrieved from the array.

$modx->documentObject['resource-field-name']
  • id - The document's ID. Can also be obtained with $modx->documentIdentifier.
  • type - Whether document, folder or weblink.
  • contentType - The content type, such as text/html.
  • pagetitle - The title of the page.
  • longtitle - The longtitle of the page.
  • description - The description of the page.
  • alias - The alias of the page. Used in creating Friendly URLs.
  • link_attributes - The Link Attributes of the page, eg. rel=, target= etc.
  • published - [0|1] Whether or not the document is published.
  • pub_date- Date the document is to be published. This is not a "normal" date, and must be processed by a script for meaningful output.
    Example: strftime("%d/%m/%y %H:%M:%S", $value)
    
  • unpub_date - Date the document is to be unpublished. See 'pub_date'.
  • parent - The ID of the document's parent.
  • isfolder - [0|1] Whether or not the document is a folder.
  • introtext - The summary of the document.
  • content - The content of the document.
  • richtext - [0|1] Whether or not a RichText Editor is to be used when editing the document.
  • template - The ID of the template to used for the document.
  • menuindex - The order in which the document is to be listed in the menu.
  • searchable - [0|1] Whether or not the document is to be searchable.
  • cacheable - [0|1] Whether or not the document is to be cached.
  • createdby - The user ID of the creator of the document.
  • createdon - The date the document was created. See pub_date.
  • editedby - The ID of the user who last edited the document.
  • editedon - The date the document was last edited. See pub_date.
  • deleted - [0|1] Whether or not the document has been deleted (but not yet completely removed from the database by emptying the trash).
  • deletedon - The date the document was deleted. See pub_date.
  • deletedby - The ID of the user who deleted the document.
  • menutitle - The title to be shown in the menu. If empty, the pagetitle is used.
  • donthit - [0|1] Disable page hit count for the document.
  • haskeywords - [0|1] Whether or not the document has links to keywords.
  • hasmetatags - [0|1] Whether or not the document has links to meta tags
  • privateweb - [0|1] Whether or not this document has been assigned to a private web document group.
  • privatemgr - [0|1] Whether or not this document has been assigned to a private manager document group.
  • content_dispo - [0|1] Whether the document's content-disposition is attachment or inline.
  • hidemenu - [0|1] Whether or not the document is to be hidden in the menu.

Suggest an edit to this page on GitHub (Requires GitHub account. Opens a new window/tab).