Skip to content

Commit 01c8f4a

Browse files
author
MFC Action
committed
Docs @ c38609e
1 parent 3f118ea commit 01c8f4a

File tree

4 files changed

+40
-8
lines changed

4 files changed

+40
-8
lines changed

documentation/search/search.js

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -623,7 +623,11 @@ function createResults(resultsPath) {
623623
srLink.innerHTML = elem[1][0];
624624
srEntry.appendChild(srLink);
625625
if (elem[1].length==2) { // single result
626-
srLink.setAttribute('href',resultsPath+elem[1][1][0]);
626+
if (elem[1][1][0].startsWith('http://') || elem[1][1][0].startsWith('https://')) { // absolute path
627+
srLink.setAttribute('href',elem[1][1][0]);
628+
} else { // relative path
629+
srLink.setAttribute('href',resultsPath+elem[1][1][0]);
630+
}
627631
srLink.setAttribute('onclick','searchBox.CloseResultsWindow()');
628632
if (elem[1][1][1]) {
629633
srLink.setAttribute('target','_parent');
@@ -643,7 +647,11 @@ function createResults(resultsPath) {
643647
srChild.setAttribute('id','Item'+index+'_c'+c);
644648
setKeyActions(srChild,'return searchResults.NavChild(event,'+index+','+c+')');
645649
setClassAttr(srChild,'SRScope');
646-
srChild.setAttribute('href',resultsPath+elem[1][c+1][0]);
650+
if (elem[1][c+1][0].startsWith('http://') || elem[1][c+1][0].startsWith('https://')) { // absolute path
651+
srLink.setAttribute('href',elem[1][c+1][0]);
652+
} else { // relative path
653+
srLink.setAttribute('href',resultsPath+elem[1][c+1][0]);
654+
}
647655
srChild.setAttribute('onclick','searchBox.CloseResultsWindow()');
648656
if (elem[1][c+1][1]) {
649657
srChild.setAttribute('target','_parent');

post_process/search/search.js

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -623,7 +623,11 @@ function createResults(resultsPath) {
623623
srLink.innerHTML = elem[1][0];
624624
srEntry.appendChild(srLink);
625625
if (elem[1].length==2) { // single result
626-
srLink.setAttribute('href',resultsPath+elem[1][1][0]);
626+
if (elem[1][1][0].startsWith('http://') || elem[1][1][0].startsWith('https://')) { // absolute path
627+
srLink.setAttribute('href',elem[1][1][0]);
628+
} else { // relative path
629+
srLink.setAttribute('href',resultsPath+elem[1][1][0]);
630+
}
627631
srLink.setAttribute('onclick','searchBox.CloseResultsWindow()');
628632
if (elem[1][1][1]) {
629633
srLink.setAttribute('target','_parent');
@@ -643,7 +647,11 @@ function createResults(resultsPath) {
643647
srChild.setAttribute('id','Item'+index+'_c'+c);
644648
setKeyActions(srChild,'return searchResults.NavChild(event,'+index+','+c+')');
645649
setClassAttr(srChild,'SRScope');
646-
srChild.setAttribute('href',resultsPath+elem[1][c+1][0]);
650+
if (elem[1][c+1][0].startsWith('http://') || elem[1][c+1][0].startsWith('https://')) { // absolute path
651+
srLink.setAttribute('href',elem[1][c+1][0]);
652+
} else { // relative path
653+
srLink.setAttribute('href',resultsPath+elem[1][c+1][0]);
654+
}
647655
srChild.setAttribute('onclick','searchBox.CloseResultsWindow()');
648656
if (elem[1][c+1][1]) {
649657
srChild.setAttribute('target','_parent');

pre_process/search/search.js

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -623,7 +623,11 @@ function createResults(resultsPath) {
623623
srLink.innerHTML = elem[1][0];
624624
srEntry.appendChild(srLink);
625625
if (elem[1].length==2) { // single result
626-
srLink.setAttribute('href',resultsPath+elem[1][1][0]);
626+
if (elem[1][1][0].startsWith('http://') || elem[1][1][0].startsWith('https://')) { // absolute path
627+
srLink.setAttribute('href',elem[1][1][0]);
628+
} else { // relative path
629+
srLink.setAttribute('href',resultsPath+elem[1][1][0]);
630+
}
627631
srLink.setAttribute('onclick','searchBox.CloseResultsWindow()');
628632
if (elem[1][1][1]) {
629633
srLink.setAttribute('target','_parent');
@@ -643,7 +647,11 @@ function createResults(resultsPath) {
643647
srChild.setAttribute('id','Item'+index+'_c'+c);
644648
setKeyActions(srChild,'return searchResults.NavChild(event,'+index+','+c+')');
645649
setClassAttr(srChild,'SRScope');
646-
srChild.setAttribute('href',resultsPath+elem[1][c+1][0]);
650+
if (elem[1][c+1][0].startsWith('http://') || elem[1][c+1][0].startsWith('https://')) { // absolute path
651+
srLink.setAttribute('href',elem[1][c+1][0]);
652+
} else { // relative path
653+
srLink.setAttribute('href',resultsPath+elem[1][c+1][0]);
654+
}
647655
srChild.setAttribute('onclick','searchBox.CloseResultsWindow()');
648656
if (elem[1][c+1][1]) {
649657
srChild.setAttribute('target','_parent');

simulation/search/search.js

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -623,7 +623,11 @@ function createResults(resultsPath) {
623623
srLink.innerHTML = elem[1][0];
624624
srEntry.appendChild(srLink);
625625
if (elem[1].length==2) { // single result
626-
srLink.setAttribute('href',resultsPath+elem[1][1][0]);
626+
if (elem[1][1][0].startsWith('http://') || elem[1][1][0].startsWith('https://')) { // absolute path
627+
srLink.setAttribute('href',elem[1][1][0]);
628+
} else { // relative path
629+
srLink.setAttribute('href',resultsPath+elem[1][1][0]);
630+
}
627631
srLink.setAttribute('onclick','searchBox.CloseResultsWindow()');
628632
if (elem[1][1][1]) {
629633
srLink.setAttribute('target','_parent');
@@ -643,7 +647,11 @@ function createResults(resultsPath) {
643647
srChild.setAttribute('id','Item'+index+'_c'+c);
644648
setKeyActions(srChild,'return searchResults.NavChild(event,'+index+','+c+')');
645649
setClassAttr(srChild,'SRScope');
646-
srChild.setAttribute('href',resultsPath+elem[1][c+1][0]);
650+
if (elem[1][c+1][0].startsWith('http://') || elem[1][c+1][0].startsWith('https://')) { // absolute path
651+
srLink.setAttribute('href',elem[1][c+1][0]);
652+
} else { // relative path
653+
srLink.setAttribute('href',resultsPath+elem[1][c+1][0]);
654+
}
647655
srChild.setAttribute('onclick','searchBox.CloseResultsWindow()');
648656
if (elem[1][c+1][1]) {
649657
srChild.setAttribute('target','_parent');

0 commit comments

Comments
 (0)