- ANCHR
- ANLoc Martin Benjamin locales@africanlocalization.net
- Aaron Patterson
- Abdellah Chadidi
- Adam
- Adam Brunner
- Ahmed Ali
- Akademe ya Luganda Kizito Birabwa kompyuta@kizito.uklinux.net
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
function convertToCelsiusDegrees($degrees, $scale = 'celsius') | |
{ | |
if ($scale == 'fahrenheit') { | |
return $degrees * 1.8 + 32; | |
} | |
return $degrees; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
function getWaterState($degrees, $scale = 'celsius') | |
{ | |
$celsiusDegrees = $scale == 'fahrenheit' | |
? $degrees * 1.8 + 32 | |
: $degrees; | |
if ($celsiusDegrees < 0) { | |
return 'This is solid ice'; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
function getWaterState($degrees, $scale = 'celsius') | |
{ | |
if ($scale == 'fahrenheit') { | |
$celsiusDegrees = $degrees * 1.8 + 32; | |
} else { | |
$celsiusDegrees = $degrees; | |
} | |
if ($celsiusDegrees < 0) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
function getWaterState($degrees) | |
{ | |
if ($degrees < 0) { | |
return 'This is solid ice'; | |
} | |
if ($degrees > 100) { | |
return 'This is gaz water'; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
function getWaterState($degrees, $important = false) | |
{ | |
if ($degrees < 0) { | |
$state = 'This is solid ice'; | |
} elseif ($degrees > 100) { | |
$state = 'This is gaz water'; | |
} else { | |
$state = 'This is liquid water'; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
function getWaterState($degrees) | |
{ | |
if ($degrees < 0) { | |
return 'This is solid ice'; | |
} elseif ($degrees > 100) { | |
return 'This is gaz water'; | |
} else { | |
return 'This is liquid water'; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$dateString = rtrim($_POST['date'], 'Z'); | |
$date = new DateTimeImmutable("$dateString Asia/Tokyo"); | |
echo $date->setTimezone(new DateTimeZone('UTC'))->format('Y-m-d H:i:s.u'); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var date = new Date(dateString + 'T' + timeString + 'Z'); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$date = new DateTimeImmutable($_POST['date']); | |
echo $date->format('Y-m-d H:i:s.u'); |
NewerOlder