diff --git a/eng/docs/api/assets/header.html b/eng/docs/api/assets/header.html
index cab0c7725..510f916e3 100644
--- a/eng/docs/api/assets/header.html
+++ b/eng/docs/api/assets/header.html
@@ -34,10 +34,8 @@ function currentVersion() {
}
function currentPackage() {
- // C docs are generated as a monolith, the correct path is:
- // https://azuresdkdocs.blob.core.windows.net/$web/c/docs/{version}/index.html
- // This sets the "docs" piece of the URL path
- return "docs";
+ // Filled in by Doxygen template
+ return "$projectname";
}
function httpGetAsync(targetUrl, callback) {
@@ -74,16 +72,12 @@ function populateOptions(optionSelector, otherSelectors) {
httpGetAsync(versionRequestUrl, function(responseText) {
if (responseText) {
let options = responseText.match(/[^\r\n]+/g);
-
populateVersionDropDown(optionSelector, options);
showSelectors(otherSelectors);
$(optionSelector).change(function() {
targetVersion = $(this).val();
-
- url = WINDOW_CONTENTS.slice();
- url[6] = targetVersion;
- window.location.href = url.join("/");
+ window.location.href = getPackageUrl(SELECTED_LANGUAGE, currentPackage(), targetVersion);
});
}
});