Template:interface

  • Revision slug: Template:interface
  • Revision title: Template:interface
  • Revision id: 236415
  • Created:
  • Creator: trevorh
  • Is current revision? No
  • Comment

Revision Content

<% var lang = env.locale; var str = "/docs/XPCOM_Interface_Reference/"; switch(lang) { case 'de': str = "/docs/XPCOM_Interface_Referenz/"; break; } /* check $0 exists */ if(wiki.pageExists(lang + str + $0)) { %><%- web.link(wiki.uri(lang + str + $0), $0) %><% } else if(wiki.pageExists(lang + '/' + $0)) { %><%- web.link(wiki.uri(lang + '/' + $0), $0) %><% } else { var targeturi = "/docs/new?slug=" + lang + str + $0 + "&title=" + $0; %><%=$0%><% } %>

Revision Source

<%
var lang = env.locale;

var str = "/docs/XPCOM_Interface_Reference/";

switch(lang) {
  case 'de':
    str = "/docs/XPCOM_Interface_Referenz/";
    break;
}

/* check $0 exists */
if(wiki.pageExists(lang + str + $0)) {
  %><code><%- web.link(wiki.uri(lang + str + $0), $0) %></code><%
} else if(wiki.pageExists(lang + '/' + $0)) {
  %><code><%- web.link(wiki.uri(lang + '/' + $0), $0) %></code><%
} else {
  var targeturi = "/docs/new?slug=" + lang + str + $0 + "&title=" + $0;
  %><code><a rel="internal" href="<%=targeturi%>" class="new"><%=$0%></a></code><%
}
%>
Revert to this revision