Creating link to file within website template

Are there any variables (“capitalised words in square brackets”) that can be used which aren’t documented in §25.14. Advanced website templates?

I’d quite like to create a simple link to a “Release along with” file, but [AUXILIARY] contains stuff I don’t want.

(To get round it I could add a hard-coded link in the template to the file, but that would mean I’d need a new website template for another game. Alternatively, I might be able to use Javascript/CSS.)


You can change the template, but I don’t know whether there’s any undocumented variables.

I think the html pages that it spews out should just be considered as a starting point. You can use them as is, if that suits your needs, or customise them to your heart’s content.

Yes. You can look in index.html and play.html files in the Standard and Classic templates and you’ll see things not in the docs like OTHERCREDITS and INBROWSERPLAY in Standard/index.html. And you’ll see some of the things documented aren’t in the templates like TIMESTAMP and DATESTAMP.

But you can make up your own arbitrary placeholders in website templates and whatever value you put for them in ‘(manifest).txt’ in the interpreter template will get substituted.

And neither of these things do you much any good since you’re looking for a way to populate it via the Release statement in the source code, and so far as I know you can’t populate an arbitrary value that way.

Personally, I think it’s a kind of wonky design decision that Inform 7 calls on you to specify all of that in the source code, and that it’s the sort of thing that’s better suited for a configuration file of an external build tool. And @zarf has written such a tool,

But it doesn’t have built-in support for arbitrary placeholders. It’s not hard to add another placeholder to it, but you’d need to add two fields for the link text and the filename and then either further modify the code to copy the file into the release folder or remember to do it manually and by this point I think modifying the html page manually to hard-code your link is sounding pretty good.

Thanks for the replies.

I like the fact that the game and website both come from the game file.

It’s odd that the variables include HTML rather than leaving that to the templates, though, and it would be good to be able to extract more information via this type of variable. doesn’t read the game file but, as you are suggesting, it could in theory.

I’ll likely remove/hide the extraneous HTML from the [AUXILIARY] variable using JavaScript and CSS.

When I did this using JavaScript it flashed up too long before disappearing, so I went back to CSS in the end. I kept most of the existing template so I think this would work in the standard website template too.

/* Get rid of the "(pdf, 438KB)" */	
.filetype {
	display: none;

/* Final li on page, i.e. the "Play in Browser" link */
li:last-child {
	display: none