'KidsHandwriting-Regular.woff2', 'woff' => 'KidsHandwriting-Regular.woff', 'ttf' => 'KidsHandwriting-Regular.ttf', ]; $fontSources = []; foreach ($customFontFiles as $format => $file) { if (is_file($fontDir . '/' . $file)) { $fontSources[] = "url('" . htmlspecialchars($fontBase . '/' . $file, ENT_QUOTES) . "') format('{$format}')"; } } $fontFaceCss = ''; if ($fontSources) { $fontFaceCss = "@font-face{font-family:'{$customFontName}';font-style:normal;font-weight:400;src:" . implode(',', $fontSources) . ";}"; } ?> Editor
lädt …