You are here:  » Comma removed from product name


Comma removed from product name

Submitted by marco@flapper on Thu, 2011-03-24 12:54 in

Hi,
I have some products with a price in the product name.

Like "€12,50 product", but the comma seems to disappear while imported. So it displays like "€1250 product"

I checked the source xml and the comma is there.
What could be causing this?

Example url:
{link saved}

Submitted by support on Thu, 2011-03-24 14:33

Hi Marco,

I see what's happening - it's the "Price search results for ...." text, which uses the product name derived from $q rather then the non-normalised name. To correct this, in your products.php look for this code at line 65:

      $header["title"] = htmlentities($q,ENT_QUOTES,$config_charset);

...and REPLACE with:

      $header["title"] = htmlentities($q,ENT_QUOTES,$config_charset);
      $banner["h2"] = translate("Price search results for")." <strong>".htmlentities($product["products"][0]["name"],ENT_QUOTES,$config_charset)."</strong>&nbsp;";

Cheers,
David.
--
PriceTapestry.com

Submitted by marco@flapper on Thu, 2011-03-24 18:28

hi,
that works but on the category page the product names are still without the comma.

Look for example on this page:
{link saved}

Submitted by support on Thu, 2011-03-24 19:15

Hi Marco,

Check your html/searchresults.php as it looks like it is using the normalised_name field as the text displayed for the product name. Viewing the source of your page, it's between H3 tags in your file - look for:

  $product["normalised_name"]

...and REPLACE that with:

  $product["name"]

I think that should be all it is - if you're not sure email me your html/searchresults.php and I'll check it out for you...

Cheers,
David.
--
PriceTapestry.com

Submitted by marco@flapper on Fri, 2011-03-25 11:47

thanks it works