We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 21301
    • 93 Posts
    I’m working on a PDF link on my pages that generates a PDF version of the document. I’d like to create a template that generates the PDF and then use the ChangeTemplate plugin to call the page with the PDF template instead of the HTML template.

    The problem is that I can’t specify a content type for a template. So I have to create a document, assign it the ’application/pdf’ content type and have a plugin read the id-parameter which then fetches the appropriate content for the page and spit it out in PDF.

    It would be a lot easier (and makes more sense to me) to be able to set the content type for a template.

    The CSS files I use now have a ’blank’ template assigned and have the CSS content type. I’d make more sense if you could simply create and assign a CSS template. Same goes for other content types like eg XML.

    And the content disposition option is also candidate for the template if you ask me.

    Does this make sense? Or am I missing the point of templates here?

    (using TP 3.2)
    • That’s some very good insight theo. Can you log a feature request in the bugtracker?
        Ryan Thrash, MODX Co-Founder
        Follow me on Twitter at @rthrash or catch my occasional unofficial thoughts at thrash.me
        • 21301
        • 93 Posts
        Done under task #79
        • Thanks. For reference for everyone, if you want ot make 100% certain your requests get the appropriate attention, as well as bugs of course, please log them as feature requests in the bug tracker. Thanks!
            Ryan Thrash, MODX Co-Founder
            Follow me on Twitter at @rthrash or catch my occasional unofficial thoughts at thrash.me