← Desenvolvimento

Alternar publicidade!

Lida 2688 vezes

Offline

fantas 
Membro
Mensagens 303 Gostos 1
Feedback +1

Troféus totais: 25
Trófeus: (Ver todos)
Level 5 Tenth year Anniversary Nineth year Anniversary Eighth year Anniversary Super Combination Combination Topic Starter Poll Voter Level 4 Level 3

Boas pessoal, uso Google adsense mas gostaria que de vez em quando aparece-se um banner que eu quize-se no local onde aparece o Adsense será que tal  é possível ?  :-k
Offline

betanalista 
Membro
Mensagens 2564 Gostos 0
Feedback +18

Troféus totais: 26
Trófeus: (Ver todos)
Super Combination Combination Topic Starter 10 Poll Votes Poll Voter Level 5 Level 4 Level 3 Level 2 Level 1

Offline

fantas 
Membro
Mensagens 303 Gostos 1
Feedback +1

Troféus totais: 25
Trófeus: (Ver todos)
Level 5 Tenth year Anniversary Nineth year Anniversary Eighth year Anniversary Super Combination Combination Topic Starter Poll Voter Level 4 Level 3

funciona com imagens, mas não funciona com o formato dos anuncios do Google : S
Offline

betanalista 
Membro
Mensagens 2564 Gostos 0
Feedback +18

Troféus totais: 26
Trófeus: (Ver todos)
Super Combination Combination Topic Starter 10 Poll Votes Poll Voter Level 5 Level 4 Level 3 Level 2 Level 1

funciona com imagens, mas não funciona com o formato dos anuncios do Google : S

isso é só adaptar

1 - CASO
Código: [Seleccione]
<?
$imgamaleatoria=rand(1,5);
?>

Código: [Seleccione]
<?php include(TEMPLATEPATH./ficheiro<php? echo $imgamaleatoria ?>.php”);?>

em vez de imagens tens ficheiros php  :grin:

atenção não testei, teste e deixa o feedback

Offline

raugusto 
Elite
Mensagens 3145 Gostos 33
Feedback +13

Troféus totais: 31
Trófeus: (Ver todos)
Level 6 Super Combination Combination Topic Starter 10 Poll Votes Poll Voter Level 5 Level 4 Level 3 Level 2

usa o google dfp
Offline

flock 
Membro
Mensagens 508 Gostos 0
Feedback +7

Troféus totais: 22
Trófeus: (Ver todos)
Super Combination Combination Topic Starter Poll Voter Level 4 Level 3 Level 2 Level 1 500 Posts 100 Posts

Em wordpress tens o AdRotate no smf não conheço
Offline

ragnarock 
Membro
Mensagens 208 Gostos 1
Feedback +1

Troféus totais: 27
Trófeus: (Ver todos)
Tenth year Anniversary Nineth year Anniversary Super Combination Combination Topic Starter Poll Voter Level 5 Level 4 Level 3 Level 2

faz algo tipo isto:
Código: [Seleccione]
<?php
      $ad1 
'banner1';

      
$ad2 '<a href="http://rumblepack.com.pt/retrogaming/"><img src="http://retrograming.files.wordpress.com/2010/04/retrogaming.png" alt="Retrogaming" title="Retrogaming"></a>';

      
$ad3='<a href="http://anthony.com.pt/"><img src="http://www.jogosbaratos.net/publicidade/banner-468x60.gif" alt="Anthony Vendeirinho" title="Anthony Vendeirinho"></a>';

      
$ad4='<iframe allowtransparency="true" src="http://ads.betfair.com/ad.aspx?bid=4175&pid=63253" width="468" height="60" marginwidth="0" marginheight="0" hspace="0" vspace="0" frameborder="0" scrolling="no"></iframe>';

      
$num rand (1,4);
      
$ads = ${'ad'.$num};

      echo 
$ads;
    
?>

funciona também com o google que eu ja testei :D (esta solução é mais ou menos aquilo que o betanalista sugeriu)
Offline

fantas 
Membro
Mensagens 303 Gostos 1
Feedback +1

Troféus totais: 25
Trófeus: (Ver todos)
Level 5 Tenth year Anniversary Nineth year Anniversary Eighth year Anniversary Super Combination Combination Topic Starter Poll Voter Level 4 Level 3

faz algo tipo isto:
Código: [Seleccione]
<?php
      $ad1 
'banner1';

      
$ad2 '<a href="http://rumblepack.com.pt/retrogaming/"><img src="http://retrograming.files.wordpress.com/2010/04/retrogaming.png" alt="Retrogaming" title="Retrogaming"></a>';

      
$ad3='<a href="http://anthony.com.pt/"><img src="http://www.jogosbaratos.net/publicidade/banner-468x60.gif" alt="Anthony Vendeirinho" title="Anthony Vendeirinho"></a>';

      
$ad4='<iframe allowtransparency="true" src="http://ads.betfair.com/ad.aspx?bid=4175&pid=63253" width="468" height="60" marginwidth="0" marginheight="0" hspace="0" vspace="0" frameborder="0" scrolling="no"></iframe>';

      
$num rand (1,4);
      
$ads = ${'ad'.$num};

      echo 
$ads;
    
?>

funciona também com o google que eu ja testei :D (esta solução é mais ou menos aquilo que o betanalista sugeriu)

Funciona Obrigadinha ;)
Offline

kaydara 
Membro
Mensagens 616 Gostos 1
Feedback +1

Troféus totais: 21
Trófeus: (Ver todos)
Super Combination Combination Topic Starter Poll Voter Level 4 Level 3 Level 2 Level 1 500 Posts 100 Posts

podes tb usar a bd para controlar o número de vezes que pretendes mostrar cada um, usando a base de dados até os podes mostrar com ratios diferentes