Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Image Popup Window


M Ivs

Recommended Posts

Posted

Please have a look at my image popup windows

 

http://prophoto.ie/catalog/index.php?cPath=23

 

 

I would like to have the window aprox 500x500px

I need to center my images in the window.

 

I also need to add my logo beneath the image and possibly a line of copyright text in the bottom right corner

A lot of people suggest a watermark.I'll be doing that anyway but I really need the logo beneath also!

 

My images are always 360x288pixels in both landscape and portrait format

 

Code from popup_image.php

<script language="javascript"><!--

var i=0;

function resize() {

if (navigator.appName == 'Netscape') i=40;

if (document.images[0]) window.resizeTo(document.images[0].width +150, document.images[0].height+200-i);

self.focus();

}

 

 

Code from product_info.php

<script language="javascript"><!--

function popupWindow(url) {

window.open(url,'popupWindow','toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,res

izable=no,copyhistory=no,width=540,height=540,screenX=0,screenY=0,top=0,left=0')

}

//--></script>

 

I would really appreciate any help

Thank you

Posted

After reading your message I started toying around with mine and here is what I come up with. First I went to header.php and copied the line that displays the logo then pasted it into popup_image.php just under the line that says:

 

<body onload="resize();">
<?php echo tep_image(DIR_WS_IMAGES . $products['products_image'], $products['products_name']); ?>

 

so here is what it looks like in mine:

<body onload="resize();">
<?php echo tep_image(DIR_WS_IMAGES . $products['products_image'], $products['products_name']); ?>
   <center><td valign="middle"><?php echo '<a href="' . tep_href_link(FILENAME_DEFAULT) . '">' . tep_image(DIR_WS_IMAGES . 'logo.gif', '(c) Copyright, Golden Empire Photography') . '</a>'; ?></td>

 

 

then in the line that says:

  if (document.images[0]) window.resizeTo(document.images[0].width +30, document.images[0].height+170-i);

I had to adjust the height+60 to 170 to accomodate my logo..

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...