homepage Welcome to WebmasterWorld Guest from 54.204.215.209
register, free tools, login, search, subscribe, help, library, announcements, recent posts, open posts,
Subscribe to WebmasterWorld

Home / Forums Index / Google / Google AdSense
Forum Library, Charter, Moderators: incrediBILL & jatar k & martinibuster

Google AdSense Forum

    
How to insert Ads script into html without paste directly
Naty




msg:1340028
 10:05 am on Aug 7, 2005 (gmt 0)

How to insert Ads script into html without paste directly
Before,I have PHP page and I can use PHP include for Ads
Now,my page is html and I need to insert Ads like PHP include statement.Because,when I need to change Ads format I can change at one file.

Is this possible?
How can I do?

 

maccas




msg:1340029
 10:17 am on Aug 7, 2005 (gmt 0)

Use SSI, <!--#include virtual="/adsense.txt" -->
and put

AddType text/x-server-parsed-html .html
AddType text/x-server-parsed-html .htm

into your .htaccess file to treat html,htm files as shtml (if your can't already include files in html)

Bddmed




msg:1340030
 10:21 am on Aug 7, 2005 (gmt 0)

Hallo Naty,

When your provider supports it you can use SSI (server side includes).

I'm using this line of code:
<!--#include virtual="/AdSenseCodeHere.shtml" -->

It's possible that you need to rename your html pages to .shtml or whatever (depending on ISP).

jetteroheller




msg:1340031
 10:46 am on Aug 7, 2005 (gmt 0)

I just implemented it to insert it by SSI

<!--#include virtual="/cgi-bin/ssi.pl?from=google-g&insert=300x250&arb=book-theme" -->

from=google-g

load the text file google-g.txt
where all used ad fromats are stored
(g stands for German, on an english page would be google-e)

insert=300x250
Take the code for the 300x250 from google-g.txt

arb=book-theme

Amazon recommended book
I use Amazon as an PSA replacement
This is the parameter for the Amazon recommended book search

Naty




msg:1340032
 10:57 am on Aug 7, 2005 (gmt 0)

That 's great for me.
I never know about this technic.

While(1)
{
Thanks for all reply;
}

Any comment welcome

NT

Naty




msg:1340033
 11:29 am on Aug 7, 2005 (gmt 0)

Hi again

I can't test it on my PC(Appserv on WinXP)
But on real server it OK.

Because, I can't create file .httaccess on WinXP

How can I do?
Please.

Bddmed




msg:1340034
 12:02 pm on Aug 7, 2005 (gmt 0)

Hello Naty,

Since this is the adsense forum I would suggest you take this question to the Apache forum. Since Apache is part of the Appserve package.

The guys (and girls) over there should be able to get things running locally.

Global Options:
 top home search open messages active posts  
 

Home / Forums Index / Google / Google AdSense
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About
© Webmaster World 1996-2014 all rights reserved