Timeline for How can I make a template output its own filename?
Current License: CC BY-SA 4.0
6 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
S Dec 16, 2022 at 2:26 | history | suggested | Todd Prouty | CC BY-SA 4.0 |
Clarifies that this answer applies to an old version of Craft.
|
Dec 8, 2022 at 8:14 | review | Suggested edits | |||
S Dec 16, 2022 at 2:26 | |||||
Apr 21, 2017 at 15:09 | comment | added | Alex |
Careful with this; it returns an object of type Twig_Markup , which is then casted to a string. If you need template name strictly as a string, use _self.getTemplateName().__toString
|
|
Jul 8, 2014 at 3:58 | vote | accept | Gareth | ||
Jul 7, 2014 at 21:50 | review | Low quality posts | |||
Jul 7, 2014 at 22:02 | |||||
Jul 7, 2014 at 21:35 | history | answered | Brandon Kelly | CC BY-SA 3.0 |