I had hoped that creating a link such as
<a href="[~11~]">Research</a>
would result in a link with a "title" field such as
<a href="index.php?q=research" title="Papers and Reports">Research</a>
where "Papers and Reports" came from the "Description" field of page 11. The DropMenu snippet seems to do this. How can I convince MODx to create such links for *all* links?
Thanks,
--Michael
[~11~] just substitutes for the URL of document 11. It doesn’t know what you’re doing with it. You’d have to run a snippet to get the description, and code like this:
<a href="[~11~]" title="[[getdescription? &docid=`11`]]>Research</a>
I have made this snippet up. I don’t know if a suitable one exists.
GetField is your new friend.
http://modxcms.com/getField-667.html
<a href="[~11~]" title="[[GetField? &field=`description` &docid=`11`]]>Research</a>