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: {gallery} -i want to find where this is  (Read 2568 times)

0 Members and 1 Guest are viewing this topic.

mojito

  • Coppermine newbie
  • Offline Offline
  • Posts: 9
{gallery} -i want to find where this is
« on: May 23, 2005, 11:11:07 am »

I would like to edit {gallery}  but this is in the .html file, so it must be php including this code so that {gallery} can be resolved or evaluated.

I'm lacking the php to know how to use these syntaxes -> =>  {object}

is it an object? it doesnt look like a function. Cant find help on php.net etc. I'm not a php novice just havent really got the hang of this syntax yet. => is a propert access operator so what is ->?

I want to be able to put a few random imges and a few dependant images on my front page. I need to understand the coppermine code methodology first.

regards

mojito
Logged

Joachim Müller

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 47843
  • aka "GauGau"
    • gaugau.de
Re: {gallery} -i want to find where this is
« Reply #1 on: May 24, 2005, 08:11:06 am »

The stuff in curly brackets in template.html are just placeholders, that's all. When coppermine is run, the functional core reads template.html and theme.php and then fills the placeholders within template.html with dynamic content that is generated based on the individual code blocks of theme.php; then everything is sent to the output.
The {GALLERY} chunk is actually the main block of the page (everything that is not meta tag or navigation), so I can't explain to you easily where to look at, as there are various places, depending on what you want to accomplish.

I don't want to make you look bad, but it should be quite obvious if you know your way around in PHP that {GALLERY} can't be part of the PHP command syntax, so you can't look this up on php.net. Let me assure you: it's neither an object nor a function, just a plain placeholder that has been chosen just because users would hardly want the word {GALLERY} to appear on their site. The original creator of coppermine (Gregory Demar) who decided to use this could as well have chosen @FOOBAR@ or [[::WHATEVER::]].

Describe what you want to accomplish, will make it easier to tell you where to look at in the code.
Logged

mojito

  • Coppermine newbie
  • Offline Offline
  • Posts: 9
Re: {gallery} -i want to find where this is
« Reply #2 on: May 24, 2005, 04:18:30 pm »

Thanks for the response. It makes for interesting reading.
The server technology is php only so something in the php code can recognise or evaluate {curlybraces} when it finds it.

ok so I dont need to know where that refference  is declared but {GALLERY} contains the interesting bits for me to add my custom images on my home page. I just would like to understand so that I can place some images at different areas "off" of my coppermine site. I am using coppermine in a mambo wrapper and on my homepage I would like a few coppermine images like

LAST 5 UPLOADED IMAGES
*
*
*
*
*

thats the sort of thing I want to achieve so I need to understand how coppermine part {gallery} works to do this or at least find which bit of code gets executed when {GALLERY} is reached in that html file..

thanks gau gau, i appreciate it seems like you are all alone sometimes moderating.

mojito
Logged

Tranz

  • Dev Team member
  • Coppermine addict
  • ****
  • Country: 00
  • Offline Offline
  • Gender: Female
  • Posts: 6149
Re: {gallery} -i want to find where this is
« Reply #3 on: May 24, 2005, 04:32:00 pm »

There is a subboard for cpm fetch that will help you accomplish that.
Logged
Pages: [1]   Go Up
 

Page created in 0.027 seconds with 20 queries.