if(top==self)document.location='index.asp'如果本页面不是包含在帧(frame)里,就把页面跳转到'index.asp'
你可以在main.asp编程得到你现在浏览器的地址,然后判断是否跳转到index.asp