Merge branch 'master' of https://git.lolcat.ca/lolcat/4get
Before Width: | Height: | Size: 30 KiB After Width: | Height: | Size: 22 KiB |
BIN
favicon.ico
Before Width: | Height: | Size: 393 B After Width: | Height: | Size: 193 B |
BIN
lib/classic.png
Before Width: | Height: | Size: 7.4 KiB After Width: | Height: | Size: 358 B |
Before Width: | Height: | Size: 807 B After Width: | Height: | Size: 744 B |
BIN
lib/img404.png
Before Width: | Height: | Size: 4.4 KiB After Width: | Height: | Size: 216 B |
|
@ -118,7 +118,7 @@ class calculator extends oracle {
|
|||
if (count($tokens) > 0 && $tokens[0][0] == "o" || $tokens[count($tokens)-1][0] == "o") {
|
||||
throw new Exception("Error Processing Request", 1);
|
||||
}
|
||||
if (in_array(["g", "("], $tokens)) {
|
||||
while (in_array(["g", "("], $tokens)) {
|
||||
$first_open = array_search(["g", "("], $tokens);
|
||||
$enclosedality = 1;
|
||||
for ($i = $first_open+1; $i < count($tokens); $i++) {
|
||||
|
|
|
@ -8,7 +8,7 @@ class time extends oracle {
|
|||
$prompts = [
|
||||
"what", "time", "is", "it",
|
||||
"right", "now", "the", "current",
|
||||
"get"
|
||||
"get", "date"
|
||||
];
|
||||
$q = str_replace(",", "", $q);
|
||||
$q = str_replace("?", "", $q);
|
||||
|
@ -37,6 +37,7 @@ class time extends oracle {
|
|||
date_default_timezone_set($timezone);
|
||||
return [
|
||||
"The time in ".$timezone => date("H:i:s"),
|
||||
" " => date("l, F jS"),
|
||||
"" => "include the string \"tz:XXX\" to use timezone XXX"
|
||||
];
|
||||
}
|
||||
|
|
Before Width: | Height: | Size: 1.2 KiB After Width: | Height: | Size: 1.2 KiB |
Before Width: | Height: | Size: 574 B After Width: | Height: | Size: 555 B |
Before Width: | Height: | Size: 1.7 KiB After Width: | Height: | Size: 1.6 KiB |
Before Width: | Height: | Size: 511 B After Width: | Height: | Size: 508 B |
Before Width: | Height: | Size: 1.3 KiB After Width: | Height: | Size: 1.2 KiB |
Before Width: | Height: | Size: 1.8 KiB After Width: | Height: | Size: 1.8 KiB |
Before Width: | Height: | Size: 1.7 KiB After Width: | Height: | Size: 1.7 KiB |
Before Width: | Height: | Size: 841 B After Width: | Height: | Size: 835 B |
Before Width: | Height: | Size: 602 B After Width: | Height: | Size: 592 B |
Before Width: | Height: | Size: 629 B After Width: | Height: | Size: 622 B |
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 1 KiB |
Before Width: | Height: | Size: 1.3 KiB After Width: | Height: | Size: 1.3 KiB |