+ Reply to Thread
Results 1 to 6 of 6

Thread: Adding Banner to Coppermine script

  1. #1
    mysoldier is offline x10Hosting Member mysoldier is an unknown quantity at this point
    Join Date
    Aug 2006
    Posts
    8

    Adding Banner to Coppermine script

    To be in compliance with the corporate free hosting, a banner has to be added to every page. How do I do this with the Coppermine script in Fantastico. I tried the custom header feature but it did not work.

  2. #2
    dyfuse's Avatar
    dyfuse is offline x10 Sophmore dyfuse is an unknown quantity at this point
    Join Date
    Apr 2006
    Posts
    196

    Re: Adding Banner to Coppermine script

    Quote Originally Posted by mysoldier
    To be in compliance with the corporate free hosting, a banner has to be added to every page. How do I do this with the Coppermine script in Fantastico. I tried the custom header feature but it did not work.
    For coppermine gallery it is probably easiest to add the advertisements after installation. You can do it through the administration panel ("Config") after logging in. Check out the category "Themes Settings", and in the "Path to custom header include" or "Path to custom footer include" box, enter in the name of the file which contains your ad code, i.e. footer.php.

    Copy the ad code to the file (Notepad is great for doing this) and name it footer.php, and upload it to your coppermine directory...It works for me.

  3. #3
    mysoldier is offline x10Hosting Member mysoldier is an unknown quantity at this point
    Join Date
    Aug 2006
    Posts
    8

    Re: Adding Banner to Coppermine script

    Thanks for the reply. I tried as you instructed but must be missing something as it didn't work.

    I c/p the corporate php code into a wordpad file and named that file header.php. The file was uploaded to /public_html/header.php (coppermine is installed in the root directory). From Config/Theme Settings I pointed to both /header.php and /public_html/header.php but never did a banner appear at the top of the page.

    Clue me in on what I did wrong

  4. #4
    dyfuse's Avatar
    dyfuse is offline x10 Sophmore dyfuse is an unknown quantity at this point
    Join Date
    Apr 2006
    Posts
    196

    Re: Adding Banner to Coppermine script

    Quote Originally Posted by mysoldier
    Thanks for the reply. I tried as you instructed but must be missing something as it didn't work.

    I c/p the corporate php code into a wordpad file and named that file header.php. The file was uploaded to /public_html/header.php (coppermine is installed in the root directory). From Config/Theme Settings I pointed to both /header.php and /public_html/header.php but never did a banner appear at the top of the page.

    Clue me in on what I did wrong
    No problem. (Just in case you were wondering I am on the advanced plan, so that's why I was quoting footer.php)

    Have you made sure you copied the corporate ad code correctly? Maybe it has a slight error in it, and therefore doesn't end up displaying anything at all! Just in case you want to compare, here is a copy of the code I put into footer.php (remember it's for advanced):

    Code:
    <br>
    <p>
    <script language='JavaScript' type='text/javascript' src='http://x10hosting.com/advert/adx.js'></script>
    <script language='JavaScript' type='text/javascript'>
    <!--
    	if (!document.phpAds_used) document.phpAds_used = ',';
    	phpAds_random = new String (Math.random()); phpAds_random = phpAds_random.substring(2,11);
    
    	document.write ("<" + "script language='JavaScript' type='text/javascript' src='");
    	document.write ("http://x10hosting.com/advert/adjs.php?n=" + phpAds_random);
    	document.write ("&amp;what=zone:3&amp;target=_blank");
    	document.write ("&amp;exclude=" + document.phpAds_used);
    	if (document.referrer)
    		document.write ("&amp;referer=" + escape(document.referrer));
    	document.write ("'><" + "/script>");
    //-->
    </script><noscript><a href='http://x10hosting.com/advert/adclick.php?n=a915c788' target='_blank'><img src='http://x10hosting.com/advert/adview.php?what=zone:3&amp;n=a915c788' border='0' alt=''></a></noscript>
    </p>
    <br>
    Just check to make sure your corporate code is ok and has no 'flaws' or errors. That's probably the most obvious thing you can do. The second could be trying testing that the "Path to custom header include" function in coppermine actually works for your installation!!

    You could try adding some test code to the start of your header.php file to see whether it will display it in your header section of the gallery. For example, maybe:

    Code:
    <p>Testing</p>
    <br />
    See whether it is actually displayed on your page. Hope this helps, and actually ends favourably. :happysad:

    EDIT: Try checking the codes out here: http://forums.x10hosting.com/ads.php
    Last edited by dyfuse; 08-17-2006 at 02:03 AM.

  5. #5
    mysoldier is offline x10Hosting Member mysoldier is an unknown quantity at this point
    Join Date
    Aug 2006
    Posts
    8

    Re: Adding Banner to Coppermine script

    Thanks ffadmin! Works great now. I was using the php code instead of the javascript code :laugh:

  6. #6
    dyfuse's Avatar
    dyfuse is offline x10 Sophmore dyfuse is an unknown quantity at this point
    Join Date
    Apr 2006
    Posts
    196

    Re: Adding Banner to Coppermine script

    Quote Originally Posted by mysoldier
    Thanks ffadmin! Works great now. I was using the php code instead of the javascript code :laugh:
    No problem!! That was probably the most likely reason. I suppose Coppermine was trying to do a php include on a file that actually had a php include function in it. Glad to be of help.

+ Reply to Thread

Similar Threads

  1. Server UP time Script
    By dharmil in forum Scripts & 3rd Party Apps
    Replies: 2
    Last Post: 04-03-2006, 04:39 PM
  2. [OFF] Banner Impressions
    By crazyboy168 in forum The Marketplace
    Replies: 9
    Last Post: 12-20-2005, 05:24 PM
  3. Custom Banner Request
    By Josh in forum The Marketplace
    Replies: 9
    Last Post: 12-11-2005, 11:44 AM
  4. Adding banner to SMF
    By Chatter911 in forum Free Hosting
    Replies: 3
    Last Post: 06-27-2005, 04:30 PM
  5. CGI - script, Advertisement _HELP.
    By kaliforna in forum Free Hosting
    Replies: 12
    Last Post: 06-02-2005, 06:01 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