¿Supiste lo que acaba de lanzar LagriHost? Sí, como lo estabas esperando, ahora vendemos Web Hosting y Dominios. Conoce más :)


Calificación:
  • 0 voto(s) - 0 Media
  • 1
  • 2
  • 3
  • 4
  • 5
TUTORIAL Aporte - Popunder Javascript para cualquier link de tu elección!
#1
0
Hola aquí les dejo este código de java para un popunder que los popblocker no pueden bloquear y les puede servir para muchos usos! lo baje de blapage, y me a servido de mucho... 
espero que sea de su agrado. [Imagen: encouragement.png]

Código:
principio
var stagedPopFrequency = "1 days";
var stagedCookieName = "__name";

if (!document.currentStage)
document.currentStage = 0;
document.currentStage++;

if (document.currentStage == 1) {
function stagedGetCookie(Name) {
var search = Name + "=";
var returnvalue = "";
if (document.cookie.length > 0) {
offset = document.cookie.indexOf(search);
if (offset != -1) { // if cookie exists
offset += search.length;
// set index of beginning of value
end = document.cookie.indexOf(";", offset);
// set index of end of cookie value
if (end == -1)
end = document.cookie.length;
returnvalue = unescape(document.cookie.substring(offset, end));
}
}
return returnvalue;
}

function stagedSetCookie(Name, Value, Expire) {
if (Expire != null) {
var expireDate = new Date();
expireDate.setDate(expireDate.getDate() + parseInt(Expire));
document.cookie = Name+"="+Value+";path=/;expires=" + expireDate.toGMTString();
} else {
document.cookie = Name+"="+Value+";path=/";
}
}

function stagedResetCookie(Name) {
var expireDate = new Date();
expireDate.setDate(expireDate.getDate() - 10);
document.cookie = Name+"=;path=/;expires=" + expireDate.toGMTString();
}

function stagedPopUnder() {
if (stagedGetCookie(stagedCookieName) == '') {
var thisStage = 1;
var stageFunc = eval('window.popUnderStage'+thisStage);
if (stageFunc != undefined) {
stageFunc();
stagedSetCookie(stagedCookieName, thisStage + 1, stagedPopFrequency);
}
} else {
var thisStage = parseInt(stagedGetCookie(stagedCookieName));
var stageFunc = eval('window.popUnderStage'+thisStage);
if (stageFunc != undefined) {
stageFunc();
stagedSetCookie(stagedCookieName, thisStage + 1, stagedPopFrequency);
}
}
}

function stagedAttachBody() {
if (document.body) {
if (document.all) {
document.body.attachEvent('onclick', stagedPopUnder);
} else {
document.body.addEventListener('click', stagedPopUnder, false);
}
} else {
setTimeout('stagedAttachBody()', 200);
}
} stagedAttachBody();
}

if( parseInt(navigator.appVersion) > 3 )
{
winWidth = screen.availWidth;
winHeight = screen.availHeight;
}
else
{
winWidth = "1024";
winHeight = "768";
}

var stagedTmpFunc = function() {
var pu = window.open("http://www.tupagina.com", "_blank", "width=" + winWidth + ",height=" + winHeight + ",scrollbars=1,resizable=1,menubar=1");
pu.blur();
window.focus();


}
eval('window.popUnderStage'+document.currentStage+ ' = stagedTmpFunc;');
stagedTmpFunc = null;
fin  


remplacen tupagina.com con la dirección que quieren abrir en el pop luego copien el código en una nota y luego salvar como popunder.js y subanlo a su directorio home... una vez hallan hecho esto ponen el siguiente código en su header

<script type="text/javascript" src="http://www.tupagina.com/popunder.js"></script>

que lo disfruten!
Si te Agrado o Sirvió El Tema Dame Reputación Lengua


#2
0
Muy bueno se agrace bro Guiño




Posibles temas similares…
Tema Autor Respuestas Vistas Último mensaje
  Tutorial Limpiar estilos no usados de tu CSS para liberar espacio Diringax 0 2,424 17-02-2017, 10:31 AM
Último mensaje: Diringax
  APORTE JAVA: Domine el lenguaje líder en aplicaciones cliente servidor - User Kevin Alfonso 1 2,970 04-08-2016, 10:59 PM
Último mensaje: asanbus
  Tutorial Versiones de Visual Basic ¿Qué es? ¿Es Visual Basic buen lenguaje para Programar? Kevin Alfonso 2 3,061 20-06-2016, 09:13 PM
Último mensaje: cybersdl
  Tutorial Cómo utilizar Javascript para reproducir un archivo Roberto 2 3,130 19-06-2016, 07:22 PM
Último mensaje: Nomak
  Tutorial Aporte: Detectar plugin instalado en el navegador web Kevin Alfonso 1 2,577 21-04-2016, 01:25 PM
Último mensaje: cybersdl



Usuarios navegando en este tema:
1 invitado(s)


Forum software by © MyBB Theme © Kevinex & iAndrew 2018