Follow us on Twitter X-Cart on Facebook Wiki
Shopping cart software Solutions for online shops and malls
 

Product Options and Image previews - any ideas?

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions
 
Thread Tools Search this Thread
  #31  
Old 03-12-2006, 03:19 AM
 
Lionel Lionel is offline
 

Senior Member
  
Join Date: Dec 2005
Posts: 199
 

Default

how can I display the proper selected variant image in cart?
__________________
X-Cart Gold 4.0.17 [unix]
X-Cart Gold 4.0.18 [unix]
Reply With Quote
  #32  
Old 03-12-2006, 06:03 AM
 
ianwebster ianwebster is offline
 

Member
  
Join Date: Mar 2005
Posts: 14
 

Default

Like I say, if you make all your "variant" images the same size, then you can use the method that I explained in full earlier in this thread.

However, (for the purposes of showing the relevant "variant" image in the cart) if your variant images are different sizes then you will need to amend the previous code I gave to include the php function
Code:
getImageSize()
which sniffs the image size. That way you can dynamically output the width and height attributes proportionately in the cart.

Note this all assumes that you want to use large "variant" images on the product page and small thumbnail versions in the cart. In actuality we are using the same images but using the width and height parameters in the cart to make them into thumbnails so we can save on screen real estate)

Have a look at http://uk2.php.net/getimagesize for the full detail of the return values.

Since I am not using different size images, I dont really have a great need to investigate in detail how to implement this feature -- but in principle this will be the way to go (assuminmg you have a basic knowledge of php programmiung, you should be able to make some minor changes to include getImageSize instead of hard coding the width/height params as I currently do)
__________________
4.0.12
Linux
Reply With Quote
  #33  
Old 03-12-2006, 06:21 AM
 
Lionel Lionel is offline
 

Senior Member
  
Join Date: Dec 2005
Posts: 199
 

Default

Thanks. I got it. However, looks like this mod does not work with filesystem. I just switched from database to filesystem and it stopped working.

getImageSize() will not work as it needs a physical location.
-----------------------------
edit:
ok, works. I had to reupload all the variants images
__________________
X-Cart Gold 4.0.17 [unix]
X-Cart Gold 4.0.18 [unix]
Reply With Quote
  #34  
Old 03-12-2006, 01:49 PM
 
youngvet1 youngvet1 is offline
 

eXpert
  
Join Date: Aug 2005
Posts: 245
 

Default

After looking at the mod. One thing seems a bit awkward, or not what I would expect. (unless u do not have larger images for the various colors)

When u select a different color from the drop down, and the image switches when i slect to enlarge it that image is always the same image.

I would think that it should be the larger image of that color for example.
__________________
x-cart version 4.0.14
Reply With Quote
  #35  
Old 03-17-2006, 05:27 AM
 
ianwebster ianwebster is offline
 

Member
  
Join Date: Mar 2005
Posts: 14
 

Default

Simply because xcart have called their database table "xcart_thumbnails" doesnt mean you actually need to include thumbnail sized images rather than larger ones. This mod stores large images in the "xcart_thumbnails" table (rather than in the detailed images table). Here is an example of the mod in use

www.lastangelsonearth.co.uk/heavenly/product.php?productid=116176

There is no need to have a popup with "large/detailed" images in it since we are already showing the large images inline within the product display page. (it would be entirely possible to use this mod without having ANY images in the "detailed" images table. I happen to include them since it means I dont have to add a "detailed" image to the "xcart_thumbnail" table for products which only have a single option -- ie my detailed image is a "default" image if there are no "variant" images available)

Personally I am using the "detailed" images table to store "detailed" images -- if you rest your cursor on the little magnifying glass in the previous url link, you will see a "detailed" image.

However, if you wanted to have "even larger" popup images (which are stored in the "detailed" images table) then you will need to do a bit of javascript programming to select the correct image for the popup.
__________________
4.0.12
Linux
Reply With Quote
  #36  
Old 03-27-2006, 07:49 AM
 
raddison raddison is offline
 

Member
  
Join Date: Feb 2003
Posts: 19
 

Default

I agree, awesome mod . I'm having a problem with the alternate image showing up in the case where one is being used, otherwise it works great. Is anyone having this problem? Is there a solution?
__________________
x-cart 4.0.18
configurator
RMA - Soon
AOM - Soon
Flexy Rectangles
Reply With Quote
  #37  
Old 04-08-2006, 07:24 PM
 
subzero subzero is offline
 

eXpert
  
Join Date: Mar 2005
Posts: 238
 

Default

Quote:
Originally Posted by Lionel
Thanks. I got it. However, looks like this mod does not work with filesystem. I just switched from database to filesystem and it stopped working.

getImageSize() will not work as it needs a physical location.
-----------------------------
edit:
ok, works. I had to reupload all the variants images

Quote:
Originally Posted by jcnelson
Jeffos, did you ever figure out what needed to be changed on yours to get it to work? I am seeing a similar result. Everything looks as if it should work, however I get the buttons for Delete Image and Change Image where the variant image should be inserted.

This is store is currently using 4.0.13

i am have the same problem too no matter what i click on after uploading the image it just wont display them even as a thumb nail on the variants page
ik too am using file system but have been using it b4 i tried this mod. has anyone got any idea how to get this to work as i am a complete beginner with this coding lark lol
__________________
Version 4.0.17
Reply With Quote
  #38  
Old 05-24-2006, 09:40 AM
  SamD's Avatar 
SamD SamD is offline
 

Advanced Member
  
Join Date: Mar 2006
Location: New York
Posts: 38
 

Default

I would really like to use this mod, however ff i make the changes to the admin section do i still need to make all the other changes?
__________________
Version 4.1.8
(Upgraded from 4.0.1
Reply With Quote
  #39  
Old 05-25-2006, 08:23 AM
  SamD's Avatar 
SamD SamD is offline
 

Advanced Member
  
Join Date: Mar 2006
Location: New York
Posts: 38
 

Default

Quote:
Originally Posted by jcnelson
Jeffos, did you ever figure out what needed to be changed on yours to get it to work? I am seeing a similar result. Everything looks as if it should work, however I get the buttons for Delete Image and Change Image where the variant image should be inserted.

This is store is currently using 4.0.13

i did all the admin stuff and i am gettin this problem too.. did you ever fix this jcnelson?
__________________
Version 4.1.8
(Upgraded from 4.0.1
Reply With Quote
  #40  
Old 08-02-2006, 07:32 PM
 
mattw mattw is offline
 

Member
  
Join Date: Nov 2004
Posts: 18
 

Default

first i want to start with a thank you. this is an awesome mod, from start to finish.

im trying to add my images in bulk (i have almost 1000 total products including variants). im using a file system NOT blobs. does anyone know a script similiar to the IMPORT IMAGES already in the admin console that would accomidate this mod. more scecifically i am looking to upload thumbnail images using only PRODUCT CODE and the image path. again, thanks for everyones help so far and in the future.
__________________
Matthew E Wawrzyniec
iCrunk LLC
Xcart v4.0.14
Reply With Quote
Reply
   X-Cart forums > X-Cart 4 > Dev Questions



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -8. The time now is 05:04 PM.

   

 
X-Cart forums © 2001-2020