[TYPO3-dev] FAL- Add an image to a TYPO3 record (tx_news) from 3. party script
Marc Bastian Heinrichs
typo3 at mbh-web.de
Sun May 4 12:30:23 CEST 2014
Hi,
> I'm developing a third party php app for adding news records to a TYPO3
> site. The news extension is tx_news.
>
> I have a problem with the news images. They don't show on the website
> unless you edit the news record from the TYPO3 backend. When I edit the
> news record, I see the image relation, so I just edit and save, without
> making any changes.
>
> I guess its related to FAL and some kind of index problem.
Only the current master version uses FAL for the images.
> What I do is upload the images to uploads/tx_news/ and insert a record
> into tx_news_domain_model_media but obviously I need something more.
I suggest to work with the models and the NewsRepositiory.
add a object of Tx_News_Domain_Model_Media with addMedia() to your
news model object and saving the news model should do the job right.
Best
Maba
More information about the TYPO3-dev
mailing list