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: Adding skyscraper ads to the right of mid-sized thumbs?  (Read 8025 times)

0 Members and 1 Guest are viewing this topic.

CodyLoco

  • Coppermine newbie
  • Offline Offline
  • Posts: 6
Adding skyscraper ads to the right of mid-sized thumbs?
« on: November 13, 2006, 08:34:24 pm »

Hi,
I just have a quick question- I'm trying to hack away at Coppermine (1.4.10 Stramm) with the Tentacles theme to try and add a skyscraper advertisement right beside the mid-sized thumbnail to the right.  I've managed to hack the ads into the front page and the footers by editing index.php and template.html, but I'm guessing the code for the actual mid-sized advert is somewhere within theme.php.  I've tried inserting it in several different spots that generate the code for the pages but I can't seem to figure out which of the nearly 1000 lines of code it is :P

Could someone please point me to the line that starts the mid-size thumbnail of the picture?  If you're wondering what I mean, look here:
http://vanguard.gamers-pad.com/displayimage.php?album=random&cat=0&pos=-24

I want it to the right of the big image.

A pointer is all I need! :)  Thanks in advance again!  And sorry if I posted this in the wrong forum but I'm guessing it's right since Stramm made that theme to my knowledge.

Thanks!

~Cody
« Last Edit: November 17, 2006, 08:27:04 am by GauGau »
Logged

Nibbler

  • Guest
Re: Adding skyscraper ads to the right of mid-sized thumbs?
« Reply #1 on: November 13, 2006, 10:19:30 pm »

You can do that via theme_display_image()
Logged

CodyLoco

  • Coppermine newbie
  • Offline Offline
  • Posts: 6
Re: Adding skyscraper ads to the right of mid-sized thumbs?
« Reply #2 on: November 14, 2006, 10:01:37 am »

Hi thanks for the reply, but do you mind being a bit more specific?  You've taken a step outside of my comfort zone here.  Are you talking about line 2018 of themes.inc.php?  And if so would the code go right after line 2030
Code: [Select]
    echo $picture; ?  Any special considerations I need to take?  The code that will be put in is all in Javascript.

Please let me know, I don't want to start hacking away at the wrong spot :)

Thanks again!

~Cody
Logged

Stramm

  • Moderator
  • Coppermine addict
  • ****
  • Country: 00
  • Offline Offline
  • Gender: Male
  • Posts: 6006
    • Bettis Wollwelt
Re: Adding skyscraper ads to the right of mid-sized thumbs?
« Reply #3 on: November 14, 2006, 04:58:49 pm »

I'd copy the entire $template_display_media from themes/sample/theme.php to the tentacle theme.php. Find
in that template
Code: [Select]
                                        <td align="center">
                                                {IMAGE}

                                        </td>
and edit it to your likings eg
Code: [Select]
                                        <td align="center">
                                                {IMAGE}

                                        </td><td><img src="yadda"></td>

Joachim Müller

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 47843
  • aka "GauGau"
    • gaugau.de
Re: Adding skyscraper ads to the right of mid-sized thumbs?
« Reply #4 on: November 15, 2006, 07:31:36 am »

Are you talking about line 2018 of themes.inc.php? 
Do not edit include/themes.in.php - under no circumstances. Only edit themes/yourtheme/theme.php. If you can find a function there that you'd like to see changed, copy the corresponding function from themes/sample/theme.php first into themes/yourtheme/theme.php. Then edit at will.
Logged

CodyLoco

  • Coppermine newbie
  • Offline Offline
  • Posts: 6
Re: Adding skyscraper ads to the right of mid-sized thumbs?
« Reply #5 on: November 16, 2006, 12:07:53 am »

Ah so themes.inc.php is the default then?
Logged

Joachim Müller

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 47843
  • aka "GauGau"
    • gaugau.de
Re: Adding skyscraper ads to the right of mid-sized thumbs?
« Reply #6 on: November 16, 2006, 06:28:11 am »

Yes: everything that is not defined in your custom theme will be drawn from themes.inc.php. Your custom theme will be taken into account first.
Logged

CodyLoco

  • Coppermine newbie
  • Offline Offline
  • Posts: 6
Re: Adding skyscraper ads to the right of mid-sized thumbs?
« Reply #7 on: November 17, 2006, 04:31:53 am »

Great thanks guys it worked perfectly!
:)
Logged
Pages: [1]   Go Up
 

Page created in 0.02 seconds with 20 queries.