AAAAhome/academiac/www/administrator/components/com_virtuemart/tables/shoppergroups.php000060400000004230151372152570025222 0ustar00setUniqueName('shopper_group_name'); $this->setLoggable(); $this->setTableShortCut('sg'); } // /** // * Validates the shopper group record fields. // * // * @author Markus Öhler // * @return boolean True if the table buffer contains valid data, false otherwise. // */ function check(){ if (empty($this->shopper_group_name) ){ vmError(JText::_('COM_VIRTUEMART_SHOPPERGROUP_RECORDS_MUST_HAVE_NAME')); return false; } else { if(function_exists('mb_strlen') ){ if (mb_strlen($this->shopper_group_name) > 32) { vmError(JText::_('COM_VIRTUEMART_SHOPPERGROUP_NAME_LESS_THAN_32_CHARACTERS')); return false; } } else { if (strlen($this->shopper_group_name) > 32) { vmError(JText::_('COM_VIRTUEMART_SHOPPERGROUP_NAME_LESS_THAN_32_CHARACTERS')); return false; } } } return parent::check(); } } // pure php no closing tag