Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

[Contribution] UltraPics v1.0 - Addition Image Pac


Guest

Recommended Posts

I spent a week to figuring out what's wrong in my case.

I realised that this contrib is incompatible with Master Prod contribution.

And no one wrote a reply to my post so I gave up.

 

That's pretty stupid right there.

Do you really think someone is going to download your files to check the entire code for faults?

My own admin-categories.php file has 2300 lines of code! No way I'm gonna check your file!

I have this contrib working with Master Products (which actually was quite easy using KDiff) so it is compatible. (I think everything is, if you take the time and have some knowledge)

I believe there were some lines that had to be added twice for UltraPics (something with "case 'new_product_preview'" and "case 'new_master_preview'")

 

I copy and paste a lot too, and just doing that I can't help but getting some idea of what the code does.

 

Just compare: 1. the original file, 2. the file you want to add and 3. the file you want to add to with a comparison tool (I like to use KDiff)

Relax, take the time, save the stuff you Know you did right, and play around with the rest.

You can figure it out.

Like Eek said... It never hurts to help!
----------------------------------------

Link to comment
Share on other sites

  • 2 weeks later...
  • Replies 375
  • Created
  • Last Reply

Top Posters In This Topic

already found problem............... :D

 

 

nevermind... solved the problem

 

 

It would be nice to post the solution to your problems, just in case someone runs into the same problem!

Don't you think it's fair that when you're asking for help, to provide some help yourself when you can?

 

(Don't mean to be naggin' all the time ;) )

Like Eek said... It never hurts to help!
----------------------------------------

Link to comment
Share on other sites

Win 2000 and ultrapics help!!! Anyone got any ideas on why the little image buttons in the edit window (ed_image.gif) would display in internet explorer on win XP but not on Windows 2000? Why, in short, the whole edit window is more like it is in mozilla than in IE? If anyone out there is using win2K, pls shout

Link to comment
Share on other sites

  • 2 weeks later...

I'm getting the red x's in Preview; does anyone have a fix for this? Each image is previewed OK, but underneath the three previews there is an 'extra' set of three 'red x' images.

 

Saw two posts in here with the same prob but no solutions posted: did you folks find a fix?

 

cheers all

Bill

Link to comment
Share on other sites

I'm getting the red x's in Preview; does anyone have a fix for this? Each image is previewed OK, but underneath the three previews there is an 'extra' set of three 'red x' images.

 

Saw two posts in here with the same prob but no solutions posted: did you folks find a fix?

 

cheers all

Bill

 

 

 

 

I'm with you...after making the file modifications, I am having the following problems with UltraPics.

1 A lot of “x images” in the preview area.

2 I get this message after I update:

Warning: Cannot modify header information - headers already sent by (output started at //store/catalog/admin/includes/languages/english/categories.php:99)

in /store/catalog/admin/includes/functions/general.php on line 22

 

does this mean there’s a problem with my header.php or general.php file?

 

This is my general.php line 22:header('Location: ' . $url);

 

Thanks in advance for anyone’s help on this!

 

Ron

"Outside of a dog, a book is man's best friend.

Inside of a dog, it's too dark to read."

 

GROUCHO (1895-1977)

Link to comment
Share on other sites

Sussed it. The code just assumes that there will be 6 imgs and tries to echo out tags. My fix:

Find the six lines like this, there's one per img:

 

<?php echo tep_image(DIR_WS_CATALOG_IMAGES . $products_image_sm_1_name, $pInfo->products_name, SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT, 'align="center" hspace="5" vspace="5"'); ?>

 

I modded mine to do a quick check to see if an img name was found, and only write out a tag if so. Moved the line break so there is always a break no matter how many imgs are there.

 

Replace the block of 6 lines with this (back up first! you know the score...):

 

<?php

 

if ($products_image_sm_1_name!="") { echo tep_image(DIR_WS_CATALOG_IMAGES . $products_image_sm_1_name, $pInfo->products_name, SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT, 'align="center" hspace="5" vspace="5"'); }

if ($products_image_sm_2_name!="") { echo tep_image(DIR_WS_CATALOG_IMAGES . $products_image_sm_2_name, $pInfo->products_name, SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT, 'align="center" hspace="5" vspace="5"'); }

if ($products_image_sm_3_name!="") { echo tep_image(DIR_WS_CATALOG_IMAGES . $products_image_sm_3_name, $pInfo->products_name, SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT, 'align="center" hspace="5" vspace="5"'); }

echo '<br>';

if ($products_image_sm_4_name!="") { echo tep_image(DIR_WS_CATALOG_IMAGES . $products_image_sm_4_name, $pInfo->products_name, SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT, 'align="center" hspace="5" vspace="5"'); }

if ($products_image_sm_5_name!="") { echo tep_image(DIR_WS_CATALOG_IMAGES . $products_image_sm_5_name, $pInfo->products_name, SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT, 'align="center" hspace="5" vspace="5"'); }

if ($products_image_sm_6_name!="") { echo tep_image(DIR_WS_CATALOG_IMAGES . $products_image_sm_6_name, $pInfo->products_name, SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT, 'align="center" hspace="5" vspace="5"'); }

echo '<br>';

 

?>

 

P'raps there's a better way but I haven't got time at the mo,

HTH

cheers

Bill

Link to comment
Share on other sites

Win 2000 and ultrapics help!!! Anyone got any ideas on why the little image buttons in the edit window (ed_image.gif) would display in internet explorer on win XP but not on Windows 2000? Why, in short, the whole edit window is more like it is in mozilla than in IE? If anyone out there is using win2K, pls shout

I'm on WIN2K and using both Mozilla and IE with non of the above problems...I am still getting an error message on another issue...

"Outside of a dog, a book is man's best friend.

Inside of a dog, it's too dark to read."

 

GROUCHO (1895-1977)

Link to comment
Share on other sites

Hi all, I have this problem after install Ultrapics

 

wen i clik on image i receive this error: :( help me please

 

Fatal error: Cannot redeclare tep_show_category() (previously declared in D:\Programmi\Apache Group\Apache2\htdocs\www\my_space\osc2\includes\header.php:178) in D:\Programmi\Apache Group\Apache2\htdocs\www\my_space\osc2\includes\boxes\categories.php on line 59

 

details of server

Windows NT STAR 5.0 build 2195 - PHP Version 5.1.2 - MySQL 4.1.18-nt

 

any idea??

Link to comment
Share on other sites

  • 1 month later...

Have just installed this contrib without any problems. In the installation file it says:

 

* (To POPUP! or NOT TO POPUP!) Have Pop up Windows or NOT!

 

I don't want have pop-ups. How do I turn them off? If this is very obvious I apoligise but have looked several time but no joy.

 

Thanks,

 

Lyle

Link to comment
Share on other sites

Hi,

 

This is a great installation and appears to work fine on my testing so far.

 

I am wondering if we have to select each of the images as Small, Popup and XL or whether there is a way to batch upload them.

 

Having over a 1000 products means there are a lot of images, and to browse and link to each image will obviously take a long time, and i'm guessing there will be a short-cut to upload them

 

Look forward to hearing your advice

 

Thanks

Link to comment
Share on other sites

  • 2 weeks later...
Anyone know how to remove pop-ups in this contrib?

 

I have found a solution for removing the pop-ups.

 

In product_info.php around line 124 I changed this:

 

<script language="javascript"><!--
  document.write('<?php echo '<a href="java script:popupWindow(\\\'' . tep_href_link(FILENAME_POPUP_IMAGE, 'pID=' . $product_info['products_id'] . 'ℑ=0') . '\\\')">' . tep_image(DIR_WS_IMAGES . $new_image, addslashes($product_info['products_name']), $image_width, $image_height, 'hspace="5" vspace="5"') . '<br>' . tep_image_button('image_enlarge.gif', TEXT_CLICK_TO_ENLARGE) . '</a>'; ?>');
//--></script>
<noscript>
  <?php echo '<a href="' . tep_href_link(DIR_WS_IMAGES . $product_info['products_image_med']) . '">' . tep_image(DIR_WS_IMAGES . $new_image . 'ℑ=0', addslashes($product_info['products_name']), $image_width, $image_height, 'hspace="5" vspace="5"') . '<br>' . tep_image_button('image_enlarge.gif', TEXT_CLICK_TO_ENLARGE) . '</a>'; ?>
</noscript>

 

to this:

 

<script language="javascript"><!--
  document.write('<?php echo tep_image(DIR_WS_IMAGES . $new_image, addslashes($product_info['products_name']), $image_width, $image_height, 'hspace="5" vspace="5"') . '</a>'; ?>');
//--></script>
<noscript>
  <?php echo tep_image(DIR_WS_IMAGES . $new_image, addslashes($product_info['products_name']), $image_width, $image_height, 'hspace="5" vspace="5"') . '</a>'; ?>
</noscript>

Link to comment
Share on other sites

I have found a solution for removing the pop-ups.

 

In product_info.php around line 124 I changed this:

 

<script language="javascript"><!--
  document.write('<?php echo '<a href="java script:popupWindow(\\\'' . tep_href_link(FILENAME_POPUP_IMAGE, 'pID=' . $product_info['products_id'] . 'ℑ=0') . '\\\')">' . tep_image(DIR_WS_IMAGES . $new_image, addslashes($product_info['products_name']), $image_width, $image_height, 'hspace="5" vspace="5"') . '<br>' . tep_image_button('image_enlarge.gif', TEXT_CLICK_TO_ENLARGE) . '</a>'; ?>');
//--></script>
<noscript>
  <?php echo '<a href="' . tep_href_link(DIR_WS_IMAGES . $product_info['products_image_med']) . '">' . tep_image(DIR_WS_IMAGES . $new_image . 'ℑ=0', addslashes($product_info['products_name']), $image_width, $image_height, 'hspace="5" vspace="5"') . '<br>' . tep_image_button('image_enlarge.gif', TEXT_CLICK_TO_ENLARGE) . '</a>'; ?>
</noscript>

 

to this:

 

<script language="javascript"><!--
  document.write('<?php echo tep_image(DIR_WS_IMAGES . $new_image, addslashes($product_info['products_name']), $image_width, $image_height, 'hspace="5" vspace="5"') . '</a>'; ?>');
//--></script>
<noscript>
  <?php echo tep_image(DIR_WS_IMAGES . $new_image, addslashes($product_info['products_name']), $image_width, $image_height, 'hspace="5" vspace="5"') . '</a>'; ?>
</noscript>

 

It should be

<script

not

<script

 

Also if you copy and paste this text and it doesn't work, delete the spaces before

	  document.write

and before the <?php echo in:

<noscript>
  <?php echo

as it adds some invisible characters which cause problems.

Link to comment
Share on other sites

  • 2 weeks later...

Hi all,

I was implementing this contribution but at halfway I realized it may be not what I was looking for.

Instead of having different images in my product info page I'd like to have only one but changing by selecting the relative attribute(by colour for example).

I couldn't find anything appropriate on the forum (that, by the way, is quite difficult to have a decent search result).

The result I am aiming is something like this website, where I spent all afternoon, not trying to understand the code (I don't know nothing about JS), but because of the content :-)

 

http://www.glamoutlet.com/Outlet/servlet/c...lorValueID=0002

 

If you already came across a contribution that can give this solution or have alternative solutions, please let me know.

 

Thanks,

Roberto

Link to comment
Share on other sites

  • 1 month later...

My images are not showing in preview in the admin side. All I get in it's place is the name of the image. I have checked over the install several times and it all looks ok. I think this might be a setting issue. Other then that everything works spotless. So does anyone know how to get the images to show in preview on the admin side?

 

-Thanks

Search the forum and contributions before posting. If that doesn't work, keep looking, then post. The forum is for seeking help and advice NOT for someone to do your work for you. Try to do something on your on, if you are going to run a shop then learn how it works.

Link to comment
Share on other sites

  • 4 weeks later...
  • 2 months later...

Hi

 

Installed this contribution on 2.2MS2 051113 and it works great.

 

I use some large images about 200k in size and when using admin/catalog/ to install products and images, the large images disrupt the layout of the page especially when you preview prior to update. Is it possible to just display the images as thumbnails for the purpose of entering them? It becomes a bit tedious having to scroll around all the time just because it displays the large images.

 

All help greatly appreciated.

 

Best Regards

Peter

Link to comment
Share on other sites

Hello, I just installed this contrib and I can't seem to find it anywhere in my admin. has anyone come across this problem? I don't know if I am missing something in the install. I followed the directions and went through it twice to make sure but get the same result. Thanks for any help

David

Link to comment
Share on other sites

Hi

 

Installed this contribution on 2.2MS2 051113 and it works great.

 

I use some large images about 200k in size and when using admin/catalog/ to install products and images, the large images disrupt the layout of the page especially when you preview prior to update. Is it possible to just display the images as thumbnails for the purpose of entering them? It becomes a bit tedious having to scroll around all the time just because it displays the large images.

 

All help greatly appreciated.

 

Best Regards

Peter

 

After many, many hours of investigation and head scratching I have found the problem. In admin/configuration/images I had "Small Image Width" set to "125" and "Small Image Height" left at "0" with "Calculate Image Size" set to "true" for automatic calculation of the aspect ratio. This causes all images in admin/catalog/categories/products to be displayed as full size even though the code parameters use "SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT". The solution is simple. Set "Small Image Height" to a value, say "100" and everything works perfectly!!

 

This also solves the same problem I had in the X-sell contribution.

 

I'm sure there probably is a better fix in the code so that you can leave "Small Image Height" at "0" for auto calculation of the aspect ratio but for the moment I can live with the simple solution.

 

If anyone has a better solution then I will be only too glad to hear about it!!

 

Happy Days!!!!

 

Peter

Link to comment
Share on other sites

After many, many hours of investigation and head scratching I have found the problem. In admin/configuration/images I had "Small Image Width" set to "125" and "Small Image Height" left at "0" with "Calculate Image Size" set to "true" for automatic calculation of the aspect ratio. This causes all images in admin/catalog/categories/products to be displayed as full size even though the code parameters use "SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT". The solution is simple. Set "Small Image Height" to a value, say "100" and everything works perfectly!!

 

This also solves the same problem I had in the X-sell contribution.

 

I'm sure there probably is a better fix in the code so that you can leave "Small Image Height" at "0" for auto calculation of the aspect ratio but for the moment I can live with the simple solution.

 

If anyone has a better solution then I will be only too glad to hear about it!!

 

Happy Days!!!!

 

Peter

 

I have realised that this solution is no good because all my images on the website now have distorted aspect ratios!! Doooh!! Maybe that's why I set it up without image heights in the first place!!!

 

Anyone got a better idea??

 

Not so happy days!

Peter

Link to comment
Share on other sites

Hello,

I am getting the following error,

 

1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ' p.products_image_med, p.products_image_lrg, p.products_image_sm_1, p.products_i' at line 1

 

Happens as soon as I add the following line,

, p.products_image_med, p.products_image_lrg, p.products_image_sm_1, p.products_image_xl_1, p.products_image_sm_2, p.products_image_xl_2, p.products_image_sm_3, p.products_image_xl_3, p.products_image_sm_4, p.products_image_xl_4, p.products_image_sm_5, p.products_image_xl_5, p.products_image_sm_6, p.products_image_xl_6

 

To get get final

$product_query = tep_db_query("select pd.products_name, pd.products_description, pd.products_url, p.products_id, p.products_quantity, p.products_model, p.products_image, p.products_image_med, p.products_image_lrg, p.products_image_sm_1, p.products_image_xl_1, p.products_image_sm_2, p.products_image_xl_2, p.products_image_sm_3, p.products_image_xl_3, p.products_image_sm_4, p.products_image_xl_4, p.products_image_sm_5, p.products_image_xl_5, p.products_image_sm_6, p.products_image_xl_6, p.products_price, p.products_weight, p.products_date_added, p.products_last_modified, date_format(p.products_date_available, '%Y-%m-%d') as products_date_available, p.products_status, p.products_tax_class_id, p.manufacturers_id from " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd where p.products_id = '" . (int)$HTTP_GET_VARS['pID'] . "' and p.products_id = pd.products_id and pd.language_id = '" . (int)$languages_id . "'");

 

Thanks JR

Link to comment
Share on other sites

Hello,

I just installed Ultra pics and everything seems to work fine, just one question on the admin page. After adding images, and before updating, I see broken images. These broken images are correct in the sense that I have not uploaded all six images, just four. But, was wondering if the broken image look is correct, or is there away so when images are not uploaded, that the broken image link may not show?

 

 

 

admin.jpg

 

Thanks JR

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...