diff --git a/source/web/scripts/office/my_tasks.js b/source/web/scripts/office/my_tasks.js index d63d896d86..623a27dffd 100644 --- a/source/web/scripts/office/my_tasks.js +++ b/source/web/scripts/office/my_tasks.js @@ -169,7 +169,8 @@ var OfficeMyTasks = if (successMessage != "") { var json = "{\"statusString\":\"" + successMessage + "\",\"statusCode\":true}"; - href += "&st=" + encodeURI(json); + href += (href.indexOf("?") == -1) ? "?" : "&"; + href += "st=" + encodeURI(json); } window.location.href = href; }, @@ -216,7 +217,8 @@ var OfficeMyTasks = // Optionally add a status string if (textResponse != "") { - href += "&st=" + encodeURI(textResponse); + href += (href.indexOf("?") == -1) ? "?" : "&"; + href += "st=" + encodeURI(textResponse); } window.location.href = href; } diff --git a/source/web/scripts/office/navigation.js b/source/web/scripts/office/navigation.js index 6b6b655757..c436725bda 100644 --- a/source/web/scripts/office/navigation.js +++ b/source/web/scripts/office/navigation.js @@ -183,7 +183,8 @@ var OfficeNavigation = // Optionally add a status string if (textResponse != "") { - href += "&st=" + encodeURI(textResponse); + href += (href.indexOf("?") == -1) ? "?" : "&"; + href += "st=" + encodeURI(textResponse); } window.location.href = href; } diff --git a/source/web/scripts/office/office_addin.js b/source/web/scripts/office/office_addin.js index ad43994ebc..9cf067b920 100644 --- a/source/web/scripts/office/office_addin.js +++ b/source/web/scripts/office/office_addin.js @@ -112,7 +112,8 @@ var OfficeAddin = // Optionally add a status string if (textResponse != "") { - href += "&st=" + encodeURI(textResponse); + href += (href.indexOf("?") == -1) ? "?" : "&"; + href += "st=" + encodeURI(textResponse); } window.location.href = href; }