Snitz Forums 2000
Snitz Forums 2000
Home | Profile | Register | Active Topics | Members | Search | FAQ
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 Snitz Forums 2000 MOD-Group
 MOD Add-On Forum (W/Code)
 Google adsense in topic.asp
 New Topic  Reply to Topic
 Printer Friendly
Next Page
Author Previous Topic Topic Next Topic
Page: of 3

dl4gbe
Starting Member

Thailand
36 Posts

Posted - 26 May 2006 :  07:58:38  Show Profile  Visit dl4gbe's Homepage  Reply with Quote
Hello.

Here an example to add adsense in topic.asp




Add the folllowing function to topic.asp
please do not forget to set your own ID in
google_ad_client



sub Adsense(strColorBG)

        Response.Write  "              <tr>" & vbNewLine & _
                        "                <td bgcolor=""" & CColor & """ valign=""top"" width=""" & strTopicWidthLeft & """>" & vbnewline 
        Response.Write  "                 <p><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """><b><span class=""spnMessageText"">Google Adsense</span></font>" & vbNewLine
		response.write	"                <p><font color=""" & strForumFontColor & """ face=""" & strDefaultFontFace & """ size=""" & strFooterFontSize & """><small>USA</small></font><br />" & vbNewLine & _                        
                        "                <font color=""" & strForumFontColor & """ face=""" & strDefaultFontFace & """ size=""" & strFooterFontSize & """><small>Mountain View</small></font></p></td>" & vbNewLine


        Response.Write  "                </td>" & vbnewline & _
                        "                <td bgcolor=""" & CColor & """ height=""100%"" width=""" & strTopicWidthRight & """"
                        if lcase(strTopicNoWrapRight) = "1" then Response.Write(" nowrap")
                        if (AdminAllowed = 1) and (maxpages > 1) then
                                Response.Write        (" colspan=""3"" ")
                        else
                                Response.Write        (" colspan=""2"" ")
                        end if
                        Response.Write        "valign=""top"">" & vbnewline
                        
        Response.Write  "                  <table width=""100%"" height=""100%"" border=""0"" cellspacing=""0"" cellpadding=""0"">" & vbNewLine & _
                        "                    <tr>" & vbNewLine & _
                        "                      <td valign=""top"">" & vbNewLine


strColor = strColorBG
 
if (left(strColor,1) = "#") then
	strColor = mid(strColor,2)
end if

%>

<script type="text/javascript"><!--
google_ad_client = "xxxxxxxxxxxxxx";
google_ad_width = 468;
google_ad_height = 60;
google_ad_format = "468x60_as";
google_ad_type = "text";
google_ad_channel ="";
google_color_border = "<%=strColor%>";
google_color_link = "0000FF";
google_color_bg = "<%=strColor%>";
google_color_text = "000000";
google_color_url = "008000";
//--></script>
<script type="text/javascript"
  src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script>

<%


        Response.Write  "                      </td>" & vbNewLine & _
                        "                    </tr>" & vbNewLine & _
						"                    <tr>" & vbNewLine & _
                        "                      <td valign=""bottom"" align=""right"" height=""20""><a href=""#top"">" & getCurrentIcon(strIconGoUp,strLangTopic00200,"align=""right""") & "</a></td>" & vbNewLine & _
                        "                    </tr>" & vbNewLine & _
                        "                  </table>" & vbNewLine & _
                        "                </td>" & vbNewLine & _
                        "              </tr>" & vbNewLine

end sub





at the beginning of the file declare one variable.


bolShowAdd = true



At the end of the big reply loop
bevor the next insert this.



if bolShowAdd = true then
    adsense(CColor)
    bolShowAdd = false
end if



Here is an example:

http://www.thai-wahn.com/topic.asp?TOPIC_ID=4755

Please note: colors only work with rgb values. In case you need a ColorName RGB converter I can post the code here.

Chris <

WWW.TIP-THAILAND.DE
The newspaper for the
German speaking Community in South East Asia (Offices in Phuket, Pattaya, Bangkok, Nong Khai, Vietiane)

Edited by - dl4gbe on 26 May 2006 08:15:20

Podge
Support Moderator

Ireland
3775 Posts

Posted - 26 May 2006 :  11:32:52  Show Profile  Send Podge an ICQ Message  Send Podge a Yahoo! Message  Reply with Quote
Very nice.

Do you have a separate channel set up for it? If so, how does it compare to adsense on the rest of the forum?<

Podge.

The Hunger Site - Click to donate free food | My Blog | Snitz 3.4.05 AutoInstall (Beta!)

My Mods: CAPTCHA Mod | GateKeeper Mod
Tutorial: Enable subscriptions on your board

Warning: The post above or below may contain nuts.
Go to Top of Page

Karel Bata
Junior Member

United Kingdom
122 Posts

Posted - 29 May 2006 :  11:45:46  Show Profile  Visit Karel Bata's Homepage  Reply with Quote

Are you deliberately out to annoy your users with this? It is very intrusive!

<
Go to Top of Page

AnonJr
Moderator

United States
5768 Posts

Posted - 29 May 2006 :  15:11:53  Show Profile  Visit AnonJr's Homepage  Reply with Quote
Personal feelings aside, its a good mod.

The ad issue is up to each webmaster to decide on his/her own. If user's are ok, then its no big deal. If they're not ok, they'll say so by either saying so or not returning. Either way, bandwidth costs money and I don't know enough to say how to best pay for it. <
Go to Top of Page

Karel Bata
Junior Member

United Kingdom
122 Posts

Posted - 30 May 2006 :  04:13:09  Show Profile  Visit Karel Bata's Homepage  Reply with Quote

There's a seperate thread debating this here.<
Go to Top of Page

CarKnee
Junior Member

USA
297 Posts

Posted - 02 June 2006 :  16:42:17  Show Profile  Visit CarKnee's Homepage  Reply with Quote
quote:
Originally posted by Podge

Very nice.

Do you have a separate channel set up for it? If so, how does it compare to adsense on the rest of the forum?



I have had an AdSense block running as the first reply in a thread for a while now (year or so). It is displayed ONLY to non registered members and "non-supporting" members.

That channel is the highest performing channel I have. It gets 2x the CTR of the 2nd highest performing AdSense block on the site. However, I have played with colors and images extensively to tweak it.

Going by that "Snitz Stats" thing I have in my signature... if you have a rank close to mine I would suggest implementing it and you may be pleasantly supprised.

I am not getting into a debate about ads being evil or not.<

Go to Top of Page

AnonJr
Moderator

United States
5768 Posts

Posted - 02 June 2006 :  17:00:40  Show Profile  Visit AnonJr's Homepage  Reply with Quote
First reply only? and only for non-registered members? And that gets you double your 2nd highest performing block?

Hmm. Though, all things are relative... $2 is double $1, but nothing to do back-flips about. Any more concrete numbers to help with the decision? (BTW, I'm not implying that those are your numbers, just that 'double' is a relative thing)<
Go to Top of Page

CarKnee
Junior Member

USA
297 Posts

Posted - 05 June 2006 :  10:09:14  Show Profile  Visit CarKnee's Homepage  Reply with Quote
quote:
Originally posted by AnonJr

First reply only? and only for non-registered members? And that gets you double your 2nd highest performing block?

Hmm. Though, all things are relative... $2 is double $1, but nothing to do back-flips about. Any more concrete numbers to help with the decision? (BTW, I'm not implying that those are your numbers, just that 'double' is a relative thing)



I only display the block in the thread to "non-supporting" members (this includes non-registered and non-logged in people). Members of a community web site have "ad blindness" and will most likely not click on any ads.

Furthermore, I tested placing the ad at random positions on the second and greater pages, but their performance was horrible so I removed them.

I didn't say income was doubled, I said Click Through Rate (CTR) was doubled. Income isn't directly proporional to CTR. Income would depend on the format/size of the AdSense block, the keywords you are targeting, etc...

For instance, if I have a thread that starts talking about taking a cruise vacation then I get an adsense block pushing a vacation. Those ads will get a different amount of $$ then a block in a thread about viagra.

-CarKnee<

Go to Top of Page

bpopark
Starting Member

8 Posts

Posted - 16 June 2006 :  21:28:25  Show Profile  Visit bpopark's Homepage  Reply with Quote
Hey my first MOD for the adsense

http://www.bpopark.com/forum/topic.asp?TOPIC_ID=21

thanks dl4gbe

Just that I had to figure out for long where I had to put these MOD
if you specify between what that wd be great for the beginners

till then take care

Pawan



<

www.bpopark.com/forum
Go to Top of Page

weeweeslap
Senior Member

USA
1077 Posts

Posted - 07 July 2006 :  04:48:03  Show Profile  Visit weeweeslap's Homepage  Send weeweeslap an AOL message  Send weeweeslap a Yahoo! Message  Reply with Quote
has anyone had problems with the laying out of this in IE? I am using ie7 beta 3 and I am having width issues in which is spreads the topic wide and in firefox it displays at it should within the borders of the layout of the site.
Well not on all topics, topics with more tha one page, example, topic with no additional pages it displays fine:
http://www.weeweeslap.com/forum/topic.asp?TOPIC_ID=12651
topics with more than one page it extends out:
http://www.weeweeslap.com/forum/topic.asp?TOPIC_ID=12631&whichpage=1

But in firefox both are seen as they should be seen so it can be an IE7 issue. My better question is, does anyone have a topic.asp file with this mod installed. I may have added code in the wrong place as adding the code at the end of the big reply loop added the code in a place where it was not expected so I added it elsewhere and it placed it where it should but the proble mentioned above. If anyone has mor einfo this I'd appreciate it. Thanks.<

coaster crazy
Go to Top of Page

jas168
Starting Member

New Zealand
2 Posts

Posted - 13 April 2007 :  14:50:56  Show Profile  Reply with Quote
hi can some one give some instrustion where to put the codes...
thank you advance<
Go to Top of Page

kolucoms6
Average Member

845 Posts

Posted - 24 May 2007 :  09:12:16  Show Profile  Reply with Quote

Where to insert

if bolShowAdd = true then
adsense(CColor)
bolShowAdd = false
end if

<
Go to Top of Page

kolucoms6
Average Member

845 Posts

Posted - 24 May 2007 :  09:15:05  Show Profile  Reply with Quote
And what is this for :

USA
Mountain View<
Go to Top of Page

MarkJH
Senior Member

United Kingdom
1722 Posts

Posted - 24 May 2007 :  12:21:44  Show Profile  Visit MarkJH's Homepage  Reply with Quote
It's Google HQ's Address.<

Bandlink.net - http://www.bandlink.net/
Bandlink Music Forums - http://www.bandlink.net/forum/
Go to Top of Page

kolucoms6
Average Member

845 Posts

Posted - 24 May 2007 :  12:47:22  Show Profile  Reply with Quote
Ok But Where to insert

if bolShowAdd = true then
adsense(CColor)
bolShowAdd = false
end if
<
Go to Top of Page

Podge
Support Moderator

Ireland
3775 Posts

Posted - 24 May 2007 :  14:12:58  Show Profile  Send Podge an ICQ Message  Send Podge a Yahoo! Message  Reply with Quote
Wherever you like within reason.

Do you want the Google Ads to show after the first topic in the thread (before the first reply) or some where else ?
Can you post a link to a text version of your topic.asp i.e. topic.txt<

Podge.

The Hunger Site - Click to donate free food | My Blog | Snitz 3.4.05 AutoInstall (Beta!)

My Mods: CAPTCHA Mod | GateKeeper Mod
Tutorial: Enable subscriptions on your board

Warning: The post above or below may contain nuts.
Go to Top of Page
Page: of 3 Previous Topic Topic Next Topic  
Next Page
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
Snitz Forums 2000 © 2000-2021 Snitz™ Communications Go To Top Of Page
This page was generated in 0.22 seconds. Powered By: Snitz Forums 2000 Version 3.4.07