Template:tb minversion section

  • Revision slug: Template:Tb_minversion_section
  • Revision title: Template:tb minversion section
  • Revision id: 288971
  • Created:
  • Creator: Sheppy
  • Is current revision? No
  • Comment

Revision Content

<% // Inserts a banner that the following section covers a certain Thunderbird version or later; // we actually prefer the new hN_tb_minversion templates now though. // // $0 - Thunderbird version var lang = env.locale; var articleUrl = "Thunderbird " + $0 + " for developers"; var IntroducedIn = "Introduced in Thunderbird " + $0; switch(lang) { case 'de': articleUrl = "Thunderbird " + $0 + " für Entwickler"; IntroducedIn = "Eingeführt in Thunderbird " + $0; break; } var fullURL = web.spacesToUnderscores("/" + lang + '/docs/' + articleUrl); var str = ""; if (wiki.pageExists(fullURL)) { str = "" + IntroducedIn + ""; } else { str = IntroducedIn; } %>

<%-str%>

Revision Source

<%
// Inserts a banner that the following section covers a certain Thunderbird version or later;
// we actually prefer the new hN_tb_minversion templates now though.
//
//  $0 - Thunderbird version

var lang = env.locale;

var articleUrl = "Thunderbird " + $0 + " for developers";
var IntroducedIn = "Introduced in Thunderbird " + $0;

switch(lang) {
  case 'de':
    articleUrl = "Thunderbird " + $0 + " für Entwickler";
    IntroducedIn = "Eingeführt in Thunderbird " + $0;
    break;
}

var fullURL = web.spacesToUnderscores("/" + lang + '/docs/' + articleUrl);
var str = "";

if (wiki.pageExists(fullURL)) {
    str = "<a href='" + fullURL + "'>" + IntroducedIn + "</a>";
} else {
    str = IntroducedIn;
}
%>
<div class="standardNote">
  <p style="margin: 4px 0px;">
   <%-str%>
  </p>
</div>
Revert to this revision