Показать сообщение отдельно
Старый 16.12.2010, 11:55   #2
Андрей Аксенов
Senior Member
 
Регистрация: 12.04.2008
Адрес: Россия, Москва
Сообщений: 706
Отправить сообщение для Андрей Аксенов с помощью ICQ Отправить сообщение для Андрей Аксенов с помощью Skype™
По умолчанию

Залезаем в папку с распакованным новым ядром typo3 (у меня это typo3_src-4.4.4). Видим файл NEWS.txt - читаем. Этот файл рекомендуется читать при каждом обновлении ядра системы!
Видим:
Цитата:
* All CSS and JS files in the TYPO3 Backend are compressed now. This
means that they are added up to a single file without unnecessary
whitespace. This will reduce the count of requests drastically, which
eventually leads to faster loading and better performance.
CAUTION: If compressionLevel is configured
($TYPO3_CONF_VARS[TYPO3_MODE]['compressionLevel'] = 1 [1-9 for compression
level or TRUE for "enabled"]) the files will be served with gzip compression.
Be sure to enable / uncomment the needed configuration in your .htaccess file,
also found in misc/advanced.htaccess.

<FilesMatch "\.js\.gzip$">
AddType "text/javascript" .gzip
</FilesMatch>
<FilesMatch "\.css\.gzip$">
AddType "text/css" .gzip
</FilesMatch>
AddEncoding gzip .gzip

IMPORTANT: If you have any trouble accessing the Backend after upgrading
to TYPO3 4.4, make sure to clear the typo3temp/ directory manually or through
the TYPO3 install tool.
Что касается добавления ?1289786904 к файлам, то читаем далее:
Цитата:
* Automatic version-numbers of CSS and JS files to avoid caching problems:
This feature provides automatic numbering of CSS and JS files using the
files modified timestamp. This way the file reference will change when a
CSS or JS files is changed, and by this the browser and proxy will re-cache
the file. This feature can be configured to include the timestamp within the
filename (before .ext) or as a parameter to the file (default).
If versioning is done directly inside the filename (by setting
$TYPO3_CONF_VARS[BE][versionNumberInFilename] = TRUE) you need the
following line as the first rewrite rule in .htaccess:

# Rule for versioned static files (see $TYPO3_CONF_VARS[BE][versionNumberInFilename])
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.+)\.(\d+)\.(php|js|css|png|jpg|gif|gzip)$ $1.$3 [L]

IMPORTANT: This rule has to be the very first rule to work properly,
at least it has to be placed before the "^typo3..." rewrite rule
Developers can use this API for versioning of files in their own backend mods,
by calling t3lib_div::createVersionNumberedFilename or using the core API
for including files in the page renderer class.
Из всего этого следует, что сейчас поджимаются css и JS файлы внутреннего интерфейса.
К этим же файлам для внешнего интерфейса добавляется временной шаблон во избежание проблем с кешированием. То есть, если время сохранения файла изменилось на сервере, то и добавляемое число также меняется, при этом содержимое самого файла остается прежним. Это позволяет механизмам кеширования правильно обрабатывать измененные файлы - их название поменялось... Как-то так.

Последний раз редактировалось Андрей Аксенов; 16.12.2010 в 12:42
Андрей Аксенов вне форума   Ответить с цитированием