Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

No popup for images, and original size of images


k_b

Recommended Posts

Posted

Hi.

We are trying to get two things working in osCommerce.

 

1.

In the product page, that is when viewing a product (product_info.php) we would like the image to be in full size, not scaled.

is it possible?

 

2.

in the same page, is it possible to turn off the "click to enlarge" function?

 

 

 

/kb

Posted

Find this starting on line 108 in product_info.php:

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

document.write('<?php echo '<a href="java script:popupWindow(\\\'' . tep_href_link(FILENAME_POPUP_IMAGE, 'pID=' . $product_info['products_id']) . '\\\')">' . tep_image(DIR_WS_IMAGES . $product_info['products_image'], addslashes($product_info['products_name']), SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT, 'hspace="5" vspace="5"') . '<br>' . TEXT_CLICK_TO_ENLARGE . '</a>'; ?>');

//--></script>

<noscript>

<?php echo '<a href="' . tep_href_link(DIR_WS_IMAGES . $product_info['products_image']) . '" target="_blank">' . tep_image(DIR_WS_IMAGES . $product_info['products_image'], $product_info['products_name'], SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT, 'hspace="5" vspace="5"') . '<br>' . TEXT_CLICK_TO_ENLARGE . '</a>'; ?>

</noscript>

 

And replace it with:

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

document.write('<?php //echo '<a href="java script:popupWindow(\\\'' . tep_href_link(FILENAME_POPUP_IMAGE, 'pID=' . $product_info['products_id']) . '\\\')">' . tep_image(DIR_WS_IMAGES . $product_info['products_image'], addslashes($product_info['products_name']), SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT, 'hspace="5" vspace="5"') . '<br>' . TEXT_CLICK_TO_ENLARGE . '</a>'; ?>');

//--><!--</script>-->

<!--<noscript>-->

<?php echo tep_image(DIR_WS_IMAGES . $product_info['products_image'], $product_info['products_name'], 'hspace="5" vspace="5"') . '<!--<br>' . TEXT_CLICK_TO_ENLARGE . '</a>-->'; ?>

<!--</noscript>-->

 

That doesn't give you any customization but it might be what you want.

Other great Open Source (Free) programs: (Free as in free speech not free beer)

The Gimp - An image program. | Firefox - All you have to do is add the Web Developer add-on to make this web browser complete. | FileZilla - An ftp program. | Inkscape - A good program to create images with. | Thunderbird - An email program. | Openoffice.org - An office suite that is compatible with MS Office. | Abiword - Another office suite. | Audacity - A sound recording tool. | ddp's Picks | Wordpress - An easy to use blogging software. | Joomla - An easy to use CMS that has ecommerce plug-ins. | Drupal - Another CMS

How do I find these programs? Google Search!

Posted
Find this starting on line 108 in product_info.php:

And replace it with:

That doesn't give you any customization but it might be what you want.

 

 

Thank you very much!

i also changed line 112 to

<?php echo '<a href="' . tep_href_link(DIR_WS_IMAGES . $product_info['products_image']) . '" target="_blank">' . tep_image(DIR_WS_IMAGES . $product_info['products_image'], $product_info['products_name'], 'width=', 'height=', 'hspace="5" vspace="5"') . '<!-- <br>' . TEXT_CLICK_TO_ENLARGE . '</a> -->'; ?>

 

(replacing:

SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGT with

'width=', 'height=' )

 

this gives me original size images on the product page.

Archived

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

×
×
  • Create New...