Nesting a magic word within a string function?

Jump to: navigation, search

I'm trying to execute the following function on every page that exists for an uploaded file: {{filepath:{{PAGENAME}}.pdf}}

So, if I uploaded a file called "File.pdf", on the wiki page for File.pdf, I'd expect {{PAGENAME}} to return "File". I'd expect the entire function to return something like: http://mywiki.com/mediawiki/images/4/4d/File.pdf

Instead, nothing at all is returned when PAGENAME is embedded within filepath. If I type the expression without {{PAGENAME}}, i.e. {{filepath:File.pdf}}, it works fine and returns: http://mywiki.com/mediawiki/images/4/4d/File.pdf

Is it just not possible to embed magic words in string functions, or am I missing some escape character or something?

Thanks in advance,

UPDATE: This can be done by simply writing {{filepath:{{PAGENAME}}}} the ".pdf" part is unnecessary.
Danachandler00:57, 22 January 2012

{{PAGENAME}} already includes the file extension. Use {{filepath:{{PAGENAME}}}}.

Subfader12:11, 22 January 2012
 
Personal tools

Variants
Actions
Navigation
Support
Download
Development
Communication
Toolbox