PDA

View Full Version : mopics follow-up



chrismole
03-12-2004, 09:39 AM
I have two questions...

1. How can I use a thumb and big image for the supporting images? As I see it, the naming convention does not allow for thumbs AND big images for the supporting images. If this is incorrect, please provide some more instructions. I tried this, but it does not work:
image1_pic1.jpg (supporting thumb)
image1_big1.jpg (supporting big)

2. Is there a way to ignore the Small Image Width and Height pixel values and just let the images be their original size? If I have a thumb and a big image, what's the point of resizing them in the IMG tag? I have many images that are not the same proportion (some landscape, some portrait) and these values are distorting my images. Any suggestions?

thanks,
Chrismole

gheffron
03-13-2004, 01:58 AM
I'm very interested in these same issues. Mopics is a little hard to find instructions for. Anyone who wanted to do a basic intro to Mopics would provide a lot of benefit for us newbies out there.

Cheers,
Greg

chrismole
03-13-2004, 06:40 AM
msasek has posted a general how-to (see below), but my two questions are not covered here.



+++++++++++++++++++++++++++++
Mo Pics HOW TO
+++++++++++++++++++++++++++++

First, on your local computer, name your images. For this example I am using the following:

Main Thumbnail : exmain.gif

Big Image for main thumbnail : exmain_big.gif

Name for 3 other pics that I want to appear on the product page:

exmain_pic1.gif
exmain_pic2.gif
exmain_pic3.gif

For this example, these extra pictures are full sized, not thumbs, although they have been optimized for small filesize.
++++++++++++++++++++++++++++++++++++++++

Next, follow these steps:

1. In osCommerce MS2-MAX admin create a product called Mopics Test Product. On the product creation page, in the Products Image field, type this path : thumbs/exmain.gif.

2. Click Preview and then click Update. The image should be broken (red x) in the admin.

3. Next, upload the images from your computer via FTP to the server:

exmain.gif /catalog/images/thumbs
exmain_big.gif /catalog/images/images_big
exmain_pic1.gif /catalog/images/thumbs
exmain_pic2.gif /catalog/images/thumbs
exmain_pic3.gif /catalog/images/thumbs

4. Go to the product page in the catalog, and see your nice images dynamically picked up by the product.


That is all there is to it. You can change the image types if you like. What I do is make all my thumbs .gif files, and then make by big images .jpg files. I set the dynamic mopics settings in the admin to reflect this.

Then, I create my thumbs - exmain_pic1.gif and my big image exmain_pic1.jpg and I upload both to the /catalog/images/thumbs dir. This allows me to have a full sized big pic, and fast loading thumbs.

dreamscape
03-14-2004, 09:22 AM
1. How can I use a thumb and big image for the supporting images? As I see it, the naming convention does not allow for thumbs AND big images for the supporting images. If this is incorrect, please provide some more instructions. I tried this, but it does not work:
image1_pic1.jpg (supporting thumb)
image1_big1.jpg (supporting big)
Ok I am the author of Dynamic MoPics, so I should say something here. I have included the option for a _big extension because I had a few people request it for their main big image, because they stored BOTH their main thumbnail and main big image in the root of the "images/" folder (why, I don't know). But a few people requested it, so I put it in.

I would highly recommend NOT using the big image extension (there is no reason I see to store both the main thumbnail and main big image in the root images folder. Ideally all thumbnails should be in the thumbs folder and all big images in the images_big folder). Otherwise you'll just confuse the hell out of yourself (as has seemed to have happened) ;)

You can setup supporting thumbnails and their big images like this:
images/thumbs/image1_pic1.jpg
images/images_big/image1_pic1.jpg
images/thumbs/image1_pic2.jpg
images/images_big/image1_pic2.jpg
etc

Of coarse where thumbs and images_big are your defined thumbnail and big image folders.



2. Is there a way to ignore the Small Image Width and Height pixel values and just let the images be their original size? If I have a thumb and a big image, what's the point of resizing them in the IMG tag? I have many images that are not the same proportion (some landscape, some portrait) and these values are distorting my images. Any suggestions?
Go into the regular image configuration and set the small image width and height to blank (just delete the number and submit a blank input).

gheffron
03-15-2004, 12:26 AM
Okay, so it looks as if it's working fine, except that it's trimming off the beginnings of long file names.

images/thumbs/eurobump-rabbit-thum-bg.jpg is getting shortened into images/thumbs/p-rabbit-thum-bg.jpg

And wait a minute, why is it looking for the big image in the /thumbs directory? I have it set to have the "main image" in the thumbs directory (main means initial image, right?), which means the big image should be in the /images_big directory. Or am I entirely screwed up?

gheffron
03-15-2004, 12:27 AM
Hey, and thanks a bunch for the instructions! That's exactly what I was hoping for.

gheffron
03-15-2004, 04:25 PM
This is definitely weird. The path to images/cabbiegril.jpg was translated (via MoPics) to images/thumbs/ril.jpg

Is it a bug? Am I doing something wrong? Is there some setting that limits the length of the paths?

dreamscape
03-16-2004, 07:21 AM
This is definitely weird. The path to images/cabbiegril.jpg was translated (via MoPics) to images/thumbs/ril.jpg

Is it a bug? Am I doing something wrong? Is there some setting that limits the length of the paths?

Is this your main thumbnail/image? If so, then you need to set "main image in thumbnail dir" to false, because you have oscommerce looking for it in images/ "cabbiegril.jpg". You have it set to true, and to be so the way osCommerce works, in the database or admin you would have to enter the image as "thumbs/cabbiegril.jpg" and then it would trim the length of your thumbs dir off, leaving "cabbiegril.jpg" as the actual image name.

The way you are doing it now, you are just putting in "cabbiegril.jpg" and have told it that it is "thumbs/cabbiegril.jpg" (main thumb in thumnail dir = true tells it this). So when it trims it to get the actual filename, all it gets is "ril.jpg". So you need to either set main thumb in thumbnail dir to false or input your image in the admin as "thumbs/cabbiegril.jpg"