Skip to content

Commit

Permalink
Merge pull request gdcc#32 from gdcc/25-ncml-drafts
Browse files Browse the repository at this point in the history
allow NcML preview to work with drafts gdcc#25
  • Loading branch information
qqmyers authored Jun 22, 2023
2 parents 91b2381 + cf94966 commit d8c1a35
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion previewers/betatest/js/ncml.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,12 @@ function translateBaseHtmlPage() {

function writeContent(fileUrl, file, title, authors) {
addStandardPreviewHeader(file, title, authors);
var ncmlUrl = queryParams.get("siteUrl") + "/api/access/datafile/" + queryParams.get("fileid") + "/auxiliary/NcML/0.1";
var apiTokenOptional = "";
var apiToken = queryParams.get("key");
if (apiToken != null) {
apiTokenOptional = "?key=" + apiToken;
}
var ncmlUrl = queryParams.get("siteUrl") + "/api/access/datafile/" + queryParams.get("fileid") + "/auxiliary/NcML/0.1" + apiTokenOptional;
// copied from text.js
var whiteList = {
a: ["title"],
Expand Down

0 comments on commit d8c1a35

Please sign in to comment.