1
0
mirror of https://github.com/processwire/processwire.git synced 2025-08-08 07:47:00 +02:00

Add PR #291 - remove php version check for strftime call in WireDateTime

This commit is contained in:
tobaco
2024-08-09 14:20:15 -04:00
committed by Ryan Cramer
parent 6e93844c19
commit 1fdc61dc41
3 changed files with 3 additions and 3 deletions

View File

@@ -421,7 +421,7 @@ class WireDateTime extends Wire {
$value = $this->relativeTimeStr($ts, 1, false); $value = $this->relativeTimeStr($ts, 1, false);
} else if($format == 'ts') { } else if($format == 'ts') {
$value = $ts; $value = $ts;
} else if(strpos($format, '%') !== false && version_compare(PHP_VERSION, '8.1.0', '<')) { } else if(strpos($format, '%') !== false) {
$value = $this->strftime($format, $ts); $value = $this->strftime($format, $ts);
} else { } else {
$value = date($format, $ts); $value = date($format, $ts);

View File

@@ -2937,7 +2937,7 @@ function InputfieldReloadEvent(event, extraData) {
var $content; var $content;
if(data.indexOf('{') === 0) { if(data.indexOf('{') === 0) {
data = JSON.parse(data); data = JSON.parse(data);
console.log(data); // console.log(data);
$content = ''; $content = '';
} else { } else {
$content = jQuery(data).find("#" + id).children(".InputfieldContent"); $content = jQuery(data).find("#" + id).children(".InputfieldContent");

File diff suppressed because one or more lines are too long