не знаю что

This commit is contained in:
2024-07-24 10:05:45 +05:00
parent d9e5677a8c
commit 5cca3481c4
11 changed files with 42 additions and 55 deletions

View File

@ -38,7 +38,8 @@
},
"autoload": {
"classmap": ["mpdf.php", "classes"]
"classmap": [
"mpdf.php", "classes"]
},
"scripts": {

View File

@ -1,2 +1,2 @@
*
.gitignore
!.gitignore

View File

@ -1,2 +1,2 @@
*
.gitignore
!.gitignore

View File

@ -1,2 +1,2 @@
*
.gitignore
!.gitignore

View File

@ -1,11 +1,16 @@
<?php
// Из файла file.js делаем file_v123456789.js добавив время
function getScript($path)
function getScript($path,$pathURL="")
{
if (file_exists($_SERVER['DOCUMENT_ROOT'].$path))
{
return '<script src="'.beforeLast($path,'.').'_v'.filectime($_SERVER['DOCUMENT_ROOT'].$path).'.'.afterLast($path,'.').'"></script>'."\n";
if($pathURL!="")
{
return '<script src="' . $pathURL.'?v='.filectime($_SERVER['DOCUMENT_ROOT'] . $path). '"></script>' . "\n";
}else {
return '<script src="' . beforeLast($path, '.') . '_v' . filectime($_SERVER['DOCUMENT_ROOT'] . $path) . '.' . afterLast($path, '.') . '"></script>' . "\n";
}
}
return '';
}

View File

@ -61,6 +61,8 @@
*/
function findFirstNode($node, $nodename)
{
if($node==null) return null;
$mas=array();
$pos=0;
$mas[$pos] = $node->firstChild;