Topic on Extension talk:Cite

filling references with a template

3
Zabien (talkcontribs)

Hello, within a template I have fields for filling the references, which look like this: <ref>Source: {{{Source Spanish|}}}</ref>. In the same template there is also the <references /> tag. Now, when using the template, I simply fill |Source Spanish=http://www.example.com. But under references, the URL won't show, it's only 1. Source: , without the template field value.

  • It's not related to the URL, any other text won't show either.
  • The position of <references /> is irrelevant, same outcome everywhere.

What am I missing?

קיפודנחש (talkcontribs)

i believe you should use the #tag: magic word if you want to use "ref" tag from inside a template.

see Help:Magic_words#Miscellaneous.

as to the "references" tag: it does not sound right to have this tag in the same template - this will place "references" once per each reference, instead of once for the whole page.

also, afair, if you use modern-enough version of the code, you can completely omit the "references" tag, to display the references at the end of the page. don't remember when was this introduced, and TBH, i am not 100% sure this is correct...

peace.

Zabien (talkcontribs)

Thank you very much! That hint did it! Works brilliantly with the #tag magic word and "ref". I do not yet see a problem with the <references /> tag, though. At the moment, the references passed via the form as well as manually added <ref>…</ref>s all neatly show up under references. I still need the tag to show them, I tried on 1.21.2 and 1.23.1 and it's demanded there. Not tried on 1.24 though.

Reply to "filling references with a template"