نقل قول نوشته اصلی توسط elipihost نمایش پست ها
کد HTML:
<script type="text/javascript">
function getCookie(c_name)
{
var i,x,y,ARRcookies=document.cookie.split(";");
for (i=0;i<ARRcookies.length;i++)
  {
  x=ARRcookies[i].substr(0,ARRcookies[i].indexOf("="));
  y=ARRcookies[i].substr(ARRcookies[i].indexOf("=")+1);
  x=x.replace(/^\s+|\s+$/g,"");
  if (x==c_name)
    {
    return unescape(y);
  }
  }
}

function setCookie(c_name,value)
{
var exdays= 1;
var exdate=new Date();
exdate.setHours(exdate.getHours() + exdays);
var c_value=escape(value) + ((exdays==null) ? "" : "; expires="+exdate.toUTCString());
document.cookie=c_name + "=" + c_value;
}

function checkCookie()
{
var username1=getCookie("tabligh1");
var username2=getCookie("tabligh2");
var usernam = "sendshod";
if(username1==null | username2==null){
window.open('#','_parent','toolbar=1,location=1,directories=1,status=1,menubar=1?,scrollbars=1,resizable=1');
window.focus();
}
if(username1=="" | username1==null){
if(window.open('http://www.ghati.ir','_blank','toolbar=1,scrollbars=1,location=1,statusbar=1,menubar=1,resizable=1,?width=800,height=600,top=500,left=1000')){
window.focus();
setCookie("tabligh1",usernam);
}
}
if(username2=="" | username2==null){
if(window.open('http://forum.ghati.ir/','_blank','toolbar=1,scrollbars=1,location=1,statusbar=1,menubar=1,resizable=1,?width=800,height=600,top=500,left=1000')){
window.focus();
setCookie("tabligh2",usernam);
}
}
}
document.onclick = checkCookie;
if ((window.XMLHttpRequest == undefined) && (ActiveXObject != undefined)) window.onload = checkCookie;
درود .
دوستام من از این کد استفاده کردم ، اما مثل اینکه محدودیت زمانی داره ، یا شایدم برای یک آی پی ، بعد از اینکه صفحه پاپ آپ رو ببینه ، دیگه تا چند ساعت صفحه پاپ آپ برای اون آی پی باز نمیشه ، میخواستم بدونم چطوری میشه این محدودیت رو برداشت ، و با هر بار رفرش شدن سایت و کلیک کاربر ، صفحه پاپ آپ نمایش داده بشه ؟
ممنون میشم راهنمایی کنید .