forum.coppermine-gallery.net
Support => cpg1.3.x Support => Older/other versions => cpg1.3 Themes/Skins/Templates => Topic started by: photofreak on August 31, 2004, 01:17:10 pm
-
I am using theme Final Fantasy!
When I select a pciture a pop-up will open but will not have the prober size - it is to small!
What can I do about it?
www.digipixz.com
-
Coppermine doesn't touch the original images so the size shouldn't change at all. The one image you have in your gallery displays correctly. 384x500 is the pop up size, 307x400 is the intermediate size, and 77x100 is the thumbnail size.
-
The pop-up is smaller then the picture! I always have to adjust it manaully.
When I use theme MAX then the pop-up is the correct size as the picture?
-
Open displayimage.php and find this code;
if ($mime_content['content']=='image') {
if (isset($image_size['reduced'])) {
$winsizeX = $CURRENT_PIC_DATA['pwidth'] + 16;
$winsizeY = $CURRENT_PIC_DATA['pheight'] + 16;
Change the 2x '16' to 18, and see if that does it. make sure you refresh when you test. If 18 doesn't work, try 20.
-
Perfect it works!
Can allso anyone tell me how to change the background off the pop-up because i want it complete black!
-
edit displayimage.php, find
<body scroll="auto" marginwidth="0" marginheight="0">
and add a style attribute to it, so it looks like this:<body scroll="auto" marginwidth="0" marginheight="0" style="background-color:black">
Joachim
-
After changing is nothing will change I still have te background in the image like the main website. I see the white thin line.
Have a look at www.digipixz.com
-
This is the code for the pop-up (to be found within displayimage.php):
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title><?php echo $CONFIG['gallery_name'] ?>: <?php echo $lang_fullsize_popup['click_to_close'];
?></title>
<meta http-equiv="content-type" content="text/html; charset=<?php echo $CONFIG['charset'] == 'language file' ? $lang_charset : $CONFIG['charset'] ?>" />
<link rel="stylesheet" href="<?php echo $THEME_DIR ?>style.css" />
<script type="text/javascript" src="scripts.js"></script>
</head>
<body scroll="auto" marginwidth="0" marginheight="0">
<script language="JavaScript" type="text/JavaScript">
adjust_popup();
</script>
<table width="100%" height="100%" border="0" cellpadding="0" cellspacing="2">
<td align="center" valign="middle">
<table cellspacing="2" cellpadding="0" style="border: 1px solid #000000; background-color: #FFFFFF;">
<td>
<?php
if (isset($HTTP_GET_VARS['picfile'])) {
if (!GALLERY_ADMIN_MODE) cpg_die(ERROR, $lang_errors['access_denied'], __FILE__, __LINE__);
$picfile = $HTTP_GET_VARS['picfile'];
$picname = $CONFIG['fullpath'] . $picfile;
$imagesize = @getimagesize($picname);
echo "<a href=\"javascript: window.close()\"><img src=\"" . path2url($picname) . "\" $imagesize[3] class=\"image\" border=\"0\" alt=\"\" title=\"$picfile\n" . $lang_fullsize_popup['click_to_close'] . "\"/></a><br />\n";
} elseif (isset($HTTP_GET_VARS['pid'])) {
$pid = (int)$HTTP_GET_VARS['pid'];
$sql = "SELECT * " . "FROM {$CONFIG['TABLE_PICTURES']} " . "WHERE pid='$pid' $ALBUM_SET";
$result = db_query($sql);
if (!mysql_num_rows($result)) cpg_die(ERROR, $lang_errors['non_exist_ap'], __FILE__, __LINE__);
$row = mysql_fetch_array($result);
$pic_url = get_pic_url($row, 'fullsize');
$geom = 'width="' . $row['pwidth'] . '" height="' . $row['pheight'] . '"';
echo "<a href=\"javascript: window.close()\"><img src=\"" . $pic_url . "\" $geom class=\"image\" border=\"0\" alt=\"\" title=\"" . htmlspecialchars($row['filename']) . "\n" . $lang_fullsize_popup['click_to_close'] . "\"></a><br />\n";
}
?>
</td>
</table>
</td>
</table>
</body>
</html>
Feel free to edit it as you like, e.g. by removing the reference to the external stylesheet and putting some inline or embedded css attribtues into it.
Joachim
-
Another question, when you have a look at www.digipixz.com you see the the space between LOGIN and LAST UPLOADS is not the same as the other links.
Where can ik fix thas so it has the same space between?
-
we have a "one question per thread" policy on this board. You already got answered two questions on this thread. Yet another (third) question is definitely too much. Locking this thread.
Joachim