################ Helper Functions ################ The QVCI framework provides a number of standard helper functions. List of Helpers =============== ci() ---- This returns the CodeIgniter instance. appuser() --------- This function is actually provided by Authuser. array_select($keys, $array) --------------------------- Reduce an array to a specific selection of keys, if they exist. Useful for restricting options to a select few. fixnum($number, $decimals=2) ---------------------------- Return a number in fixed-point decimal without a thousands separator. This should be used consistently across the application to ensure that fixed-point numbers are rendered properly, always using the specified number of decimal points and never with thousands separators. If the application wants to render a number using a thousands separator, then it should use number_format(). parse_num($n) ------------- Given a numeric string which may contain comma separators, return the number with commas removed. This should be used consistently across the application, usually when processing form input, to ensure that it can handle numbers (int or fixed-point) that may contain a thousands separator.