forum.coppermine-gallery.net

Support => cpg1.4.x Support => Older/other versions => cpg1.4 plugins => Topic started by: Catman on January 29, 2007, 08:41:20 am

Title: Not possible to add a picture to the shopping cart if selected after a search
Post by: Catman on January 29, 2007, 08:41:20 am
Hello,

I'm using the photo_shop plugin for my gallery.  Everything seemed to work fine, but yesterday I discovered that when I start searching for a picture, it is not possible to add the found picture(s) to the cart. But it is possible to add the same picture to the cart when I access it through the album. I have done the same thing on a test server, with the same result. Then I went to http://stramm.st.funpic.org/ and tried to do the same. I searched with the keyword "sea" I found 1 picture, but again it was not possible to add the picture to the cart. Seems this is a bug because it is possible to reproduce it on several systems.

Regards

Frank
Title: Re: Not possible to add a picture to the shopping cart if selected after a searc
Post by: Stramm on January 29, 2007, 09:31:24 am
known issue, that's due to way the search system works.
Title: Re: Not possible to add a picture to the shopping cart if selected after a search
Post by: Catman on January 29, 2007, 12:26:11 pm
Thank's for youre reply;

Is there any workaround for this issue? Or is there any hope for the near future that this issue can be solved?

Kind regards

Frank
Title: Re: Not possible to add a picture to the shopping cart if selected after a searc
Post by: Stramm on January 29, 2007, 01:01:38 pm
no workaround
if this will be changed... hmm, I do not know. The plugin relies on the main app to handle over the pic_id. The search system however uses cookies to save the search result.

??? Quick fix possibly is to disable displaying the shop for the search meta album
Title: Re: Not possible to add a picture to the shopping cart if selected after a search
Post by: Catman on January 29, 2007, 04:38:04 pm
It's a pity, because searching, and then adding the found picture(s) to the cart was the main goal. The excellent search function in Coppermine made me start using it. Maybe someone else has a good idea?
Title: Re: Not possible to add a picture to the shopping cart if selected after a searc
Post by: Stramm on January 29, 2007, 05:35:21 pm
there's a possibility, but you'll lose your search meta album once you've added a pic to the basket

codebase.php
find
Code: [Select]
global $CONFIG, $SHOP_CONFIG, $lang_photoshop;replace with
Code: [Select]
global $CONFIG, $SHOP_CONFIG, $lang_photoshop, $album;
find
Code: [Select]
<form action="{$REFERER}" method="post">replace with
Code: [Select]
<form action="{$referer}" method="post">
above
Code: [Select]
$shop_data =  <<<EOTadd
Code: [Select]
($album == 'search') ? $referer = "displayimage.php?pos=-{$pic_data['pid']}" : $referer = null;
Title: Re: Not possible to add a picture to the shopping cart if selected after a search
Post by: Catman on January 29, 2007, 07:21:16 pm
 :D Thank you very much; this is working fine. It is very close to what I want.

Kind regards

Frank