sharepoint 中banner 图片的放大

<script language=JavaScript" type="text/javascript">

                   function PopBanner(){

                            var obj=document.getElementById("ctl00_onetidHeadbnnr0");

                            var erc=obj.src.substring(obj.src.lastIndexOf('/')+1,obj.src.lastIndexOf('.'));

                            if(erc=='newBanner'){

                             if(obj.height>100 && obj.width>100){

                                      var title=document.getElementById("ctl00_PlaceHolderSiteName_onetidProjectPropertyTitle");

                                      var sreach=document.getElementById("WebPartWPQ1");

                                  sreach.style.visibility='hidden';

                                      title.style.visibility='hidden';

                                      var td=title.parentNode.parentNode;

                                      var tr=td.parentNode;

                                      tr.deleteCell(1);

                                      tr.deleteCell(1);

                                      obj.height='112';

                                      obj.width='1400';

                             }

                            }

                   }

         </script>

posted @ 2009-12-08 18:19  StarWang  阅读(217)  评论(0编辑  收藏  举报