Forum Moderators: phranque

Message Too Old, No Replies

insert a code in all pages

some code on all pages on a site

         

Jaunty Edward

6:37 pm on Mar 25, 2007 (gmt 0)

10+ Year Member



hi,

I want to find if what I need to do can be done in apache or not.

I want a insert a perticular code on every page thats processed on a website.

I think this is possible surely, coz I have seen free hosting websites that insert a ad code on all the pages that are processed by the server software.

any clue how this can be done.

thanks
bye

jdMorgan

7:00 pm on Mar 25, 2007 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Those free Web servers use HTML frames or iFrames to "include" the hosted site's pages inside their own page. This ruins any chances for those site's pages to rank in search, and the same can be said for doing it to your own site's pages.

You can use PHP or SSI (Server-Side Includes) to include common elements on all of your pages, and since this is done by the server instead of the client, it won't hurt your search engine ranking unless you include too much common content. How much is too much? I don't know, but I'd stay well below 25%.

Jim