What do you want to save?
Add Code snippet
New code examples
-
PHP 2022-02-14 09:30:11
convert gb to bytes php
function toByteSize($p_sFormatted) { $aUnits = array('B'=>0, 'KB'=>1, 'MB'=>2, 'GB'=>3, 'TB'=>4, 'PB'=>5, 'EB'=>6, 'ZB'=>7, 'YB'=>8); $sUnit = strtoupper(trim(substr($p_sFormatted, -2))); if (intval($sUnit) !== 0) { ... Add solution -
PHP 2021-11-20 18:21:24
function passing multiple arguments using 3 dots php
function concatenate($transform, ...$strings) { $string = ''; foreach($strings as $piece) { $string .= $piece; } return($transform($string)); } echo concatenate("strtoupper", "I'd ", "like ", 4 + 2, &... Add solution -
PHP 2021-11-16 13:09:18
php while loop of alphabet
// php loop alphabet in foundation buttons with url params as links foreach (range('a', 'z') as $alphabet) { echo "<a class=\"button" href=\"example.com?letter=" . $alphabet . "\">" . strto... Add solution -
PHP 2021-10-24 02:42:08
php convert mb to bytes
function toByteSize($p_sFormatted) { $aUnits = array('B'=>0, 'KB'=>1, 'MB'=>2, 'GB'=>3, 'TB'=>4, 'PB'=>5, 'EB'=>6, 'ZB'=>7, 'YB'=>8); $sUnit = strtoupper(trim(substr($p_sFormatted, -2))); if (intval($sUnit) !== 0) { ... Add solution