Topic on Project:Support desk

Is this possible to do?

7
50.80.25.170 (talkcontribs)

Is it possible to, without extensions, to have a page show how far a number is from another number?

In other words, I want a page to say "This year was X years ago.", and X is the current year (Which I can set manually, as this is a wiki about another fictional universe) minus the name of the page.

I can't add extensions, as I'm using a wikihost that doesn't let you do that.

Bawolff (talkcontribs)
Jeffwang (talkcontribs)

What host are you on?

50.80.25.170 (talkcontribs)

Wikkii: []

There are installed extensions, and one of them is ParserFunctions.

Bawolff (talkcontribs)

In that case you can use {{#expr: to do calculations. For example This year was {{#expr:{{CURRENTYEAR}} - {{{1}}} }} years ago creates a template that does what you describe. See help:Extension:ParserFunctions for details.

Jeffwang (talkcontribs)

Then shouldn't the year thing work? If you're having problems MyWikis can help you all you need. We already have TONS of extensions installed. See?

50.80.25.170 (talkcontribs)

I didn't know that you could use ParserFunctions for things like that so that's why I asked how I could do it. But now I do so it's solved the problem.


And thanks to everyone for the help.

Reply to "Is this possible to do?"