Misc - staffcheck/api GitHub Wiki

Misc

  • Class name: Misc
  • Namespace:

Methods

findSubmitButton

null|string Misc::findSubmitButton(string $prefix)
  • Visibility: public
  • This method is static.

Arguments

  • $prefix string

getSortDirectionArray

array Misc::getSortDirectionArray(boolean $text_keys)
  • Visibility: public
  • This method is static.

Arguments

  • $text_keys boolean

ArrayAssocSum

array|boolean Misc::ArrayAssocSum($array, null $element, null $decimals, boolean $include_non_numeric)
  • Visibility: public
  • This method is static.

Arguments

  • $array mixed
  • $element null
  • $decimals null
  • $include_non_numeric boolean

ArrayGroupBy

array Misc::ArrayGroupBy($array, $group_by_elements, array $ignore_elements)
  • Visibility: public
  • This method is static.

Arguments

  • $array mixed
  • $group_by_elements mixed
  • $ignore_elements array

ArrayAvg

boolean|float|integer Misc::ArrayAvg($arr)
  • Visibility: public
  • This method is static.

Arguments

  • $arr mixed

prependArray

array|boolean Misc::prependArray($prepend_arr, $arr)
  • Visibility: public
  • This method is static.

Arguments

  • $prepend_arr mixed
  • $arr mixed

arrayColumn

array|boolean|null Misc::arrayColumn(null $input, null $columnKey, null $indexKey)
  • Visibility: public
  • This method is static.

Arguments

  • $input null
  • $columnKey null
  • $indexKey null

flattenArray

array Misc::flattenArray($array, boolean $preserve, array $r)
  • Visibility: public
  • This method is static.

Arguments

  • $array mixed
  • $preserve boolean
  • $r array

arrayIntersectByKey

array|null Misc::arrayIntersectByKey($keys, $options)
  • Visibility: public
  • This method is static.

Arguments

  • $keys mixed
  • $options mixed

arrayIntersectByRow

boolean|mixed Misc::arrayIntersectByRow($rows)
  • Visibility: public
  • This method is static.

Arguments

  • $rows mixed

arrayCommonValuesForEachKey

array|boolean Misc::arrayCommonValuesForEachKey($rows, null $filter_columns)

Returns the most common values for each key (column) in the rows.

  • Visibility: public
  • This method is static.

Arguments

  • $rows mixed
  • $filter_columns null - Specific columns to get common data for.

arrayDiffByKey

array|null Misc::arrayDiffByKey($keys, $options)
  • Visibility: public
  • This method is static.

Arguments

  • $keys mixed
  • $options mixed

arrayMergeRecursiveDistinct

array Misc::arrayMergeRecursiveDistinct(array $array1, array $array2)
  • Visibility: public
  • This method is static.

Arguments

  • $array1 array
  • $array2 array

arrayMergeRecursive

array Misc::arrayMergeRecursive(array $array1, array $array2)
  • Visibility: public
  • This method is static.

Arguments

  • $array1 array
  • $array2 array

arrayDiffAssocRecursive

array|boolean Misc::arrayDiffAssocRecursive($array1, $array2)
  • Visibility: public
  • This method is static.

Arguments

  • $array1 mixed
  • $array2 mixed

arrayCommonValue

mixed Misc::arrayCommonValue($arr)
  • Visibility: public
  • This method is static.

Arguments

  • $arr mixed

arrayIUnique

array Misc::arrayIUnique($array)

Case insensitive array_unique().

  • Visibility: public
  • This method is static.

Arguments

  • $array mixed

addKeyPrefix

array Misc::addKeyPrefix($prefix, $arr, null $ignore_elements)
  • Visibility: public
  • This method is static.

Arguments

  • $prefix mixed
  • $arr mixed
  • $ignore_elements null

removeKeyPrefix

array|boolean Misc::removeKeyPrefix($prefix, $arr, null $ignore_elements)
  • Visibility: public
  • This method is static.

Arguments

  • $prefix mixed
  • $arr mixed
  • $ignore_elements null

addSortPrefix

array|boolean Misc::addSortPrefix($arr, integer $begin_counter)
  • Visibility: public
  • This method is static.

Arguments

  • $arr mixed
  • $begin_counter integer

trimSortPrefix

array|mixed Misc::trimSortPrefix($value, boolean $trim_arr_value)
  • Visibility: public
  • This method is static.

Arguments

  • $value mixed
  • $trim_arr_value boolean

strReplaceOnce

mixed Misc::strReplaceOnce($str_pattern, $str_replacement, $string)
  • Visibility: public
  • This method is static.

Arguments

  • $str_pattern mixed
  • $str_replacement mixed
  • $string mixed

FileDownloadHeader

boolean Misc::FileDownloadHeader($file_name, $type, $size)
  • Visibility: public
  • This method is static.

Arguments

  • $file_name mixed
  • $type mixed
  • $size mixed

APIFileDownload

boolean Misc::APIFileDownload($file_name, $type, $data)
  • Visibility: public
  • This method is static.

Arguments

  • $file_name mixed
  • $type mixed
  • $data mixed

removeTrailingZeros

string Misc::removeTrailingZeros($value, integer $minimum_decimals)

value should be a float and not a string. be sure to run this before TTi18n currency or number formatter due to foreign numeric formatting for decimal being a comma.

  • Visibility: public
  • This method is static.

Arguments

  • $value mixed - float
  • $minimum_decimals integer

MoneyFormat

string Misc::MoneyFormat($value, boolean $pretty)

Just a number format that looks like currency without currency symbol can maybe be replaced by TTi18n::numberFormat()

  • Visibility: public
  • This method is static.

Arguments

  • $value mixed
  • $pretty boolean

abbreviateString

boolean|string Misc::abbreviateString($str)
  • Visibility: public
  • This method is static.

Arguments

  • $str mixed

TruncateString

string Misc::TruncateString($str, $length, integer $start, boolean $abbreviate)
  • Visibility: public
  • This method is static.

Arguments

  • $str mixed
  • $length mixed
  • $start integer
  • $abbreviate boolean

HumanBoolean

string Misc::HumanBoolean($bool)
  • Visibility: public
  • This method is static.

Arguments

  • $bool mixed

getBeforeDecimal

integer Misc::getBeforeDecimal($float)
  • Visibility: public
  • This method is static.

Arguments

  • $float mixed

getAfterDecimal

integer Misc::getAfterDecimal($float, boolean $format_number)
  • Visibility: public
  • This method is static.

Arguments

  • $float mixed
  • $format_number boolean

removeDecimal

mixed Misc::removeDecimal($value)
  • Visibility: public
  • This method is static.

Arguments

  • $value mixed

encodeInteger

string Misc::encodeInteger($int)
  • Visibility: public
  • This method is static.

Arguments

  • $int mixed

decodeInteger

integer Misc::decodeInteger($str, integer $max)
  • Visibility: public
  • This method is static.

Arguments

  • $str mixed
  • $max integer

calculatePercent

float|integer Misc::calculatePercent($current, $maximum, integer $precision)
  • Visibility: public
  • This method is static.

Arguments

  • $current mixed
  • $maximum mixed
  • $precision integer

sumMultipleColumns

boolean|integer|string Misc::sumMultipleColumns($data, $sum_elements)
  • Visibility: public
  • This method is static.

Arguments

  • $data mixed
  • $sum_elements mixed

calculateIncludeExcludeAmount

integer Misc::calculateIncludeExcludeAmount($amount, $element, array $include_elements, array $exclude_elements)
  • Visibility: public
  • This method is static.

Arguments

  • $amount mixed
  • $element mixed
  • $include_elements array
  • $exclude_elements array

calculateMultipleColumns

boolean|integer|string Misc::calculateMultipleColumns($data, array $include_elements, array $exclude_elements)
  • Visibility: public
  • This method is static.

Arguments

  • $data mixed
  • $include_elements array
  • $exclude_elements array

getPointerFromArray

mixed Misc::getPointerFromArray($array, $element, integer $start)
  • Visibility: public
  • This method is static.

Arguments

  • $array mixed
  • $element mixed
  • $start integer

AdjustXY

mixed Misc::AdjustXY($coord, $adjust_coord)
  • Visibility: public
  • This method is static.

Arguments

  • $coord mixed
  • $adjust_coord mixed

writeBarCodeFile

boolean Misc::writeBarCodeFile($file_name, $num, boolean $print_text, integer $height)
  • Visibility: public
  • This method is static.

Arguments

  • $file_name mixed
  • $num mixed
  • $print_text boolean
  • $height integer

hex2rgb

array|string Misc::hex2rgb($hex, boolean $asString)
  • Visibility: public
  • This method is static.

Arguments

  • $hex mixed
  • $asString boolean

escapeCSVTriggerChars

mixed Misc::escapeCSVTriggerChars($input)

Mititage CSV Injection attacks: See below links for more information: [1] https://www.owasp.org/index.php/CSV_Excel_Macro_Injection [2] https://hackerone.com/reports/72785 [3] https://hackerone.com/reports/90131

  • Visibility: public
  • This method is static.

Arguments

  • $input mixed

Array2CSV

boolean|null|string Misc::Array2CSV($data, null $columns, boolean $ignore_last_row, boolean $include_header, string $eol)
  • Visibility: public
  • This method is static.

Arguments

  • $data mixed
  • $columns null
  • $ignore_last_row boolean
  • $include_header boolean
  • $eol string

Array2JSON

boolean|null|string Misc::Array2JSON($data, null $columns)
  • Visibility: public
  • This method is static.

Arguments

  • $data mixed
  • $columns null

Array2XML

boolean|null|string Misc::Array2XML($data, null $columns, null $column_format, boolean $ignore_last_row, boolean $include_xml_header, string $root_element_name, string $row_element_name)
  • Visibility: public
  • This method is static.

Arguments

  • $data mixed
  • $columns null
  • $column_format null
  • $ignore_last_row boolean
  • $include_xml_header boolean
  • $root_element_name string
  • $row_element_name string

Export2XML

mixed Misc::Export2XML($factory_arr, $filter_data, $output_file)
  • Visibility: public
  • This method is static.

Arguments

  • $factory_arr mixed
  • $filter_data mixed
  • $output_file mixed

ExportListFactory2XML

boolean Misc::ExportListFactory2XML($lf, $filter_data, $file_pointer)
  • Visibility: public
  • This method is static.

Arguments

  • $lf mixed
  • $filter_data mixed
  • $file_pointer mixed

inArrayByKeyAndValue

boolean Misc::inArrayByKeyAndValue($arr, $search_key, $search_value)
  • Visibility: public
  • This method is static.

Arguments

  • $arr mixed
  • $search_key mixed
  • $search_value mixed

preSetArrayValues

array|boolean Misc::preSetArrayValues($arr, $keys, null $preset_value)
  • Visibility: public
  • This method is static.

Arguments

  • $arr mixed
  • $keys mixed
  • $preset_value null

getMimeType

boolean|mixed|string Misc::getMimeType($file_name, boolean $buffer, boolean $keep_charset, string $unknown_type)
  • Visibility: public
  • This method is static.

Arguments

  • $file_name mixed
  • $buffer boolean
  • $keep_charset boolean
  • $unknown_type string

countLinesInFile

integer Misc::countLinesInFile($file)
  • Visibility: public
  • This method is static.

Arguments

  • $file mixed

parseCSV

array|boolean Misc::parseCSV($file, boolean $head, boolean $first_column, string $delim, integer $len, null $max_lines)
  • Visibility: public
  • This method is static.

Arguments

  • $file mixed
  • $head boolean
  • $first_column boolean
  • $delim string
  • $len integer
  • $max_lines null

importApplyColumnMap

array|boolean Misc::importApplyColumnMap($column_map, $csv_arr)
  • Visibility: public
  • This method is static.

Arguments

  • $column_map mixed
  • $csv_arr mixed

censorString

boolean|string Misc::censorString($str, string $censor_char, integer|null $min_first_chunk_size, integer|null $max_first_chunk_size, integer|null $min_last_chunk_size, integer|null $max_last_chunk_size)

censor part of a string for purposes of displaying things like SIN, bank accounts, credit card numbers.

  • Visibility: public
  • This method is static.

Arguments

  • $str mixed
  • $censor_char string
  • $min_first_chunk_size integer|null
  • $max_first_chunk_size integer|null
  • $min_last_chunk_size integer|null
  • $max_last_chunk_size integer|null

encrypt

boolean|string Misc::encrypt($str, null $salt, null $key)
  • Visibility: public
  • This method is static.

Arguments

  • $str mixed
  • $salt null
  • $key null

decrypt

boolean|string Misc::decrypt($str, null $salt, null $key)

We can't reliably test that decryption was successful, so type checking should be done in the calling function. (see RemittanceDestinationAccountFactory::getValue3())

  • Visibility: public
  • This method is static.

Arguments

  • $str mixed
  • $salt null
  • $key null

getJSArray

string Misc::getJSArray($values, null $name, boolean $assoc, boolean $object)
  • Visibility: public
  • This method is static.

Arguments

  • $values mixed
  • $name null
  • $assoc boolean
  • $object boolean

getArrayNeighbors

array Misc::getArrayNeighbors($arr, $key, string $neighbor)
  • Visibility: public
  • This method is static.

Arguments

  • $arr mixed
  • $key mixed
  • $neighbor string

getURLProtocol

string Misc::getURLProtocol()
  • Visibility: public
  • This method is static.

getRemoteHTTPFileSize

boolean|mixed Misc::getRemoteHTTPFileSize($url)
  • Visibility: public
  • This method is static.

Arguments

  • $url mixed

downloadHTTPFile

boolean|integer Misc::downloadHTTPFile($url, $file_name)
  • Visibility: public
  • This method is static.

Arguments

  • $url mixed
  • $file_name mixed

getEmailDomain

string Misc::getEmailDomain()
  • Visibility: public
  • This method is static.

getEmailLocalPart

string Misc::getEmailLocalPart()
  • Visibility: public
  • This method is static.

getEmailReturnPathLocalPart

string Misc::getEmailReturnPathLocalPart(null $email)
  • Visibility: public
  • This method is static.

Arguments

  • $email null

checkValidDomain

boolean Misc::checkValidDomain()
  • Visibility: public
  • This method is static.

checkValidReferer

boolean Misc::checkValidReferer(boolean $referer)
  • Visibility: public
  • This method is static.

Arguments

  • $referer boolean

getHostNameWithoutSubDomain

string Misc::getHostNameWithoutSubDomain($host_name)
  • Visibility: public
  • This method is static.

Arguments

  • $host_name mixed

getHostName

string Misc::getHostName(boolean $include_port)
  • Visibility: public
  • This method is static.

Arguments

  • $include_port boolean

parseDatabaseHostString

array Misc::parseDatabaseHostString($database_host_string)
  • Visibility: public
  • This method is static.

Arguments

  • $database_host_string mixed

isOpenPort

boolean Misc::isOpenPort($address, integer $port, integer $timeout)
  • Visibility: public
  • This method is static.

Arguments

  • $address mixed
  • $port integer
  • $timeout integer

findClosestMatch

array|boolean|mixed Misc::findClosestMatch($search_str, $search_arr, integer $minimum_percent_match, boolean $return_all_matches)

Accepts a search_str and key=>val array that it searches through, to return the array key of the closest fuzzy match.

  • Visibility: public
  • This method is static.

Arguments

  • $search_str mixed
  • $search_arr mixed
  • $minimum_percent_match integer
  • $return_all_matches boolean

NumberToLetter

boolean|string Misc::NumberToLetter($number)
  • Visibility: public
  • This method is static.

Arguments

  • $number mixed

reScaleRange

float|integer Misc::reScaleRange($value, integer $old_min, integer $old_max, integer $new_min, integer $new_max)
  • Visibility: public
  • This method is static.

Arguments

  • $value mixed
  • $old_min integer
  • $old_max integer
  • $new_min integer
  • $new_max integer

issetOr

null Misc::issetOr($var, null $default)
  • Visibility: public
  • This method is static.

Arguments

  • $var mixed
  • $default null

getFullName

boolean|string Misc::getFullName($first_name, $middle_name, $last_name, boolean $reverse, boolean $include_middle)
  • Visibility: public
  • This method is static.

Arguments

  • $first_name mixed
  • $middle_name mixed
  • $last_name mixed
  • $reverse boolean
  • $include_middle boolean

getCityAndProvinceAndPostalCode

string Misc::getCityAndProvinceAndPostalCode($city, $province, $postal_code)
  • Visibility: public
  • This method is static.

Arguments

  • $city mixed
  • $province mixed
  • $postal_code mixed

parseCallerID

boolean|string Misc::parseCallerID($number)

Caller ID numbers can come in in all sorts of forms: 2505551234 12505551234 +12505551234 (250) 555-1234 Parse out just the digits, and use only the last 10 digits.

Currently this will not support international numbers

  • Visibility: public
  • This method is static.

Arguments

  • $number mixed

generateCopyName

boolean|string Misc::generateCopyName($name, boolean $strict)
  • Visibility: public
  • This method is static.

Arguments

  • $name mixed
  • $strict boolean

generateShareName

boolean|string Misc::generateShareName($from, $name, boolean $strict)
  • Visibility: public
  • This method is static.

Arguments

  • $from mixed
  • $name mixed
  • $strict boolean

cleanDir

boolean Misc::cleanDir($path, $recursive, boolean $del_dirs, boolean $del_root, $exclude_regex_filter)

Delete all files in directory

  • Visibility: public
  • This method is static.

Arguments

  • $path mixed - string directory to clean
  • $recursive mixed - boolean delete files in subdirs
  • $del_dirs boolean
  • $del_root boolean
  • $exclude_regex_filter mixed - string regex to exclude paths

deleteEmptyDirectory

mixed Misc::deleteEmptyDirectory($path, $recurse_parent_levels)
  • Visibility: public
  • This method is static.

Arguments

  • $path mixed
  • $recurse_parent_levels mixed

rename

boolean Misc::rename($old_name, $new_name)

If rename fails for some reason, attempt a copy instead as that might work, specifically on windows where if the file is in use.

Might fix possible "Access is denied. (code: 5)" errors on Windows when using PHP v5.2 (https://bugs.php.net/bug.php?id=43817)

  • Visibility: public
  • This method is static.

Arguments

  • $old_name mixed
  • $new_name mixed

getFileList

array|boolean Misc::getFileList($start_dir, null $regex_filter, boolean $recurse)
  • Visibility: public
  • This method is static.

Arguments

  • $start_dir mixed
  • $regex_filter null
  • $recurse boolean

isSubDirectory

boolean Misc::isSubDirectory($child_dir, $parent_dir)
  • Visibility: public
  • This method is static.

Arguments

  • $child_dir mixed
  • $parent_dir mixed

convertObjectToArray

array Misc::convertObjectToArray(object $obj)
  • Visibility: public
  • This method is static.

Arguments

  • $obj object

getBytesFromSize

integer|string Misc::getBytesFromSize($val)
  • Visibility: public
  • This method is static.

Arguments

  • $val mixed

getSystemMemoryInfo

integer|string Misc::getSystemMemoryInfo()
  • Visibility: public
  • This method is static.

getSystemLoad

integer|mixed Misc::getSystemLoad()
  • Visibility: public
  • This method is static.

isSystemLoadValid

boolean Misc::isSystemLoadValid()
  • Visibility: public
  • This method is static.

formatEmailAddress

string Misc::formatEmailAddress($email, object $user_obj)
  • Visibility: public
  • This method is static.

Arguments

  • $email mixed
  • $user_obj object

parseRFC822EmailAddress

boolean Misc::parseRFC822EmailAddress($input, boolean $return_just_key)
  • Visibility: public
  • This method is static.

Arguments

  • $input mixed
  • $return_just_key boolean

sendSystemMail

boolean Misc::sendSystemMail($subject, $body, null $attachments, boolean $force)
  • Visibility: public
  • This method is static.

Arguments

  • $subject mixed
  • $body mixed
  • $attachments null
  • $force boolean

isCurrentOSUserRoot

mixed Misc::isCurrentOSUserRoot()
  • Visibility: public
  • This method is static.

getCurrentOSUser

mixed Misc::getCurrentOSUser()
  • Visibility: public
  • This method is static.

setProcessUID

mixed Misc::setProcessUID($uid)
  • Visibility: public
  • This method is static.

Arguments

  • $uid mixed

findWebServerOSUser

mixed Misc::findWebServerOSUser()
  • Visibility: public
  • This method is static.

disableCaching

boolean Misc::disableCaching(boolean $email_notification)
  • Visibility: public
  • This method is static.

Arguments

  • $email_notification boolean

getMapURL

boolean|string Misc::getMapURL($address1, $address2, $city, $province, $postal_code, $country, string $service)
  • Visibility: public
  • This method is static.

Arguments

  • $address1 mixed
  • $address2 mixed
  • $city mixed
  • $province mixed
  • $postal_code mixed
  • $country mixed
  • $service string

isEmail

boolean Misc::isEmail($email, boolean $check_dns, boolean $error_level, $return_raw_result)
  • Visibility: public
  • This method is static.

Arguments

  • $email mixed
  • $check_dns boolean
  • $error_level boolean
  • $return_raw_result mixed

getPasswordStrength

integer Misc::getPasswordStrength($password)
  • Visibility: public
  • This method is static.

Arguments

  • $password mixed

getCurrentCompanyProductEdition

integer Misc::getCurrentCompanyProductEdition()
  • Visibility: public
  • This method is static.

redirectMobileBrowser

boolean Misc::redirectMobileBrowser()
  • Visibility: public
  • This method is static.

redirectUnSupportedBrowser

boolean Misc::redirectUnSupportedBrowser()
  • Visibility: public
  • This method is static.

isUnSupportedBrowser

boolean Misc::isUnSupportedBrowser(null $useragent)
  • Visibility: public
  • This method is static.

Arguments

  • $useragent null

isSearchEngineBrowser

boolean Misc::isSearchEngineBrowser(null $useragent)
  • Visibility: public
  • This method is static.

Arguments

  • $useragent null

detectMobileBrowser

boolean|string Misc::detectMobileBrowser(null $useragent)
  • Visibility: public
  • This method is static.

Arguments

  • $useragent null

PercentDistribution

array|boolean Misc::PercentDistribution($amount, $percent_arr, string $remainder_operation, integer $precision)
  • Visibility: public
  • This method is static.

Arguments

  • $amount mixed
  • $percent_arr mixed
  • $remainder_operation string
  • $precision integer

arrayChangeValueCase

array|boolean Misc::arrayChangeValueCase($input, integer $case)
  • Visibility: public
  • This method is static.

Arguments

  • $input mixed
  • $case integer

isWritable

boolean Misc::isWritable($path)

Checks to see if a file/directory is writable.

  • Visibility: public
  • This method is static.

Arguments

  • $path mixed

getRemoteIPAddress

boolean Misc::getRemoteIPAddress()
  • Visibility: public
  • This method is static.

isSSL

boolean Misc::isSSL(boolean $ignore_force_ssl)
  • Visibility: public
  • This method is static.

Arguments

  • $ignore_force_ssl boolean

MajorVersionCompare

mixed Misc::MajorVersionCompare($version1, $version2, $operator)
  • Visibility: public
  • This method is static.

Arguments

  • $version1 mixed
  • $version2 mixed
  • $operator mixed

getInstanceIdentificationString

string Misc::getInstanceIdentificationString($primary_company, $system_settings)
  • Visibility: public
  • This method is static.

Arguments

  • $primary_company mixed
  • $system_settings mixed

stripThe

boolean|string Misc::stripThe($str, boolean $add_to_end)
  • Visibility: public
  • This method is static.

Arguments

  • $str mixed
  • $add_to_end boolean

stripHTMLSpecialChars

mixed Misc::stripHTMLSpecialChars($str)
  • Visibility: public
  • This method is static.

Arguments

  • $str mixed

checkValidImage

boolean Misc::checkValidImage($file_data)
  • Visibility: public
  • This method is static.

Arguments

  • $file_data mixed

formatAddress

string Misc::formatAddress($name, boolean $address1, boolean $address2, boolean $city, boolean $province, boolean $postal_code, boolean $country, $condensed)
  • Visibility: public
  • This method is static.

Arguments

  • $name mixed
  • $address1 boolean
  • $address2 boolean
  • $city boolean
  • $province boolean
  • $postal_code boolean
  • $country boolean
  • $condensed mixed

getUniqueID

string Misc::getUniqueID()
  • Visibility: public
  • This method is static.

sanitizeFileName

mixed|string|array<mixed,string>|null Misc::sanitizeFileName($file_name)

Sanitize strings to be used in file names by converting spaces to underscore and removing non-alpha numeric characters

  • Visibility: public
  • This method is static.

Arguments

  • $file_name mixed

zip

array Misc::zip($file_array, boolean $zip_file_name, boolean $ignore_single_file)

zips an array of files and returns a file array for download

  • Visibility: public
  • This method is static.

Arguments

  • $file_array mixed
  • $zip_file_name boolean
  • $ignore_single_file boolean

getAmountUpToLimit

integer Misc::getAmountUpToLimit($amount, $limit)
  • Visibility: public
  • This method is static.

Arguments

  • $amount mixed
  • $limit mixed

getAmountDifferenceUpToLimit

string Misc::getAmountDifferenceUpToLimit($amount, $limit)

This is can be used to handle YTD amounts.

  • Visibility: public
  • This method is static.

Arguments

  • $amount mixed
  • $limit mixed

getHardwareID

mixed Misc::getHardwareID()
  • Visibility: public
  • This method is static.
⚠️ **GitHub.com Fallback** ⚠️