前端js代码
function searchAll(){
var contentStr = $('#contentStr_id').val(); contentStr =encodeURI(contentStr); alert(contentStr); $('#tt').datagrid('options').url='propose!page.action?test=' + contentStr; $('#tt').datagrid('reload'); }
后台java代码Action层代码
String name = "";
try { name = java.net.URLDecoder.decode(request.getParameter("test"),"utf-8"); } catch (UnsupportedEncodingException e2) { e2.printStackTrace(); }