Where do I edit html to customise image display ? Where do I edit html to customise image display ?
 

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]

Main Menu

Where do I edit html to customise image display ?

Started by AndrewC, December 12, 2005, 09:37:09 PM

Previous topic - Next topic

0 Members and 2 Guests are viewing this topic.

AndrewC

I'm trying to customise my theme and want to be able to add some framing images around my displayed images. On my old clunky webpage I did this just by adding top, left, right and bottom frame elements in cells around my image (a 3x3 table with the image in the centre cell).

With CPG I can't see where I need to go to do this. What I want is to be able to add other rows and cells to the standard table that CPG creates:

<!-- Start standard table -->
<table align="center" width="600px" cellspacing="1" cellpadding="0" class="maintable">
        <tr>
                <td align="center" class="display_media" nowrap="nowrap">
                        <table cellspacing="2" cellpadding="0" class="imageborder">
                                <tr>
                                        <td align="center">
                                                <img src="albums/wildlife/test/040328AVI001.jpg" width="265" height="400" class="image" border="0" alt="" /><br />
                                        </td>
                                </tr>
                        </table>
                </td></tr>
                </td>
        </tr>
</table>


Can someone please point me in the right direction.

Thanks, Andrew

Joachim Müller

why don't you just edit the css properties of the the class that controls the look of the table - nested tables just for design purposes are being considered somewhat deprecated. If you want this to happen to all coppermine tables, edit the maintable class. If you want to edit just the table where your pics are shown, edit display_media.
Add some extra margin or padding to it.
To do so, edit themes/yourtheme/style.css, find the class name and edit the definition in curly braces that comes after it.

AndrewC

Quote from: GauGau on December 13, 2005, 09:22:13 AM
why don't you just edit the css properties of the the class that controls the look of the table - nested tables just for design purposes are being considered somewhat deprecated. If you want this to happen to all coppermine tables, edit the maintable class. If you want to edit just the table where your pics are shown, edit display_media.
Add some extra margin or padding to it.
To do so, edit themes/yourtheme/style.css, find the class name and edit the definition in curly braces that comes after it.

With css padding, margin and borders I can see how to add a solid matte and frame but I like to have my images "framed" with a bevelled matte or drop shadow and a sculpted frame. Easy to add in PS but then you increase the image upload size.

So I went looking for where display_media is used a class declaration and found where I need to edit - include/themes.inc.php.

Is there any kind of guide to what all the different php pages are used for ? I guess a lot are self explanatory such as (exifReader.inc.php) but is there any sort of overview / flowchart to Coppermine which would help a newbie find his/her way around ?

Joachim Müller

don't edit include/themes.inc.php.! Edit themes/yourtheme/theme.php. If the section you want to edit doesn't exist in your theme.php file, copy&paste it from the sample theme. I repeat: do not edit themes.inc.php

AndrewC

Quote from: GauGau on December 14, 2005, 08:23:40 AM
don't edit include/themes.inc.php.! Edit themes/yourtheme/theme.php. If the section you want to edit doesn't exist in your theme.php file, copy&paste it from the sample theme. I repeat: do not edit themes.inc.php

So does anything declared in themes/yourtheme/theme.php take precedence over the same instructions found elsewhere outside themes/yourtheme/ ???