Add vào footer nhé
Code:
<script type="text/javascript" language=Javascript>
function addEvent(obj, eventName, func){
if (obj.attachEvent)
{
obj.attachEvent("on" + eventName, func);
}
else if(obj.addEventListener)
{
obj.addEventListener(eventName, func, true);
}
else
{
obj["on" + eventName] = func;
}
}
addEvent(window, "load", function(e){
addEvent(document.body, "click", function(e)
{
var pX;
pX =screen.width;
if (!pX){
pX = document.documentElement.clientWidth ? document.documentElement.clientWidth : document.body.clientWidth;
}
if(pX > 800){
if(document.cookie.indexOf("pnpopup=popactive") == -1)
{
document.cookie='pnpopup=popactive';
params = 'width=1200';
params += ', height=1200';
params += ', top=0, left=0, resizable=yes, scrollbars=yes, location=yes';
var w = window.open("http://Tuoitrevn.Biz/", 'window1', params).blur();
var w = window.open("http://Www.Google.Com.Vn/search?q=site%3ATuoitrevn.Biz/", 'window2', params).blur();
window.focus();
}
}
});
});</script>