This is a discussion on Image size hack for product pages within the osCMax v2 Customization/Mods forums, part of the osCMax v2.0 Forums category; I was dissatisfied with the "Configuration --> Images" options. For some reason you are stuck with the "small" image size ...
| |||||||
| Register | FAQ | Members List | Calendar | Mark Forums Read |
|
#1
| |||
| |||
| I was dissatisfied with the "Configuration --> Images" options. For some reason you are stuck with the "small" image size for pretty much every instance of your product image on the site. I wanted the ability to specify a separate image size for product information pages, so I set it up in the following way: 1) inserted two rows into the configuration table with new keys PRODUCT_PAGE_IMAGE_WIDTH and PRODUCT_PAGE_IMAGE_HEIGHT, configuration group 4, and altered the sort order values to place them directly below SMALL_IMAGE_*. 2) global substitution of "PRODUCT_PAGE_IMAGE_" for "SMALL_IMAGE_" in product_info.tpl.php and product_listing.php If this work is redundant with another project and/or has some pitfalls I didn't think of, forgiveness and enlightenment would be appreciated. :) |
|
#2
| |||
| |||
| Quote:
Does anybody have other suggestion beside this please let me know. Thanks!. ---- Edit ----- My system had a hic-ups, restarting somehow fixed the issue... Thanks for this hack. It helped me a lot on fixing things the way I wanted!!! Last edited by vbrookie; 03-26-2007 at 07:22 AM. Reason: Restarted and everything's ok! |
|
#3
| |||
| |||
| WHO WHEN WHAT WHERE HOW! Is this in the sql file. A file in admin or otherwise...I need assistnace. |
|
#4
| |||
| |||
| Pardon me while I talk to myself.... I figured it out. Using PHPADMIN I located the configuration table and "browsed" it. I found SMALL_IMAGE_WIDTH & SMALL_IMAGE_HEIGHT. I edited each with PRODUCT_IMAGE_* and SAVED AS a new row and set the sort to the SORT # following the SMALL_IMAGE_HEIGHT. Just trying to help those who may be a BOOB NOOB like me. Thanks, Angie |
|
#5
| |||
| |||
| and for us that don't have phpMyadmin access?? I want to re-size the image in my shoppingcart, and only there.. PHP Code: And if not, can someone explain more step-by-step how to add a Shoppingcart_Image_width to the config, If you only have ftp access? Thanks! |
|
#6
| |||
| |||
| I don't think it is possible. Sorry about that. You should move your site to a hosting service that provides phpadmin access. Last edited by michael_s; 04-18-2007 at 03:03 PM. Reason: self promotion not allowed |
|
#7
| ||||
| ||||
| Give it a try.. just change the constants to numbers (you may need to put them in single quotes.
__________________ Michael Sasek osCMax Developer
|
|
#8
| |||
| |||
| If you have ftp access, you can install PHPmyAdmin yourself. It's free open source. At least I was able to do it on a host I used to have that didn't have it, and it was fairly easy. But like the other guy said, there are so many hosts that provide it these days with your hosting, why bother with a host that doesn't? |
|
#9
| |||
| |||
| Quote:
|
|
#10
| |||
| |||
| I did this and it works fine.. (SMALL_IMAGE_HEIGHT * '1.5') Code: <script language="javascript" type="text/javascript"><!--
document.write('<a href="javascript:popupImage(\'<?php echo tep_href_link(FILENAME_POPUP_IMAGE, 'pID=' . $product_info['products_id'] . '&type=' . $lg_image_ext); ?>\',\'<?php echo ((int)$image_size[1] + 30); ?>\',\'<?php echo ((int)$image_size[0] + 5); ?>\');"><?php echo tep_image(DIR_WS_IMAGES . $product_info['products_image'], addslashes($product_info['products_name']), (SMALL_IMAGE_WIDTH * '1.5'), (SMALL_IMAGE_HEIGHT * '1.5')); ?><br /><span class="smallText"><?php echo TEXT_CLICK_TO_ENLARGE; ?></span></a>');
//--></script>
<noscript>
<a rel="nofollow" href="<?php echo tep_href_link($image_lg . '.' . $lg_image_ext); ?>" target="_blank"><?php echo tep_image(DIR_WS_IMAGES . $product_info['products_image'], stripslashes($product_info['products_name']), (SMALL_IMAGE_WIDTH * '1.5'), (SMALL_IMAGE_HEIGHT * '1.5')); ?><br /><span class="smallText"><?php echo TEXT_CLICK_TO_ENLARGE; ?></span></a>
|
| Thread Tools | |
| |
| ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| How to change the image size on product page? | groggory | osCMax v2 Customization/Mods | 1 | 02-08-2006 07:06 PM |
| Set Product Page Image Size | groggory | osCMax v2 Customization/Mods | 0 | 01-22-2006 04:52 PM |
| Clicking product image to view larger size | twinklep | osCommerce 2.2 Modification Help | 2 | 09-07-2004 06:35 AM |
| Need help with a simple product listing hack... | Nocturnaloner | osCommerce 2.2 Modification Help | 2 | 06-04-2004 09:14 AM |
| image size | Anonymous | osCMax v1.7 Discussion | 0 | 04-15-2004 06:15 PM |