Docs Goabase

HelperFormat extends HelperJson
in package

Table of Contents

Methods

calcZipSize()  : int
checkAtts()  : array<string|int, mixed>
setzt (int) auf _id
dateTimeFormat()  : string
translates iso-timestamp into other format YYYY-MM-DD hh:mm:ss uralte funktion
decodeToArray()  : mixed
json to array
doIntRow()  : array<string|int, mixed>
encodeToJson()  : string
Returns the json representation of a value
fetchGeoError()  : string
getCleanIntVal()  : int|float
getPartyTodayHint()  : string
Get "today" or "tomorrow" text for a party date
htmlSan()  : string
humanFilesize()  : string
jsonError()  : void
makeEntityCrapRepair()  : array<string|int, mixed>|string|array<string|int, string>|null
Repairs Entity Crap
numberFormat()  : float|string
Formats a number/price in the language
returnAlphaNum()  : mixed
Helper preg_replace('/[^0-9A-z]/','',$var)
returnAtoZ()  : string
returnDigit()  : int
Helper preg_replace('/\D/','',$var)

Methods

calcZipSize()

public static calcZipSize(int $nSizeChars) : int
Parameters
$nSizeChars : int
Return values
int

checkAtts()

setzt (int) auf _id

public static checkAtts([array<string|int, mixed> $saAtt = [] ]) : array<string|int, mixed>
Parameters
$saAtt : array<string|int, mixed> = []
Return values
array<string|int, mixed>

dateTimeFormat()

translates iso-timestamp into other format YYYY-MM-DD hh:mm:ss uralte funktion

public static dateTimeFormat(string $dateTime[, string $dateFormat = '' ]) : string
Parameters
$dateTime : string

timestamp ISO

$dateFormat : string = ''
Return values
string

decodeToArray()

json to array

public static decodeToArray(string $json) : mixed
Parameters
$json : string

doIntRow()

public static doIntRow([array<string|int, mixed> $saRow = [] ]) : array<string|int, mixed>
Parameters
$saRow : array<string|int, mixed> = []
Return values
array<string|int, mixed>

encodeToJson()

Returns the json representation of a value

public static encodeToJson(mixed $val) : string
Parameters
$val : mixed
Return values
string

fetchGeoError()

public static fetchGeoError() : string
Return values
string

getCleanIntVal()

public static getCleanIntVal(mixed $var) : int|float
Parameters
$var : mixed
Return values
int|float

getPartyTodayHint()

Get "today" or "tomorrow" text for a party date

public static getPartyTodayHint(array<string|int, mixed> $saParty) : string
Parameters
$saParty : array<string|int, mixed>
Tags
throws
Exception
Return values
string

htmlSan()

public static htmlSan(mixed $var) : string
Parameters
$var : mixed
Return values
string

humanFilesize()

public static humanFilesize(string $bytes[, int $decimals = 2 ]) : string
Parameters
$bytes : string
$decimals : int = 2
Return values
string

jsonError()

public static jsonError(int $errorCode, string $errorData) : void
Parameters
$errorCode : int
$errorData : string

makeEntityCrapRepair()

Repairs Entity Crap

public static makeEntityCrapRepair(array<string|int, mixed>|string $strTerm) : array<string|int, mixed>|string|array<string|int, string>|null
Parameters
$strTerm : array<string|int, mixed>|string

"Fovič";

Return values
array<string|int, mixed>|string|array<string|int, string>|null

UTF-8

numberFormat()

Formats a number/price in the language

public static numberFormat(float|string $number[, int $decimals = 2 ]) : float|string
Parameters
$number : float|string
$decimals : int = 2
Return values
float|string

returnAlphaNum()

Helper preg_replace('/[^0-9A-z]/','',$var)

public static returnAlphaNum(mixed $var) : mixed
Parameters
$var : mixed

returnAtoZ()

public static returnAtoZ(mixed $var) : string
Parameters
$var : mixed
Return values
string

returnDigit()

Helper preg_replace('/\D/','',$var)

public static returnDigit(mixed $var) : int
Parameters
$var : mixed
Return values
int

        
On this page

Search results