Feature #15564
closed
Hook Request for class.tslib_content.php
Added by Ingo Schmitt almost 19 years ago.
Updated almost 19 years ago.
Description
I like to have a hook in the method getImgResource for preprocessing the Data, e.g. to manipulate the paths to get the data from an other path.
Hook as patch-file attached
(issue imported from #M2478)
Files
Hi Ingo,
I just can't get the difference to using the "import" option of the imgResource function.
Could you please explain?
Hi Thorsten,
if you are connecting to 3rd party systems (e.g. Data Warehouse) you could not use the TS import property, as you can't use external files.
Also you could not use an external (not TYPO3 file) als file for Data in Content-Elements (witch we currently need for an project)
Hi Ingo,
using the .import TS property is in fact in no way different to what you could do using your suggested hook.
The lines following lines of getImgResource() provide you with a perfect way to generate whatever file path you like:
if ($fileArray['import.']) {
$ifile = $this->stdWrap('',$fileArray['import.']);
if ($ifile) {$file = $fileArray['import'].$ifile;}
}
Ingo wrote:
Also you could not use an external (not TYPO3 file)
Looking at the code, it seems like the same path rules apply to paths set by your hook and to paths set by .import.
cheers,
Ingmar
Ok, close this bug. Thanks for your analysing. I have to leare much more about TYPO3 :-)
Also available in: Atom
PDF