You are here:  » Product name currency problem

Support Forum



Product name currency problem

Submitted by tbbd2007 on Sat, 2007-08-04 11:35 in

Having looked through the forum for the answer I can see that Price Tapestry strips out the '&' and ';' from '£'. The only problem with this is that some of the product names contain the currency symbol, i.e. 'International £10.00 calling card' is displayed as 'International pound10.00 calling card'. I did try searching and replacing the 'pound' with '£', but no no avail, presumably because the filter cannot find the specific 'pound' text. All of the products are different prices so I cannot easily do search and replace for every price. What can I do instead?

Kind regards

Stephen

Submitted by support on Sat, 2007-08-04 18:28

Hi Stephen,

It is quite easy to modify the import routine to allow & and ; which will permit HTML entities into the database. In includes/admin.php you will find the following code on line 163:

$record[$admin_importFeed["field_description"]] = tapestry_normalise($record[$admin_importFeed["field_description"]],",'\'\.%!");

...change this as follows:

$record[$admin_importFeed["field_description"]] = tapestry_normalise($record[$admin_importFeed["field_description"]],",'\'\.%!&;");

(the list of characters in the second parameter to tapestry_normalise() is a list of characters that you wish to allow in the description field).

Hope this helps!
Cheers,
David.

Submitted by clare on Tue, 2008-02-12 09:28

Hi,
My admin file is a little altered and although I thought this was the corresponding line

 database_safe(isset($record[$admin_importFeed["field_description"]])?$record[$admin_importFeed["field_description"]]:""),

and tried changing it to

 database_safe(isset($record[$admin_importFeed["field_description"]])?$record[$admin_importFeed["field_description"]]:",'\'\.%!&;"),

The nbsp is still showing in the descriptions. Just to recap as I am on new thread, in the datafeed they are using the encoding & amp ; nbsp ; (without the spaces) and in my site this is showing as just nbsp, when it should just be a space.

You can see on mysite.com/shopUK/c/clothing-and-accessories/category/Novelty-T-Shirts/

My site being findallsorts.

Submitted by support on Tue, 2008-02-12 09:32

Hi Clare,

Sorry - that's not quite the right place. Look slightly further up the function, where you will see the comment:

    /* apply standard filters */

You will see the line about 3 or 4 lines below that point...

Cheers,
David.

Submitted by clare on Tue, 2008-02-12 09:46

I hope you dont mind, I have sent my admin.php via email, as for some reason that section "apply standard filters" on my file, doesnt have the description part and I cant rememer what I changed in it. It still imports everything fine, other than this one problem.

Submitted by clickspace on Tue, 2008-02-12 18:03

Hi David,

I added the mods suggested further up this thread but still have problems as follows;

Example search result outputs:

7.0quot LCD --- should be, 7" LCD
clearnbsp9 inchnbspLCD --- should be, clear 9 inch LCD
Here39s where --- should be, Here's where
thesenbspyellow --- should be, these yellow
etc.

Finally, I am also getting things like this in the product titles:

22quot HD Ready --- should be, 22" HD Ready

I did try and change my config file from;

$config_charset = "utf-8";

To;

$config_charset = "iso-8859-1";

but it didn't seem to make any difference so I have changed it back.

I am importing all current feeds using CSV (comma) unzipped. Not sure if that makes any difference.

Any pointers much appreciated,
Steven

Submitted by support on Tue, 2008-02-12 18:06

Hi Steven,

Did you re-import after making the changes? The change is to the import routine so changes won't have any effect immediately?

Otherwise, feel free to email me your modified includes/admin.php and i'll check it over for you...

Cheers,
David.