Knowledgebase

Home » Item #922

Update language strings gives error

Item: #922
Date: 26 Jan 2005
Applies to
v5

Question

When I edit language strings in the back end, I get an error when I submit the change. I noticed that the version number of the string appears to show a comma instead of a decimal point, for example:

5,003 rather than 5.003

Why is this and what can I do about it?

Answer

This problem is due to the server running European or non-English settings but the database drivers expecting English number formats.

We have seen this with some European customers and occasionally with some UK hosts owned by European companies (for example 1&1 which is part of Schlunde in Germany).

In Europe, the comma "," rather than point "." is used to separate whole numbers from decimal fractions.

In the UK and US, we would write:

567.89

Whereas in most of Europe, it would be written:

567,89

CactuShop sets the local ID in the config file to English settings, but on some servers this appears to be ignored, certainly with respect to numbers.

To code around this, you can make a small change to the _update_langstring.asp script. Add this line around line 30:

LS_VersionAdded = replace(LS_VersionAdded, ",", ".")

This should replace commas with decimal points for the LS_VersionAdded value before submitting to the database.

Can't find the answer you need? Click here to open a support ticket.

« Back