- Created complete documentation in docs/ directory - Added PROJECT_OVERVIEW.md with feature highlights and getting started guide - Added ARCHITECTURE.md with system design and technical details - Added SECURITY.md with comprehensive security implementation guide - Added DEVELOPMENT.md with development workflows and best practices - Added DEPLOYMENT.md with production deployment instructions - Added API.md with complete REST API documentation - Added CONTRIBUTING.md with contribution guidelines - Added CHANGELOG.md with version history and migration notes - Reorganized all documentation files into docs/ directory for better organization - Updated README.md with proper documentation links and quick navigation - Enhanced project structure with professional documentation standards
39 lines
1.5 KiB
PHP
39 lines
1.5 KiB
PHP
<?php
|
|
defined('_ISVALID') or header('Location: /error');
|
|
|
|
// Minimal polyfills for PHP 8.1+ removals used in this codebase
|
|
|
|
if (!function_exists('strftime')) {
|
|
function strftime($format, $timestamp = null)
|
|
{
|
|
$timestamp = $timestamp ?? time();
|
|
// Map common strftime tokens to date() tokens
|
|
$replacements = [
|
|
'%a' => 'D', // abbreviated weekday name
|
|
'%A' => 'l', // full weekday name
|
|
'%d' => 'd', // day of month, zero-padded
|
|
'%e' => 'j', // day of month, no leading zero
|
|
'%u' => 'N', // ISO-8601 numeric day of week (1-7)
|
|
'%w' => 'w', // numeric day of week (0-6)
|
|
'%b' => 'M', // abbreviated month name
|
|
'%B' => 'F', // full month name
|
|
'%m' => 'm', // month (01-12)
|
|
'%y' => 'y', // 2-digit year
|
|
'%Y' => 'Y', // 4-digit year
|
|
'%H' => 'H', // hour 00-23
|
|
'%I' => 'h', // hour 01-12
|
|
'%M' => 'i', // minute 00-59
|
|
'%S' => 's', // second 00-59
|
|
'%T' => 'H:i:s', // time
|
|
'%p' => 'A', // AM/PM
|
|
'%P' => 'a', // am/pm
|
|
'%z' => 'O', // GMT offset
|
|
'%Z' => 'T', // timezone abbreviation
|
|
'%%' => '%', // literal percent
|
|
];
|
|
$phpFormat = strtr($format, $replacements);
|
|
return date($phpFormat, is_numeric($timestamp) ? (int) $timestamp : strtotime((string) $timestamp));
|
|
}
|
|
}
|
|
|