在JQUERY中要动态执行从服务器端返回的HTML片断,可用JQUERY中的globalEval方法。 举例如下: var scriptCode='alert("hello")';$.globalEval(scriptCode);