Archive Pages Design$type=blogging$count=7

Pop Up Flottant pour blog


Pop Up Flottant pour blog
Ajouter un pop flottant sur votre blog, cela est une bonne façon d'annoncer un produit d'affiliation, gagner plus d'adeptes sur les réseaux sociaux ou de capturer des emails oferencendo un ebook gratuit.

Voir un exemple POPUP BLOGGER 
[lock]
Ajouter le code avant  </head>

<style>
#topbar{
position:absolute;
border: 2px solid green;
padding: 5px 0px 0px 0px;
margin: 100px 0px 0px 200px;
background-color: #ffffff;
font-size:12px;
width: 300px;
visibility: hidden;
z-index: 300;}
</style>


Ajouter après </head>


<!-- Java PopUp -->
&lt;script type=&quot;text/javascript&quot;&gt;
var persistclose=1
var startX = 20
var startY = 5
var verticalpos=&quot;fromtop&quot;
function iecompattest(){
return (document.compatMode &amp;&amp; document.compatMode!=&quot;BackCompat&quot;)? document.documentElement : document.body
}
function get_cookie(Name) {
var search = Name + &quot;=&quot;
var returnvalue = &quot;&quot;;
if (document.cookie.length &gt; 0) {
offset = document.cookie.indexOf(search)
if (offset != -1) {
offset += search.length
end = document.cookie.indexOf(&quot;;&quot;, offset);
if (end == -1) end = document.cookie.length;
returnvalue=unescape(document.cookie.substring(offset, end))
}
}
return returnvalue;
}
function closebar(){
if (persistclose)
document.cookie=&quot;remainclosed=1&quot;
document.getElementById(&quot;topbar&quot;).style.visibility=&quot;hidden&quot;
}
function staticbar(){
barheight=document.getElementById(&quot;topbar&quot;).offsetHeight
var ns = (navigator.appName.indexOf(&quot;Netscape&quot;) != -1) || window.opera;
var d = document;
function ml(id){
var el=d.getElementById(id);
if (!persistclose || persistclose &amp;&amp; get_cookie(&quot;remainclosed&quot;)==&quot;&quot;)
el.style.visibility=&quot;visible&quot;
if(d.layers)el.style=el;
el.sP=function(x,y){this.style.left=x+&quot;px&quot;;this.style.top=y+&quot;px&quot;;};
el.x = startX;
if (verticalpos==&quot;fromtop&quot;)
el.y = startY;
else{
el.y = ns ? pageYOffset + innerHeight : iecompattest().scrollTop + iecompattest().clientHeight;
el.y -= startY;
}
return el;
}
window.stayTopLeft=function(){
if (verticalpos==&quot;fromtop&quot;){
var pY = ns ? pageYOffset : iecompattest().scrollTop;
ftlObj.y += (pY + startY - ftlObj.y)/8;
}
else{
var pY = ns ? pageYOffset + innerHeight - barheight: iecompattest().scrollTop + iecompattest().clientHeight - barheight;
ftlObj.y += (pY - startY - ftlObj.y)/8;
}
ftlObj.sP(ftlObj.x, ftlObj.y);
setTimeout(&quot;stayTopLeft()&quot;, 10);
}
ftlObj = ml(&quot;topbar&quot;);
stayTopLeft();
}
if (window.addEventListener)
window.addEventListener(&quot;load&quot;, staticbar, false)
else if (window.attachEvent)
window.attachEvent(&quot;onload&quot;, staticbar)
else if (document.getElementById)
window.onload=staticbar
&lt;/script&gt;
<!-- Java PopUp -->


Ajouter après  <body>

<!-- commefaire -->
<div id='topbar'>
  <p align='right'><a href='http://commefaire.blogspot.fr' onClick='closebar(); return false'>[X]</a></p>
<img border='0' height='250' src='https://4.bp.blogspot.com/-KnBcVs2Ayzs/WKLmCEIB84I/AAAAAAAAAKk/niT0lk8u_dQWLiWibomZd1CJcxAvWILagCLcB/s320/How%2Bto%2Bmake%2Bmoney%2Bblogging.png' width='300'/>
</div>
<!-- commefaire -->

[/lock]
Maintenant, faites les changements nécessaires dans le pop up, changer ce qui est en rouge, mettre le lien de votre image.

Pop Up Flottant pour blog Pop Up Flottant pour blog Reviewed by Unknown on 14:29 Rating: 5

Aucun commentaire:

Fourni par Blogger.