Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

surfalot

[Contribution] More_pics_6 v1.1 For osC 2.2 MS2

Recommended Posts

Eek, I'm not getting any pictures showing up in my store! I've used a file comparison program to merge the contribs files with my non-virgin ones. Currently running Ultimate SEO URLs, a meta-data contribution, and Image magic, too.

Share this post


Link to post
Share on other sites

There are 4 blocks of More Pics code in products_info.php. Search for "BOF: More Pics 6" in the package file and make sure each has been inserted correctly.

Share this post


Link to post
Share on other sites
There are 4 blocks of More Pics code in products_info.php. Search for "BOF: More Pics 6" in the package file and make sure each has been inserted correctly.

 

I had mis-merged one. Thank you for for stating the obvious for me :P Sorry to bug you! Thanks!

Share this post


Link to post
Share on other sites

Hi all ,installed 1.1b, works great.

 

the only problem is that the additional images section is also showing the main image as part of the thumbnails.. any idea how to get rid?

Share this post


Link to post
Share on other sites

firstly this contrib is great! it works fine, or seems to...

 

Anyway I have 2 questions, the 1st is regarding the code in catalog\admin\includes\functions\general.php at approx. line 882 (on mine anyway) I think I noticed a bug, I amended the code and it seems to work, but I would appreciate surfalot if you could confirm what I did...

 

the code previously was (this is a chopped version, only showing the lines necessary to explain)

 

if ($duplicate_subimage1['total'] < 2) {

if (file_exists(DIR_FS_CATALOG_IMAGES . $product_subimage1['products_subimage1'])) {

@unlink(DIR_FS_CATALOG_IMAGES . $product_subimage1['products_subimage1']);

}

}

 

 

if ($duplicate_subimage2['total'] < 2) {

if (file_exists(DIR_FS_CATALOG_IMAGES . $product_subimage2['products_subimage2'])) {

@unlink(DIR_FS_CATALOG_IMAGES . $product_subimage2['products_subimage2']);

}

}

 

 

if ($duplicate_subimage3['total'] < 3) {

if (file_exists(DIR_FS_CATALOG_IMAGES . $product_subimage3['products_subimage3'])) {

@unlink(DIR_FS_CATALOG_IMAGES . $product_subimage3['products_subimage3']);

}

}

 

if ($duplicate_subimage4['total'] < 5) {

if (file_exists(DIR_FS_CATALOG_IMAGES . $product_subimage4['products_subimage4'])) {

@unlink(DIR_FS_CATALOG_IMAGES . $product_subimage4['products_subimage4']);

}

}

 

 

if ($duplicate_subimage5['total'] < 5) {

if (file_exists(DIR_FS_CATALOG_IMAGES . $product_subimage5['products_subimage5'])) {

@unlink(DIR_FS_CATALOG_IMAGES . $product_subimage5['products_subimage5']);

}

}

 

 

if ($duplicate_subimage6['total'] < 6) {

if (file_exists(DIR_FS_CATALOG_IMAGES . $product_subimage6['products_subimage6'])) {

@unlink(DIR_FS_CATALOG_IMAGES . $product_subimage6['products_subimage6']);

}

}

 

 

I believe this code is checking for duplicate images?, so I would expect the code on all the subimages to say '($duplicate_subimageX'total'] < 2)', however they seem incorrect, am I right to amend all these to say < 2 ???,, I have anyway, and as said, it seems to work okay...

 

 

2nd question is....

 

Is it possible to have the images in product setup to adhere to the image restrictions?, as the images I am using are 800px wide for each of the images I upload, this throws the product admin page into huge proportions, any assistance with that would be greatly appreciated, I have looked at the code to try to find where to add in SMALL_IMAGE_WIDTH, and SMALL_IMAGE_HEIGHT, but I have not managed to see it as yet, probably because I am looking in the wrong places.

 

 

thanks in advance..

 

regards

John.

 

regardless, like I said, this is a great contrib as it stands, something I feel should have been part of oscommerce from the start, 1 image is just not enough, when all you have are images to display a product, the more the better...

Share this post


Link to post
Share on other sites
the only problem is that the additional images section is also showing the main image as part of the thumbnails.. any idea how to get rid?

The design was to replace the original image location with the image group. I'm guessing you didn't comment out the original image code as suggested by the contrib. You can eliminate the original image from the More Pics group by removing this line:

if (tep_not_null($product_info['products_image'])) { $mopics_images[] = $product_info['products_image']; }

Or comment out the original image code, and maintain the group only.

Share this post


Link to post
Share on other sites
Hi,

 

Does anyone have this working with the sts_templates?

 

 

Hello

 

Did you ever get this working with STS templates ?

 

I've found that most things DON't work with it - unfortunately ...

 

I'm currantly trying to get file_upload contrib to work with it - to no avail !

 

DOnna

 

=============

 

DBK Web Development

Share this post


Link to post
Share on other sites
I believe this code is checking for duplicate images?, so I would expect the code on all the subimages to say '($duplicate_subimageX'total'] < 2)', however they seem incorrect, am I right to amend all these to say < 2 ???,, I have anyway, and as said, it seems to work okay...

Yup, that's a bug. each of those should be "< 2".

 

2nd question is....

Is it possible to have the images in product setup to adhere to the image restrictions?

They should already. If you are talking about when they are displayed on the right-sidebar of the categories.php file while the product is highlighted, they should be restricted. the code is on lines 1248-1255 of the categories.php file in the More Pics 6 1.1b contrib package.

Share this post


Link to post
Share on other sites
Did you ever get this working with STS templates ?

I haven't, sorry.

Share this post


Link to post
Share on other sites
Yup, that's a bug. each of those should be "< 2".

 

They should already. If you are talking about when they are displayed on the right-sidebar of the categories.php file while the product is highlighted, they should be restricted. the code is on lines 1248-1255 of the categories.php file in the More Pics 6 1.1b contrib package.

 

Yeah I see the code, however, to stop major image distortion on the thumbs I have left the Height blank within the setup of the store config, this displays the thumbs with 'as said' les distortion, probably due to keeping aspect ratio, if I put a number in there, the same as the width, say 100 and 100, it does work, blast!!!, but you end up with the images looking like square / retangular distored images naffff...

 

can you think of a fix for this Surfalot ?, is their some image resizing contrib I can use where it helps with this issue??

 

btw.. cheers for the quick reply, I appreciate it...

Edited by sidewinder

Share this post


Link to post
Share on other sites

Thanks very much.. i installed the contrib in OSCmax and had to do a lot of shuffling, so i probably missed a couple of bits.

 

The design was to replace the original image location with the image group. I'm guessing you didn't comment out the original image code as suggested by the contrib. You can eliminate the original image from the More Pics group by removing this line:
if (tep_not_null($product_info['products_image'])) { $mopics_images[] = $product_info['products_image']; }

Or comment out the original image code, and maintain the group only.

Share this post


Link to post
Share on other sites
The design was to replace the original image location with the image group. I'm guessing you didn't comment out the original image code as suggested by the contrib. You can eliminate the original image from the More Pics group by removing this line:
if (tep_not_null($product_info['products_image'])) { $mopics_images[] = $product_info['products_image']; }

Or comment out the original image code, and maintain the group only.

 

Hi surfalot...

 

that worked fine.. the original product_image dissapears.. but now the popup is one behind.. ie on the product page click on sub_image_3 and sub_image2 pops up?

Share this post


Link to post
Share on other sites

in product_info.php, search for

'&invis='.$mo_item

replace with

'&invis='.($mo_item+1)

Share this post


Link to post
Share on other sites

New version v1.2 uploaded with a few frequently asked for features.

Share this post


Link to post
Share on other sites
Guest

Hello,

 

I've had this great contribution up and running for awhile now, and have been impressed. It works great, and is invaluable. Now, I'm trying to find a way to add image magic contribution, and more pics (I believe) is over writing the image resize command of image magic. Thus, my pics are still being passed as full size, then squashed by browser defeating the purpose of image magic. Has anyone here installed both contributions and gotten them to work together - and if so what code changes were made? Any help would be great, and much appreciated.

 

NS

Share this post


Link to post
Share on other sites

yes, bodleytunes has done it. there seems to be only one issue and that was with the arrow buttons in the popup. I haven't tried Image Magic yet so I haven't looked at what the problem is. the info is on page 4 of this thread.

Share this post


Link to post
Share on other sites

Well, I added the sub image to the product table okay, but I am confused as what to do in the second section,

"insert into config_group"

Are these new lines in thos tables?

If so would someone paste an example for me?

Thanks,

Dave

Share this post


Link to post
Share on other sites

sounds like you are trying to do the SQL additions manually. That file

is SQL code. Hopefully your host has phpMyAdmin installed for you or

some other SQL tool you can run it in. Talk to your host. If not, it's

going to be hard to use many of the contrib available here.

 

You can setup the database automatically by starting phpMyAdmin.

Select your osC database (if you have more then 1 database).

Click the little SQL image in the upper left.

Copy all the text from the database_additions.txt file into the Run SQL query window, click go.

 

At this point, just copy the sections you haven't already done.

Share this post


Link to post
Share on other sites
in product_info.php, search for
'&invis='.$mo_item

replace with

'&invis='.($mo_item+1)

 

Thanks surf.. worked a treat.. i knew it was something like that but couldnt get it quite right.

Share this post


Link to post
Share on other sites
sounds like you are trying to do the SQL additions manually. That file

is SQL code. Hopefully your host has phpMyAdmin installed for you or

some other SQL tool you can run it in. Talk to your host. If not, it's

going to be hard to use many of the contrib available here.

 

You can setup the database automatically by starting phpMyAdmin.

Select your osC database (if you have more then 1 database).

Click the little SQL image in the upper left.

Copy all the text from the database_additions.txt file into the Run SQL query window, click go.

 

At this point, just copy the sections you haven't already done.

 

 

Sucess!

Thanks Surf, I don't know alot about sql, but I am learning>

Now all I have to do is to copy the php pages to their proper locations.

Thamnks,

Dave

Share this post


Link to post
Share on other sites

Hallo all,

 

I have add the script more pics 6 v1.2 but I get this erro can somebody help me please,

 

Fatal error: Cannot redeclare tep_show_category() (previously declared in /home/yousefy/domains/itweb.nl/public_html/osc/includes/header.php:175) in /home/yousefy/domains/itweb.nl/public_html/osc/includes/boxes/categories.php on line 13

Share this post


Link to post
Share on other sites

looks like you have a function being redefined. Can't figure out how it happened from this install. this contrib does not touch any of the files mentioned.

 

recompare your original with the one in the package and make sure you didn't add this line

<?php require(DIR_WS_INCLUDES . 'header.php'); ?>

from the contrib package if your install didn't require it. Or maybe somehow duplicated the include. Remember, all areas that need to be merged into your code are marked with "BOF: More Pics 6" and "EOF: More Pics 6".

Share this post


Link to post
Share on other sites

Have just installed this and I am getting when trying to access the products attributs section in the admin

 

Fatal error: Call to undefined function: link_get_variable() in public_html/shop/catalog/admin/products_attributes.php on line 17

 

which is

 

// These variables are accessed directly rather than through $HTTP_GET_VARS or $_GET later in this script

link_get_variable('option_page');

link_get_variable('value_page');

link_get_variable('attribute_page');

// <<< END REGISTER_GLOBALS

 

I have globals turned off?? My server won't let them be turned on, so I have applied the globals patch??

 

 

Any help would be apprectiated.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×