Ravens PHP Scripts: Forums
 

 

View next topic
View previous topic
Post new topic   Reply to topic    Ravens PHP Scripts And Web Hosting Forum Index -> Blocks
Author Message
craeyon
Hangin' Around



Joined: Jun 04, 2006
Posts: 40

PostPosted: Sat Jul 08, 2006 2:14 pm Reply with quote

Hey, i have been trying to create a Adsense block and so far no luck. I have no idea but is my script even correct ? (ignore the scipt i no its script. If i put the script tag in there one more time ill get perma blocked from this site)

Code:


<?php
if (eregi("block-Adsense.php",$PHP_SELF)) {
  Header("Location: ../index.php");
  die();
}
?>
<scipt language="text/javascript">
<!--
google_ad_client = "***woot woot***";
google_ad_width = "728";
google_ad_height = "90";
google_ad_format = "728x90_as";
google_ad_type = "text_image";
google_ad_channel ="***woot woot***";
google_color_border = "F4F6FB";
google_color_bg = "F4F6FB";
google_color_link = "0000FF";
google_color_text = "000000";
google_color_url = "008000";
// -->
</scipt>
<?php
$content .= "<scipt type=\"text/javascript\" src=\"http://pagead2.googlesyndication.com/pagead/show_ads.js\">";
$content .= "</scipt>";
?>
 
View user's profile Send private message
kguske
Site Admin



Joined: Jun 04, 2004
Posts: 6433

PostPosted: Sat Jul 08, 2006 3:01 pm Reply with quote

In a block, you can't output HTML (e.g. the first scrip t) directly. It must be added to the $content variable.

_________________
I search, therefore I exist...
nukeSEO - nukeFEED - nukePIE - nukeSPAM - nukeWYSIWYG
 
View user's profile Send private message
craeyon







PostPosted: Sat Jul 08, 2006 3:04 pm Reply with quote

Code:


<?php
if (eregi("block-Adsense.php",$PHP_SELF)) {
  Header("Location: ../index.php");
  die();
}

$content .= "<scri pt language=\"text/javascript\"><!--
google_ad_client = \"pub-4844596130995747\";
google_ad_width = \"728\";
google_ad_height = \"90\";
google_ad_format = \"728x90_as\";
google_ad_type = \"text_image\";
google_ad_channel =\"3980767519\";
google_color_border = \"F4F6FB\";
google_color_bg = \"F4F6FB\";
google_color_link = \"0000FF\";
google_color_text = \"000000\";
google_color_url = \"008000\";
// -->
</scr ipt>";
$content .= "<scr ipt type=\"text/javascript\" src=\"http://pagead2.googlesyndication.com/pagead/show_ads.js\">";
$content .= "</scr ipt>";
?>


is that it? that cant be it.. that doesn't look right. Confused
 
Guardian2003
Site Admin



Joined: Aug 28, 2003
Posts: 6799
Location: Ha Noi, Viet Nam

PostPosted: Sat Jul 08, 2006 3:18 pm Reply with quote

Code:


<?php
if (eregi("block-AdSense.php",$PHP_SELF)) {
  Header("Location: index.php");
  die();
}
?>
<script language="JavaSc ript">
<!--
google_ad_client = 'your client-number';
google_ad_width = 468;
google_ad_height = 60;
google_ad_format = '468X60_as';
google_color_border = "E5E5E5";
google_color_bg = "E5E5E5";
google_color_link = "336699";
google_color_url = "000000";
google_color_text = "000000";
// -->
</sc ript>
<?php
$content .= "<center><sc ript language=\"JavaSc ript\"
src=\"http://pagead2.googlesyndication.com/pagead/show_ads.js\">";
$content .= "</sc ript></center>";
?>
 
View user's profile Send private message Send e-mail
craeyon







PostPosted: Sat Jul 08, 2006 3:34 pm Reply with quote

THANK ye Very Happy
 
Display posts from previous:       
Post new topic   Reply to topic    Ravens PHP Scripts And Web Hosting Forum Index -> Blocks

View next topic
View previous topic
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum


Powered by phpBB © 2001-2007 phpBB Group
All times are GMT - 6 Hours
 
Forums ©