title: Codeigniter - is it risky to modify the cart $product_name_rules to accept any character?
body: <p>I'm using the Cart Class in CI, and my product names contain lots of "dangerous" characters, such as apostrophe, brackets, semicolon, ampersands, and many non latin characters.</p>
  
  <p>The Cart Class limits the allowed characters like so:</p>
  
  <pre><code>var $product_name_rules = '\.\:\-_ a-z0-9'; // alpha-numeric, dashes, underscores, colons or periods
  </code></pre>
  
  <p>I know I can extend the Cart Class and override this limitation with something like this in a MY_Cart Class:</p>
  
  <pre><code>$this-&gt;product_name_rules = '\d\D'; 
  </code></pre>
  
  <p>But this makes me wonder - perhaps the CI people had a reason for limiting the product names. Maybe by removing the limitation I'm opening a backdoor to hackers.</p>
  
  <p>Obviously, when I add items from the cart to my database, I use Active Records and query binding, which should (to my best understanding) provide a sufficient defense against sql injections and the like. </p>
  
  <p>So what was the idea behind limiting the characters in the first place?</p>