<![CDATA[ List of all supported template tags? - MODX Community Forums]]> https://forums.modx.com/thread/?thread=14905 <![CDATA[Re: List of all supported template tags?]]> https://forums.modx.com/thread/14905/list-of-all-supported-template-tags?page=2#dis-post-80948

(for those who stumble upon this thread like I did)]]>
artifex Aug 19, 2011, 12:29 PM https://forums.modx.com/thread/14905/list-of-all-supported-template-tags?page=2#dis-post-80948
<![CDATA[Re: List of all supported template tags?]]> https://forums.modx.com/thread/14905/list-of-all-supported-template-tags?page=2#dis-post-80947
But adding a snippet for this trivial task looks too much.
I’ll just type the pagetitle manually, instead. undecided
The request has been submitted, though.]]>
goldsky Aug 08, 2011, 05:39 AM https://forums.modx.com/thread/14905/list-of-all-supported-template-tags?page=2#dis-post-80947
<![CDATA[Re: List of all supported template tags?]]> https://forums.modx.com/thread/14905/list-of-all-supported-template-tags?page=2#dis-post-80946
[[GetPagetitle? &pageId = 2]]

/* GetPagetitle snippet */
$resource = $modx->getObject('modResource', $pageId));
return $resource->get('pagetitle');

This might be more efficient (though I’m not sure I have it right):

/* GetPagetitle snippet */
/* build a new xPDOQuery object, similar to getObject() */
$query = $modx->newQuery('modResource', $pageId);

/* indicate you only want to select the pagetitle column */

/* prepare the PDOStatement and execute it directly */
if ($query->prepare() && $query->stmt->execute()) {
    /* use PDOStatement->fetchColumn() to just get the first column of 
           the current row of the result set */

BobRay Aug 08, 2011, 04:48 AM https://forums.modx.com/thread/14905/list-of-all-supported-template-tags?page=2#dis-post-80946
<![CDATA[Re: List of all supported template tags?]]> https://forums.modx.com/thread/14905/list-of-all-supported-template-tags#dis-post-80945 I wonder this exists (have tried and failed):

<a href="[[~2]]" title="[[~2:pagetitle]]">[[~2:pagetitle]]</a>

Using ’?’ on the link creates a GET parameter.

<a href="[[~2]]" title="[[~2? &get=`pagetitle`]]">[[~2? &get=`pagetitle`]]</a>
So this one is not an option.]]>
goldsky Aug 08, 2011, 03:55 AM https://forums.modx.com/thread/14905/list-of-all-supported-template-tags#dis-post-80945
<![CDATA[Re: List of all supported template tags?]]> https://forums.modx.com/thread/14905/list-of-all-supported-template-tags#dis-post-80944
If you click on the Freeze URI checkbox on the page settings tab, an input field will appear where you can set the URI for the resource. It will appear in the URL when the page is accessed and won’t change no matter if the page is moved or the alias is changed.

uri_override is the checkbox value and uri is the value you entered in the URI field.]]>
BobRay Apr 18, 2011, 04:35 PM https://forums.modx.com/thread/14905/list-of-all-supported-template-tags#dis-post-80944
<![CDATA[Re: List of all supported template tags?]]> https://forums.modx.com/thread/14905/list-of-all-supported-template-tags#dis-post-80943
* uri_override
* uri

All the others make sense to me, but those 2 seems out of place. Where did they come from?

I’m adding these all to the official wiki:
Everettg_99 Apr 18, 2011, 08:19 AM https://forums.modx.com/thread/14905/list-of-all-supported-template-tags#dis-post-80943
<![CDATA[Re: List of all supported template tags?]]> https://forums.modx.com/thread/14905/list-of-all-supported-template-tags#dis-post-80942 einsteinsboi Apr 15, 2011, 02:16 PM https://forums.modx.com/thread/14905/list-of-all-supported-template-tags#dis-post-80942 <![CDATA[Re: List of all supported template tags?]]> https://forums.modx.com/thread/14905/list-of-all-supported-template-tags#dis-post-80941 BobRay Apr 15, 2011, 09:06 AM https://forums.modx.com/thread/14905/list-of-all-supported-template-tags#dis-post-80941 <![CDATA[Re: List of all supported template tags?]]> https://forums.modx.com/thread/14905/list-of-all-supported-template-tags#dis-post-80940 Everettg_99 Apr 15, 2011, 07:58 AM https://forums.modx.com/thread/14905/list-of-all-supported-template-tags#dis-post-80940 <![CDATA[Re: List of all supported template tags?]]> https://forums.modx.com/thread/14905/list-of-all-supported-template-tags#dis-post-80939 Quote from: Everett at Apr 15, 2011, 02:42 AM

Ack. Yes, I wrote that page. I was wanting to complete it but I can’t find a full list and I know I’m leaving things out, e.g. publishedon... author... probably others... but I can’t find a list anywhere.

Here’s a list of the resource fields. I think it’s complete:

§ alias (text — Alias)
§ cacheable (int 0/1 — Cacheable)
§ class_key (int — Class Key of the Resource)
§ content (text — Resource Content)
§ content_type (int — Content Type)
§ createdon (date — Created On date)
§ createdby (int — Created By User ID Number)
§ deleted (int 0/1 — Deleted)
§ deletedby (int — Deleted By User ID Number)
§ deletedon (date — Date of Deletions)
§ description (text — Description)
§ editedon (date — Edited In date).
§ editedby (int — Edited By User ID number)
§ hidemenu (text — Hide From Menus)
§ id (int — Resource ID)
§ introtext (text — Summary)
§ isfolder (int 0/1 — Container)
§ link_attributes (text — Link attributes)
§ longtitle (text — Long Title)
§ menuindex (int — Menu Index)
§ menutitle (text — Menu Title)
§ pagetitle (text — Page Title)
§ parent (int — Parent Resource)
§ pub_date (date —Publish Date)
§ published (int 0/1 — Published)
§ publishedby (int — Published By User ID Number)
§ publishedon (date — Published On)
§ richtext (int 0/1 — Rich Text
§ searchable (int 0/1 — Searchable)
§ template (int — Template ID number)
§ unpub_date (date -- Unpublish Date)
§ uri_override (int 0/1 — Freeze URI)
§ uri (string — URI)
BobRay Apr 15, 2011, 02:05 AM https://forums.modx.com/thread/14905/list-of-all-supported-template-tags#dis-post-80939