How do I use/call globals in entries? Trying to insert a simple global called {{ whateveryounameit }} with some text but don't see anything except its name.
Any other ways to display common content across multiple entries?
How do I use/call globals in entries? Trying to insert a simple global called {{ whateveryounameit }} with some text but don't see anything except its name.
Any other ways to display common content across multiple entries?
You call globals with the globals' handle, and the field name of a field in it. So, if you have a text input field named "myField" inside a global with handle "myGlobal", you can call it anywhere in your templates with:
{{ myGlobal.myField }}
if globals don't work for you could create a related entry field that allows you call up previously created content (related blog or news posts as an example). This way you can but reference the same content through multiple entries but only have to create it once.
Here's the Craft docs for Relations
The answer is detailed here: Reference tags inside Matrix textfield
You'll need to use the global set's element ID as the reference part (second segment) of the reference tag:
{globalset:51:siteUrl}
To find the global set's ID, go to CP -> Settings -> Globals. The URL to the global set will have the ID as the last segment (e.g. http://yoursite.craft.dev/admin/settings/globals/51)