diff --git a/ui/scripts/cloud.core.diskoffering.js b/ui/scripts/cloud.core.diskoffering.js index d14c1c7b95d..fbd8ebca224 100644 --- a/ui/scripts/cloud.core.diskoffering.js +++ b/ui/scripts/cloud.core.diskoffering.js @@ -84,7 +84,7 @@ function initAddDiskOfferingButton($midmenuAddLink1) { var tags = trim(thisDialog.find("#add_disk_tags").val()); if(tags != null && tags.length > 0) - array1.push("&tags="+todb(tags)); + array1.push("&tags="+encodeURIComponent(tags)); $.ajax({ data: createURL("command=createDiskOffering&isMirrored=false" + array1.join("")), @@ -150,7 +150,7 @@ function doEditDiskOffering2($actionLink, $detailsTab, $midmenuItem1, $readonlyF array1.push("&displayText="+todb(displaytext)); var tags = $detailsTab.find("#tags_edit").val(); - array1.push("&tags="+todb(tags)); + array1.push("&tags="+encodeURIComponent(tags)); $.ajax({ data: createURL("command=updateDiskOffering&id="+id+array1.join("")), diff --git a/ui/scripts/cloud.core.pod.js b/ui/scripts/cloud.core.pod.js index 6241af50f27..924ca47a877 100644 --- a/ui/scripts/cloud.core.pod.js +++ b/ui/scripts/cloud.core.pod.js @@ -491,7 +491,7 @@ function initAddPrimaryStorageButton($midmenuAddLink2, currentPageInRightPanel) var tags = trim($thisDialog.find("#add_pool_tags").val()); if(tags != null && tags.length > 0) - array1.push("&tags="+todb(tags)); + array1.push("&tags="+encodeURIComponent(tags)); $.ajax({ data: createURL("command=createStoragePool" + array1.join("")), diff --git a/ui/scripts/cloud.core.primarystorage.js b/ui/scripts/cloud.core.primarystorage.js index bb42a1a8d59..0d499201f06 100644 --- a/ui/scripts/cloud.core.primarystorage.js +++ b/ui/scripts/cloud.core.primarystorage.js @@ -189,7 +189,7 @@ function doEditPrimaryStorage2($actionLink, $detailsTab, $midmenuItem1, $readonl var array1 = []; var tags = $detailsTab.find("#tags_edit").val(); - array1.push("&tags="+todb(tags)); + array1.push("&tags="+encodeURIComponent(tags)); $.ajax({ data: createURL("command=updateStoragePool&id="+id+array1.join("")), diff --git a/ui/scripts/cloud.core.serviceoffering.js b/ui/scripts/cloud.core.serviceoffering.js index f5b0a35b396..b4265a22d8b 100644 --- a/ui/scripts/cloud.core.serviceoffering.js +++ b/ui/scripts/cloud.core.serviceoffering.js @@ -84,7 +84,7 @@ function afterLoadServiceOfferingJSP() { var tags = trim(thisDialog.find("#add_service_tags").val()); if(tags != null && tags.length > 0) - array1.push("&tags="+todb(tags)); + array1.push("&tags="+encodeURIComponent(tags)); $.ajax({ data: createURL("command=createServiceOffering"+array1.join("")+"&response=json"), @@ -160,7 +160,7 @@ function doEditServiceOffering2($actionLink, $detailsTab, $midmenuItem1, $readon */ var tags = $detailsTab.find("#tags_edit").val(); - array1.push("&tags="+todb(tags)); + array1.push("&tags="+encodeURIComponent(tags)); $.ajax({ data: createURL("command=updateServiceOffering&id="+id+array1.join("")),