Bug 40933

Some more escape()'s replaced by encodeURI()'s (были кракозябры при заведении бага из test run'а)


git-svn-id: svn://svn.office.custis.ru/3rdparty/bugzilla.org/trunk@220 6955db30-a419-402b-8a0d-67ecbb4d7f56
custis
vfilippov 2009-08-04 17:37:52 +00:00
parent 354c2b366a
commit dbfafd96ec
3 changed files with 8 additions and 8 deletions

View File

@ -516,7 +516,7 @@ TUI_hide_default('expert_fields');
<br>
<p style="text-align: left" id="showpreviewbtn"><a href="javascript:void showcommentpreview()">Preview</a></p>
<div id="wrapcommentpreview" style="display: none">
<iframe id="commentpreview" style="height: auto; border-width: 0; width: 100%">
<iframe name="commentpreview" id="commentpreview" style="height: auto; border-width: 0; width: 100%">
</iframe>
<script>
/*<!--*/
@ -527,7 +527,7 @@ TUI_hide_default('expert_fields');
function showcommentpreview() {
document.getElementById('wrapcommentpreview').style.width=(document.Create.comment.offsetWidth-10)+'px';
document.getElementById('wrapcommentpreview').style.display='table-cell';
document.getElementById('commentpreview').src='page.cgi?id=previewcomment.html&comment='+escape(document.Create.comment.value);
window.frames['commentpreview'].location.replace('page.cgi?id=previewcomment.html&comment='+encodeURI(document.Create.comment.value));
document.getElementById('showpreviewbtn').style.display='none';
}
//-->

View File

@ -1516,7 +1516,7 @@ CaseBugsGrid = function(id){
store.on('load',function(){
var url = 'enter_bug.cgi?';
for (var i=0; i<store.fields.keys.length; i++){
url = url + store.fields.keys[i] + '=' + escape(store.getAt(0).get(store.fields.keys[i])) + '&';
url = url + store.fields.keys[i] + '=' + encodeURI(store.getAt(0).get(store.fields.keys[i])) + '&';
}
url = url + 'caserun_id=' + caserun_id;
window.open(url);

View File

@ -1601,15 +1601,15 @@ searchToJson = function(url){
var pair = pairs[i].split('=');
if (params[pair[0]]){
if (typeof params[pair[0]] == 'object'){
params[pair[0]].push(unescape(pair[1]));
params[pair[0]].push(decodeURI(pair[1]));
}
else{
params[pair[0]] = new Array(params[pair[0]]);
params[pair[0]].push(unescape(pair[1]));
params[pair[0]].push(decodeURI(pair[1]));
}
}
else{
params[pair[0]] = unescape(pair[1]);
params[pair[0]] = decodeURI(pair[1]);
}
}
@ -1624,11 +1624,11 @@ jsonToSearch = function(params, searchStr, drops){
}
if (typeof params[key] == 'object'){
for(i=0; i<params[key].length; i++){
searchStr = searchStr + key + '=' + escape(params[key][i]) + '&';
searchStr = searchStr + key + '=' + encodeURI(params[key][i]) + '&';
}
}
else{
searchStr = searchStr + key + '=' + escape(params[key]) + '&';
searchStr = searchStr + key + '=' + encodeURI(params[key]) + '&';
}
}
if (searchStr.lastIndexOf('&') == searchStr.length - 1){