Closed Thread
Page 1 of 2 12 LastLast
Results 1 to 10 of 11

Thread: how to add ads to phpbb forum?

  1. #1
    avishai is offline x10Hosting Member avishai is an unknown quantity at this point
    Join Date
    Sep 2005
    Posts
    32

    how to add ads to phpbb forum?

    HI,

    I've searched through the support forum but I couldn't get an answer to my problem.
    I don't know how to add ads to my phpbb forum on my site. Does anyone know how to and more important where to add the ad code? I have an advanced plan. I can't find the header/footer files that I need to change. Any help will be appreciated.

    Thanks
    Avishai

  2. #2
    minievan Guest

    Re: how to add ads to phpbb forum?

    There is another thread with this problem. Please search before making new threads XD

  3. #3
    bigguy's Avatar
    bigguy is offline Retired bigguy is an unknown quantity at this point
    Join Date
    Mar 2005
    Location
    Canada
    Posts
    5,426

    Re: how to add ads to phpbb forum?

    Try putting the ad in the "overall_header.tpl" file, that usually works.
    P.C. Tweakr - For all your computer and internet support
    P.C. Tweakr - For all your SMF help and support

  4. #4
    motogawa's Avatar
    motogawa is offline x10 Sophmore motogawa is an unknown quantity at this point
    Join Date
    Oct 2005
    Location
    Indianapolis, IN
    Posts
    153

    Re: how to add ads to phpbb forum?

    Placing the code in overall_header.tpl doesnt really help at all to the most part.

    This is what you shoudl do

    1.) Navigate to $phpbb_root_path/includes
    2.) Located page_header.php
    3.) Open page_header.php
    4.) In page header located these lines below.

    PHP Code:
    header ('Expires: 0');
    header ('Pragma: no-cache');

    $template->pparse('overall_header'); 
    5.) If your hosting plan is corporate change it to this.

    PHP Code:
    header ('Expires: 0');
    header ('Pragma: no-cache');

    $template->pparse('overall_header');

    echo 
    "<script language='JavaScript' type='text/javascript' src='http://x10hosting.com/advert/adx.js'></script>\n";
    echo 
    "<script language='JavaScript' type='text/javascript'>\n";
    echo 
    "<!--\n";
    echo 
    "if (!document.phpAds_used) document.phpAds_used = ',';\n";
    echo 
    "phpAds_random = new String (Math.random());\n";
    echo 
    "phpAds_random = phpAds_random.substring(2,11);\n";
    echo 
    "document.write (\"<\" + \"script language='JavaScript' type='text/javascript' src='\");\n";
    echo 
    "document.write (\"http://x10hosting.com/advert/adjs.php?n=\" + phpAds_random);\n";
    echo 
    "document.write (\"&amp;what=zone:1&amp;target=_blank\");\n";
    echo 
    "document.write (\"&amp;exclude=\" + document.phpAds_used);\n";
    echo 
    "if (document.referrer)\n";
    echo 
    "document.write (\"&amp;referer=\" + escape(document.referrer));\n";
    echo 
    "document.write (\"'><\" + \"/script>\");\n";
    echo 
    "//-->\n";
    echo 
    "</script><noscript><a href='http://x10hosting.com/advert/adclick.php?n=a7fb3e9d' target='_blank'><img src='http://x10hosting.com/advert/adview.php?what=zone:1&amp;n=a7fb3e9d' border='0' alt=''></a></noscript>\n"
    6.) If your hosting plan is advanced change it to this.
    PHP Code:
    header ('Expires: 0');
    header ('Pragma: no-cache');

    $template->pparse('overall_header');

    echo 
    "<script language='JavaScript' type='text/javascript' src='http://x10hosting.com/advert/adx.js'></script>\n";
    echo 
    "<script language='JavaScript' type='text/javascript'>\n";
    echo 
    "<!--\n";
    echo 
    "if (!document.phpAds_used) document.phpAds_used = ',';\n";
    echo 
    "phpAds_random = new String (Math.random());\n";
    echo 
    "phpAds_random = phpAds_random.substring(2,11);\n";
    echo 
    "document.write (\"<\" + \"script language='JavaScript' type='text/javascript' src='\");\n";
    echo 
    "document.write (\"http://x10hosting.com/advert/adjs.php?n=\" + phpAds_random);\n";
    echo 
    "document.write (\"&amp;what=zone:3&amp;target=_blank\");\n";
    echo 
    "document.write (\"&amp;exclude=\" + document.phpAds_used);\n";
    echo 
    "if (document.referrer)\n";
    echo 
    "document.write (\"&amp;referer=\" + escape(document.referrer));\n";
    echo 
    "document.write (\"'><\" + \"/script>\");\n";
    echo 
    "//-->\n";
    echo 
    "</script><noscript><a href='http://x10hosting.com/advert/adclick.php?n=a915c788' target='_blank' class=forumlink><img src='http://x10hosting.com/advert/adview.php?what=zone:3&amp;n=a915c788' border='0' alt=''></a></noscript>\n";
    echo 
    "\n";
    echo 
    "\n"
    That should fix the problems in your phpbb ads.
    PHP, AJAX, SQL, Javascript Programmer!
    Need help ask me!

  5. #5
    gauravmm is offline x10Hosting Member gauravmm is an unknown quantity at this point
    Join Date
    Aug 2005
    Posts
    22

    Re: how to add ads to phpbb forum?

    i used a frame, but your way is better.
    Rav3n


  6. #6
    bigguy's Avatar
    bigguy is offline Retired bigguy is an unknown quantity at this point
    Join Date
    Mar 2005
    Location
    Canada
    Posts
    5,426

    Re: how to add ads to phpbb forum?

    I`m not trying to argue and you might be right, but why doesnt it help when it has always worked before fine ?? Just thought I would ask. Maybe you can enlighten me :-)

    Placing the code in overall_header.tpl doesnt really help at all to the most part.
    P.C. Tweakr - For all your computer and internet support
    P.C. Tweakr - For all your SMF help and support

  7. #7
    IamShipon1988's Avatar
    IamShipon1988 is offline x10 Lieutenant IamShipon1988 is an unknown quantity at this point
    Join Date
    Jul 2005
    Location
    Rochester, NY
    Posts
    470

    Re: how to add ads to phpbb forum?

    just ad the script above every item on overall_header.tpl on every template/skin you have


  8. #8
    bigguy's Avatar
    bigguy is offline Retired bigguy is an unknown quantity at this point
    Join Date
    Mar 2005
    Location
    Canada
    Posts
    5,426

    Re: how to add ads to phpbb forum?

    Like I said I wasnt trying to argue I just would like to know why putting it in the page_header.php is better thats all, no worries, I`m trying to find out for future reference. :coolugh:

    Quote Originally Posted by bigguy
    I`m not trying to argue and you might be right, but why doesnt it help when it has always worked before fine ?? Just thought I would ask. Maybe you can enlighten me :-)


    Placing the code in overall_header.tpl doesnt really help at all to the most part.
    P.C. Tweakr - For all your computer and internet support
    P.C. Tweakr - For all your SMF help and support

  9. #9
    admincafe's Avatar
    admincafe is offline x10Hosting Member admincafe is an unknown quantity at this point
    Join Date
    Sep 2005
    Posts
    60

    Re: how to add ads to phpbb forum?

    to place the ad in the overal_header.tlp just ad an extra <td><tr> the ad code</td></tr> than the ad should show up

    The admincafe The Only place Where Admins Can come Together!!


  10. #10
    avishai is offline x10Hosting Member avishai is an unknown quantity at this point
    Join Date
    Sep 2005
    Posts
    32

    Re: how to add ads to phpbb forum?

    Thanks for the help,

    Avishai

Closed Thread
Page 1 of 2 12 LastLast

Similar Threads

  1. Replies: 3
    Last Post: 05-31-2006, 07:46 AM
  2. phpBB: Fully Modded Forum
    By TheJeffsta in forum Free Hosting
    Replies: 5
    Last Post: 04-14-2006, 06:28 PM
  3. phpBB Forum Problems
    By nycdlmusckat in forum Free Hosting
    Replies: 3
    Last Post: 10-10-2005, 02:46 PM
  4. Adding ad's to phpbb forum
    By haqzombie in forum Free Hosting
    Replies: 7
    Last Post: 07-31-2005, 12:35 PM
  5. Phpbb Forum Codes..how to add.
    By bernhardt in forum Free Hosting
    Replies: 1
    Last Post: 03-02-2005, 12:11 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
x10hosting free hosting for the masses
dedicated servers