c# 在UpdatePanel后台执行前台JS方法

 string msg = string.Format(@"
                document.getElementById('{0}').style.backgroundImage = 'url(images/huangdi.jpg)';
                document.getElementById('{1}').style.backgroundImage = 'url(images/niubei.jpg)';", pageName1, pageName2);
            ScriptManager.RegisterStartupScript(upName, upName.GetType(), Guid.NewGuid().ToString(), msg, true);
posted @ 2011-01-27 16:05  尹成亮  阅读(696)  评论(0编辑  收藏  举报