15 replies [Last post]
bwv
bwv's picture
Offline
Uber DonorBug FinderEarly adopter... addicted to alphas.Spreading the word - Ubercart for president.
Joined: 08/07/2007
Juice: 417
Was this information Helpful?

Hello. I was browsing for help with the problem I am having and came upon this thread:

http://www.ubercart.org/issue/6022/image_thumbnail_my_cart_page

I added a post to it but could not find it listed in the forums, so I am (and please forgive me if I have violated a posting rule) reposting it as a forum topic.

Essentially, if you add an item to the cart, then go to the /cart page, the small images do not show. I have deleted and rebuilt a preset called "cart" but to no avail.

I am starting to think it might be best to remove that field from the cart display entirely. That way only four fields will display (Remove, Products (name/link only), Qty. and Total.

Any assistance would be greatly appreciated. thanks

steve's picture
Offline
Joined: 10/26/2007
Juice: 19
Re: Removing/fixing image display on /cart

If you want to remove it you can do it by css:

.imagecache-cart {display:none;}

Steve.

ron_s's picture
Offline
Joined: 09/11/2008
Juice: 173
Re: Re: Removing/fixing image display on /cart

I have provided a solution. It is available here:
http://www.ubercart.org/issue/6022/image_thumbnail_my_cart_page#comment-...

The same problem also exists in the uc_category module. Please see the same thread for my most recent response.

Ron

j0rd's picture
Offline
Getting busy with the Ubercode.
Joined: 07/16/2008
Juice: 453
Re: Removing/fixing image display on /cart

The css solution is probably the easiest. In Drupal 5 / Ubercart 1 I believe you can remove it with "Configure Tables" aka. Tapir Settings.

In Drupal 6 / Ubercart 2, since the Tapir UI has been removed, I'm using my custom module to edit the cart form including removing the cart image. Here's the snipppet.

function castawayceramics_form_alter(&$form, &$form_state, $form_id) {
   switch($form_id) {
      case 'uc_cart_view_table':
         $form['table']['#value']['columns']['image']['access'] = FALSE;
         break;
   }
}
ron_s's picture
Offline
Joined: 09/11/2008
Juice: 173
j0rd wrote:The css solution
j0rd wrote:

The css solution is probably the easiest.

But this completely assumes someone is looking to get rid of the cart images. The original post was looking for a solution, and if there's no solution, then how to hide it.

Obviously using CSS to hide it is the right approach, but why not try to fix the original problem as I'm suggesting above?

j0rd's picture
Offline
Getting busy with the Ubercode.
Joined: 07/16/2008
Juice: 453
Re: j0rd wrote:The css solution

I thought he was just looking to remove the image. I glanced at the links you guys have provided and can not attest to the problem as I've never encountered it myself.

I have on the other hand installed ubercart where the imagecache presets are not installed or not configured. Usually this had to do with enabling all my modules at once and ubercart getting installed before imagecache is. Drupal 5 has this error with imagecache and imageapi too. I always make sure now, I install imageapi stuff first, then imagecache then ubercart. This avoids this issue. If they didn't get setup properly ubercart would have issues displaying images. Perhaps this is what you guys are encountering, although judging by the OP, he seems to have tried to re-fix his presets. Other issue has to do with server permissions. Make sure you're webserver can write to all sub-directories under "files".

Other than that, I can only offer you one more tip to assist you in your debugging. Use dpm instead of print_r...it's much better for debugging. You will have to install the 'devel' module to get it.

ron_s wrote:
j0rd wrote:

The css solution is probably the easiest.

But this completely assumes someone is looking to get rid of the cart images. The original post was looking for a solution, and if there's no solution, then how to hide it.

Obviously using CSS to hide it is the right approach, but why not try to fix the original problem as I'm suggesting above?

bwv
bwv's picture
Offline
Uber DonorBug FinderEarly adopter... addicted to alphas.Spreading the word - Ubercart for president.
Joined: 08/07/2007
Juice: 417
Re: Re: Removing/fixing image display on /cart

I tried the solution posted by ron_s but it did not work on my site (thank you for your help ron_s, nonetheless). The TAPIR settings worked perfectly and I was able to remove the column, thank you for the tip. Ultimately, I'd like to be able to display the image in the cart table, but it is certainly not critical. Regards, david

bwv
bwv's picture
Offline
Uber DonorBug FinderEarly adopter... addicted to alphas.Spreading the word - Ubercart for president.
Joined: 08/07/2007
Juice: 417
j0rd: I have upgraded my

j0rd:

I have upgraded my site to 6.10, and need to revisit the image issue. Can you please explain what I need to do to remove the image? You are using a custom module; I assume that is what i need to do as well. Do I merely copy and paste your snippet (customized with my site name) into a module file? Thanks, david

bwv
bwv's picture
Offline
Uber DonorBug FinderEarly adopter... addicted to alphas.Spreading the word - Ubercart for president.
Joined: 08/07/2007
Juice: 417
Re: j0rd: I have upgraded my

I wonder if some kind soul would help me figure out how to use the code that j0rd provided to help me remove the image field on the cart display. See the image field thingy beneath the heading "products." That is what I would like to remove. Thank you!

AttachmentSize
cart.jpeg 41.85 KB
nonamer's picture
Offline
Joined: 12/28/2008
Juice: 4
modul

hey guys,
im trying to actually remove the whole picture from the cart (my site is in hebrew and the picture is hiding the product name and info)
i am a total noob and dont know anything about coding etc...

using uc 2
drupal 5

could you guys help me out with removing the picture completly ?

thanks.

bwv
bwv's picture
Offline
Uber DonorBug FinderEarly adopter... addicted to alphas.Spreading the word - Ubercart for president.
Joined: 08/07/2007
Juice: 417
Re: modul

To remove the picture go here:

admin/store/settings/tables/uc_cart_view_table

and uncheck the first products field.

Also, please check to make sure you are using the correct drupal/UC combination. Sounds like you may not be.

http://classicvinyl.biz
http://music.bwv810.com

nonamer's picture
Offline
Joined: 12/28/2008
Juice: 4
Re: Re: modul

you guys are right, i thoght i was using UC2 (i tryed drupal 6.8 befor downgrading) im actually using UC 1.6.

and thanks a lot guys.
now its working great.

Alaska's picture
Offline
Joined: 10/16/2007
Juice: 1433
Versions

Sounds like you are mixing versions. As best I can tell, Uber 1.x goes with Drupal 5.x. Uber 2.x goes with Drupal 6.x. Not at all sure how well Uber 2 will run with Drupal 5! You may want to check the forum for additional information.

In my case running the latest Drupal at 5.14 and Uber 1.6.

Others can chime in and let you know if this is correct.

fletch11's picture
Offline
Joined: 10/17/2009
Juice: 4
try this

It's been a while, but in case someone is looking for a solution to removing image columns:

http://www.ubercart.org/docs/developer/7512/tapir_tables_api#altering

minneapolisdan's picture
Offline
Joined: 05/21/2009
Juice: 67
Re: try this

Thanks, this solved the problem for me, removing the images from the cart. I just added that to my custom module.

shotokai's picture
Offline
Joined: 12/02/2010
Juice: 17
Re: try this

I understand that adding that code into the uc_cart.module will remove the image, and it worked for me, but where is the right place to add the code so as not to be messing with core ubercart files?