Feature #29315
closedAdd hook to t3lib_div#readLLfile
0%
Description
This hook would be very useful, because there currently does not seem to be another way to modify all read locallang data.
I attached a patch with the hook I am currently using.
Files
Updated by Lucas Jenß about 13 years ago
Why would this be delayed until 4.7.0, or in other words, whats the reason to not include this in 4.6.0 ? :)
Updated by Xavier Perseguers about 13 years ago
Hi, the reason is that this is a new feature and new features are not allowed since 2nd August (feature freeze).
Updated by Ingo Renner about 13 years ago
Xavier Perseguers wrote:
Hi, the reason is that this is a new feature and new features are not allowed since 2nd August (feature freeze).
Xavier, I also see no reason to move this to 4.7. A hook doesn't really harm. We do have a policy to not introduce hooks in patch level releases, but for dev versions post feature freeze I'd argue it's no problem. :)
Updated by Xavier Perseguers about 13 years ago
Hi Ingo, OK, so let's discuss that once the hook is proposed here with a sensible use case then.
Updated by Ingo Renner about 13 years ago
Xavier Perseguers wrote:
Hi Ingo, OK, so let's discuss that once the hook is proposed here with a sensible use case then.
agreed, patch is missing of course and some use case description would be good to have, too since hooks are still "hard to maintain" in case things change...
Updated by Lucas Jenß about 13 years ago
- File t3lib_div.patch t3lib_div.patch added
Updated by Lucas Jenß about 13 years ago
Sorry, I was sure I had attached a patch.
As for the use-case:
We use the LFEditor so that copy editors may modify locallang.xml content in production systems. Also, we have recently started using "capistrano" to deploy our Typo3 websites, which causes the problem that locallang.xml changes are simply discarded, because capistrano does a clean checkout.
Our solution is, that we are writing an additional layer, in the database, in which locallang changes made on the production system are made.
In the proposed hook, we query the database and overwrite the fetched values from the locallang.xml file in case there are more recent entries in the database.
Updated by Xavier Perseguers about 13 years ago
Your patch does not apply successfully on current master (it uses fuzzy position and results in just a complete dumb location).
In addition, you are not respecting our CGL (extra spaces around parentheses, ...)
You may consider submit to Gerrit: http://wiki.typo3.org/Contribution_Walkthrough_Tutorials
Updated by Lucas Jenß about 13 years ago
Yes, I wasn't smart enough to check the current HEAD, just added the code to the latest release. Looking at the repository (https://github.com/typo3/TYPO3v4-Core/tree/master/typo3) I realized that my hook may not be the best solution considering the current development state, so I will create a new patch hooking into t3lib_l10n_factory. Should I submit that directly to Gerrit, without opening a new bug here?
Either way, this issue can probably be closed. Thanks for you help :)
Updated by Xavier Perseguers about 13 years ago
- Status changed from New to Needs Feedback
Do you still need this hook? If not, then we could close this issue.
Updated by Lucas Jenß about 13 years ago
Well, I do need the hook, but in Typo3 4.5.x where t3lib_l10n_* is not available yet (which I want to XCLASS to get the same effect). As that is probably not going to happen in 4.5.x, and in 4.6 it is completely rewritten, I guess the issue can be closed.
Updated by Xavier Perseguers about 13 years ago
- Status changed from Needs Feedback to Closed
- Priority changed from Should have to Won't have this time