[TYPO3-core] RFC #13998: Introduce Automatic versioning of CSS and JS files

Lars Houmark lars at houmark.com
Wed Apr 7 08:45:07 CEST 2010


Hi Georg,

> - why not shipping/modifing the .htaccess with the patch, as there are
> already some htacceess files in typo3/

Well, this patch is intended to be able to run in the frontend as well. 
I thought about having the same rule in the /typo3 .htaccess also, but 
goit away from it. Sure we should add it there.

> - CGL: comments are intended one addtional tab

In t3liv_div, the function above is using same indention, which is one 
tab and one space afterwards. Is this wrong?

> - code
> -------------------------------------
> +			if ($lookupFile[1]) {
> +				$separator = '&';
> +			} else {
> +				$separator = '?';
> +			}
> -------------------------------------
> could be just a $seperator = ($lookupFile[1]) ? '&' : '?';
> IMO this is also faster

Maybe I did not understand the benchmarking of Jigal correctly, but 
else will be the most common situation in this statement, and according 
to him that is slower than having a normal if / else. I will keep it 
like this for now, unless someone thinks it should be changed. I also 
like ternary more myself so... :)

> - $fullName .= $lookupFile[1] ? '?'. $lookupFile[1] : '';
>                                   ^^^ missing a space

Not in my end.

> - useInfileVersionNumbering => wouldn't be a fileVersionNumbering or
> versionNumberedFiles be better?

"useInFile" is to make the function include the name inside the 
filename, before the extension. If it is false, it will failover to 
append it in the query-string, so I guess the naming could be 
misunderstood with your proposals. Anyways, I am open to ideas 
regarding configuration. Currently there is no configuration for 
disabling this feature completely from BE or FE - though FE will 
currently not call the function in the pagerenderer. I guess when this 
is changed, the configuration will change with it.

> sorry for the nitpicking

Not a problem, thanks for feedback :)

-- 
Lars Houmark



More information about the TYPO3-team-core mailing list