Fandom

Community Central

Admin Forum:Template Question

19,031pages on
this wiki
Add New Page
Talk0 Share

Ad blocker interference detected!


Wikia is a free-to-use site that makes money from advertising. We have a modified experience for viewers using ad blockers

Wikia is not accessible if you’ve made further modifications. Remove the custom ad blocker rule(s) and the page will load as expected.

This Forum has been archived

Forums: Admin Central Index Technical Help Template Question
Wikia's forums are a place for the community to help other members.
To contact staff directly or to report bugs, please use Special:Contact.

Hi everyone, I am the administrator on the Adele Wiki, and we have an infobox template for her albums. It can be found here. Anyways, I was working on it today and I added a section to it for her album chronology, and it won't show the links to the preceding and following albums on the album pages. (For example, on this page, under the "Adele Chronology" bar, there should be something that says the name of the current album and the year, and a link to the previous album, and it's not appearing.) Can anyone help? Thanks. ---Tsu'tey♫ 16:49, April 11, 2012 (UTC)

Think I've fixed it -- RandomTime 17:28, April 11, 2012 (UTC)

Thanks, you pretty much did, but the other album page won't work, and it's showing some of the template's code at the top of the 21 page. Also, the bars that says "Singles" and "Adele chronology" are not going entirely across the template (in other words, they need to be longer). Can you help me with that? Thank you so much. =) ---Tsu'tey♫ 12:15, April 12, 2012 (UTC)

Changed a colspan to "3" - seems to have solved -- RandomTime 12:25, April 12, 2012 (UTC)

Thank you so much. =) ---Tsu'tey♫ 12:42, April 12, 2012 (UTC) WAIT! There's another problem -- now it's not working on the other album page, 19. I don't know what happened, 'cause the chronology thing still works on the 21 page. Can you help? Thanks.

I've fixed that page by adding "none" as "Last album" - the way it's set up is that it checks for "Last album" - and doesn't show the discography if it's empty - so it won't show up unless you put in a previous album -- RandomTime 13:36, April 12, 2012 (UTC)
[edit conflict]

The reason it's not working is that you've built it to be dependent on the presence of a {{{Last album}}}. Because 19 is her debut, there is no last, and therefore the logic of your structure demands there is no chronology. You need to change it so that this dependency is removed. There are many ways to do this. One way I'd suggest is that you simply change this:

{{#if:{{{Last album|}}}|
<!--{{{!}}} style="width:100%; background: transparent; text-align: center; font-size: 88%; line-height: 1.4em; vertical-align: bottom"-->
{{!}} style="width: 100%;" {{!}} {{{Last album}}}
{{!}} style="width: 100%;" {{!}} {{{This album}}}
{{!}} style="width: 100%;" {{!}} {{{Next album}}}|
 }}

to

<!--{{{!}}} style="width:100%; background: transparent; text-align: center; font-size: 88%; line-height: 1.4em; vertical-align: bottom"-->
{{!}} style="width: 100%;" {{!}} {{#if:{{{Last album|}}}|{{{Last album}}}}}
{{!}} style="width: 100%;" {{!}} {{{This album}}}
{{!}} style="width: 100%;" {{!}} {{#if:{{{Next album|}}}|{{{Next album}}}}}

With an artist who's just starting out, this is probably sufficient. But infobox navigation can be altered any number of ways. There are any number of bells and whistles that could be added to all this. In any event, this would make something show up on 19. czechout@fandom    fly tardis  <span style="">13:39: Thu 12 Apr 2012 

[/edit conflict]
Incidentally, there is no reason that navigation should ever be dependent on the presence of a "last" or "next" variable. Such a structure will always fail on the first or last page in the sequence. If you want to make navigation something that you could hide — in the case, say, of a one-off item that's not a part of any series — I've found that a helpful thing to do is to simply build a separate variable, say {{{nav}}}, and then say {{{#ifeq:{{{nav}}}|0| |whatever}}.
What this does is to look for the value of a variable called "nav". If nav is exactly equal to 0, then it will display nothing. If it's not equal to 0, then it will print whatever. This makes it so that you have to take the overt step of typing nav=0 for the navigation to disappear, which means there's no mysteries about why there's no navigation. czechout@fandom    fly tardis  <span style="">13:48: Thu 12 Apr 2012 

Also on Fandom

Random Wiki