Results 1 to 4 of 4
  1. #1

    Adding banners to all pages

    Hello,

    The subject doesn't really explain what I have in mind, but please continue reading

    I am thinking of offering free web hosting to some clients as part of a sponsorship. I will ask for an ad banner placed to the top of the pages.

    How can I do this automatically like geocities or other service providers do? Would a script be enough, if yes, how can I find it?

    Regards
    About-Webhosting
    Everything you need to know about web hosting business..
    Realible and low-cost web hosting..
    30 Day Money Back Guarantee & Paypal Accepted

  2. #2
    I think you would add a handler to the webserver you are using...
    What is your webserver?
    WatermarkIt: Take ownership of your images
    Salo Storm Software

  3. #3
    I am planning to use the reseller account I bought from resellerzoom, that's why I am not able to install anything to the server.
    About-Webhosting
    Everything you need to know about web hosting business..
    Realible and low-cost web hosting..
    30 Day Money Back Guarantee & Paypal Accepted

  4. #4
    Join Date
    Nov 2004
    Location
    UK
    Posts
    774
    I would HIGHLY recommend that you get a VPS/Ded for this task, and install Apache and mod_layout.

    However, that said you can include ads using the following solution, although this may use quite a lot of resources, and is quite a complex method:

    Use mod_rewrite rules (in a .htaccess file - obviously needs to be protected from user manipulation) to redirect ALL hits to files to a PHP script, and send the REQUEST_FILENAME variable to the PHP script using the GET method.

    PHP script then parses incoming variable and looks at extension (then decides whether or not to include advert.html) - e.g. files with extension .html/.htm/.txt will automatically have advert.html included, files .gif/.jpg/.swf will NOT have advert.html included.

    PHP script can now include original file.

    Result is that HTML files will have an advert stuck on, and then are sent to the browser, while other files such as images will not have the advert file included.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •