Guest LNT Posted October 25, 2005 Share Posted October 25, 2005 Hi All, Right, I have just been asked to put some images in the categories area instead of the blank blue folder. Seeing as cube cart resizes everything else I thought this would too apply here. However I was shocked to find out that it doesnt resize the pictures for the categories like it would for products. Can anyone shed any light on this and also if anyone has a hack for this, then that too would be appreciated. Cheers, Tom. Quote Link to comment Share on other sites More sharing options...
markscarts Posted October 26, 2005 Share Posted October 26, 2005 Hmm, I like the main category images to be the same size as the product images . . . and I like to create images specificly for the main categories, usually a collage of some product images for that category. As to subcategories, I just re-size them in the stylesheet. Open up layout.css and look for the i.d. selector, #subCats, and the class selector, .subCat Between these two (that is, after the closing } of #subCats and before .subCat) place the following blocks of code: #subCats image { width:175px; margin-top: 5px; } #subCats img { width:175px; margin-top:5px; } This will resize the Subcategory images to your preferences, just change the values 175px and 5px to the values you want BTW, this tip is included in my tutorial entitled, "Latest Products & Subcategory Display Fix" - look in the downloads sect9ion under tutorials and documentation for CC3 . . . To summarize . . . 1. Make custom image for main category images, in whatever size you want. Upload to images/uploads 2. Set size (and any other properties you wish to set) for subcategory images by adding statements about image in #subCats in the layout.css stylesheet. Quote Link to comment Share on other sites More sharing options...
Guest LNT Posted October 26, 2005 Share Posted October 26, 2005 #subCats image { width:175px; margin-top: 5px; } #subCats img { width:175px; margin-top:5px; } Hi CC3 and thanks for the help, I havent tried this yet, but would I be right in thinking that if I also wanted to specify how tall the image was to be I could do this by adding the following 2 lines to your existing fix like so Also when I say sub categories I mean you have your main categories in the links on the left for instance; Homepage Gifts Futuristic Oldies Sales etc etc I mean the category that would be inside one of these. To me this would be a subcategory how ever to others this may just simply be another category with the real subcategory being within this second one like this; Homepage Gifts ---->Baskets (My subcategory) ------------>Hampers (Possibly everyone else sub category) Futuristic Etc Etc Which would you deem as being a category and sub category? This is so I dont go an edit the files only to find it was the wrong bit I edited Cheers, Tom.#subCats image { width:175px; height:60px; margin-top: 5px; } #subCats img { width:175px; height:60px; margin-top:5px; } Quote Link to comment Share on other sites More sharing options...
markscarts Posted October 26, 2005 Share Posted October 26, 2005 Hi Tom, 1. Top-level Categories are listed on index page. Anyhing under a top-level cate3gory is a subcategory. 2. You can specify a height, but there is generally no need to do this. The image will resize proportionally, so shrinking the width will also shrink the height accordingly. If you specify both height and width, you may distort the image's proportions. 3. You can specify any properties you want there, that can be used with "image" or "img" - Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.