Welcome Guest, Not a member yet? Register   Sign In
Restrictions on cart name
#1

[eluser]markbarratt[/eluser]
This may be a feature not a bug of the Cart library in svn.

The 'name' part of a cart array appears to be limited by:

1: being in ASCII plus common punctuation, at line 31 of Cart.php:

Code:
var $product_name_rules    = '\.\:\-_ a-z0-9'; // alpha-numeric, dashes, underscores, colons or periods

Is there any reason for this restriction? I have titles in both modern European and also occasionally in non-Latin scripts.

2: There appears to be a length restriction on the name item, though I can't find any reference to that in the code: at any rate, items with long titles which otherwise meet the regex validation don't add to the cart.

I could probably work round these issues (as long as the options array will accept long utf-8 strings!) on the grounds that the cart library is pretty spiffing otherwise, but it would be good to know whether these are known limitations, configurable settings, or bugs.

Thanks


Messages In This Thread
Restrictions on cart name - by El Forum - 09-09-2009, 09:53 AM
Restrictions on cart name - by El Forum - 02-18-2010, 04:09 PM
Restrictions on cart name - by El Forum - 02-18-2010, 04:15 PM



Theme © iAndrew 2016 - Forum software by © MyBB