Advanced search  

News:

cpg1.5.48 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.46 or older update to this latest version as soon as possible.
[more]

Pages: [1]   Go Down

Author Topic: google adsense code on displaimage.php  (Read 7629 times)

0 Members and 1 Guest are viewing this topic.

calyps

  • Coppermine newbie
  • Offline Offline
  • Posts: 10
google adsense code on displaimage.php
« on: May 06, 2009, 01:01:57 pm »

Hello All,

I want to display google adsense code on the left and right hand side of the actual image on displayimage.php. Please refer to the screen shot. The screen shot have two black boxes were i want to display the ads (in square box). Please let me know how and what is the file that i will need to make change to?


Your help would be highly appreciated :)

Thanks,

Ali
Logged

Joachim Müller

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 47843
  • aka "GauGau"
    • gaugau.de
Logged

calyps

  • Coppermine newbie
  • Offline Offline
  • Posts: 10
Re: google adsense code on displaimage.php
« Reply #2 on: May 08, 2009, 06:47:23 pm »

Hello,

Sorry for not sending you the URL to the actual gallery. The gallery URL is http://www.thebestin.asia/Gallery/index.php

and the picture can be viewed directly @ http://www.thebestin.asia/Gallery/displayimage.php?album=random&cat=0&pos=-33

As you can see there is a big gap on the left and right hand side of the website (light gray area) which i need to cover it with advertisement.


Thanks,

Ali
Logged

Joachim Müller

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 47843
  • aka "GauGau"
    • gaugau.de
Re: google adsense code on displaimage.php
« Reply #3 on: May 09, 2009, 02:39:19 pm »

You need to upgrade first!
Logged

calyps

  • Coppermine newbie
  • Offline Offline
  • Posts: 10
Re: google adsense code on displaimage.php
« Reply #4 on: May 17, 2009, 07:50:43 pm »

Hi,

I thought I have the latest version of Coppermine? Please help.


Thanks,

Ali
Logged

phill104

  • Administrator
  • Coppermine addict
  • *****
  • Country: gb
  • Offline Offline
  • Gender: Male
  • Posts: 4885
    • Windsurf.me
Re: google adsense code on displaimage.php
« Reply #5 on: May 17, 2009, 11:20:55 pm »

Far from it. You are using <!--Coppermine Photo Gallery 1.4.9 (stable)--> while the current release is 1.4.22 making you 13 revisions behind.

http://coppermine-gallery.net/demo/cpg14x/docs/index.htm#upgrade_why

I'm assuming from your comment "I thought I had the latest revision" that you are using one installed by your webhost. If that is the case this is a classic reason why we are against the use of such installers.

Download the latest version from here then follow all the upgrade steps outlined in the docs.

http://coppermine-gallery.net/demo/cpg14x/docs/index.htm#upgrade
Logged
It is a mistake to think you can solve any major problems just with potatoes.

calyps

  • Coppermine newbie
  • Offline Offline
  • Posts: 10
Re: google adsense code on displaimage.php
« Reply #6 on: June 30, 2009, 11:08:05 pm »

finally managed to get it done now. Sorry for such a late reply. Got stuck with my studies.

Any help now?

Thanks,

Sorry once again :(
Logged

Joe Carver

  • Dev Team member
  • Coppermine addict
  • ****
  • Country: us
  • Offline Offline
  • Gender: Male
  • Posts: 1545
  • aka 'i-imagine'
    • Home Page
Re: google adsense code on displaimage.php
« Reply #7 on: June 30, 2009, 11:42:49 pm »

Look in the Sample theme for this section

Code: [Select]
// HTML template for intermediate image display
$template_display_media = <<<EOT
 
AND ALL CODE UNTIL

EOT;

Copy it into your theme and modify to your needs.

Joachim Müller

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 47843
  • aka "GauGau"
    • gaugau.de
Logged

calyps

  • Coppermine newbie
  • Offline Offline
  • Posts: 10
Re: google adsense code on displaimage.php
« Reply #9 on: July 08, 2009, 11:28:34 pm »

Hello,

Thank you for providing me with some valuable website and links to existing posts! I have spend several days trying to fix and get the ads on the right spot. However I failed  :'(

I managed to get the ads working right next to the images but that impacts the layout of the screen. Also, i managed to get the whole gallery (including albums and the rest of the pages) to reduce in size in width and installed ads on the left and right .. however, I just want them to be on displayimage file in the box area and not impacting any layout issues.
(see image in my first post)

Any help would be highly appreciated!

Thanks,

Ali
Logged

Joachim Müller

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 47843
  • aka "GauGau"
    • gaugau.de
Re: google adsense code on displaimage.php
« Reply #10 on: July 09, 2009, 11:12:47 am »

We need to see what you did. Zip your custom theme folder and attach the zip to your posting.
To me it seems like you did quite the opposite of what you're supposed to do: you edited http://www.thebestin.asia/Gallery/themes/rainy_day/template.html and dumped the adbrite code right above the placeholder token {GALLERY}, which is not what the thread I have refered to says.

In fact I haved posted nearly the identical information in the thread I have refered to:
The code you refered to indeed needs to go into themes/yourtheme/theme.php. If you want answers, post a link to your gallery and let us see your changes by zipping your custom theme folder and attaching the zip archive to your posting (using "additional options" when composing your message).
Why don't you start playing by the rules - do what supporters say if you want support.
Logged

calyps

  • Coppermine newbie
  • Offline Offline
  • Posts: 10
Re: google adsense code on displaimage.php
« Reply #11 on: July 11, 2009, 12:41:52 am »

Hello,

Sorry! Basically, i tried everything but when it all failed i tried playing with it myself and stopped half way though .. Anyway, I will try again tomorrow and see what results i get. Thank you once again for helping me out so far. Much appreciated!

Thanks,

Logged

Joachim Müller

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 47843
  • aka "GauGau"
    • gaugau.de
Re: google adsense code on displaimage.php
« Reply #12 on: July 12, 2009, 09:52:12 am »

Why don't you start playing by the rules - do what supporters say if you want support.
You don't need to reply or start a new thread if you don't do as suggested.
Logged
Pages: [1]   Go Up
 

Page created in 0.022 seconds with 19 queries.