[FLOW3-general] Resource does not get published

Alexander Dick typo3 at dick.at
Mon Dec 17 10:57:22 CET 2012


Does noone have an idea what the problem could be?

Am 14.12.2012 09:29, schrieb Alexander Dick:
> Hi guys,
>
> I'm developing my first FLOW application at the moment and I'm a bit
> stuck with the file upload.
>
> At the moment it is a simple form with some fields to create a "Part"
> object, this object also has an image.
>
> <f:form method="post" action="create" name="newPart"
> enctype="multipart/form-data">
>
> <f:form.textfield property="title" />
> .
> .
> .
>
> <f:form.uploadproperty="image.originalResource" />
>
> </f:form>
>
> The image is a "PartImage"
>
> class Part {
>
> /**
> * @var \My\Package\Domain\Model\PartImage
> * @ORM\OneToOne(cascade="persist")
> */
> protected $image;
>
> it also has the required $originalResource property and the correspondig
> setter & getter:
>
> class PartImage {
>
> /**
> * The original resource
> * @var \TYPO3\FLOW3\Resource\Resource
> * @ORM\OneToOne
> */
> protected $originalResource;
>
>
> The resource gets uploaded correctly and the object is persisted
> correctly, I can access the resource via {part.image.originalResource}.
>
> But I'm unable to render the resource in the frontend.
> Shouldnt {f:uri.resource(path: part.image.originalResource)} publishh
> the resource at the first call? It only outputs this path:
> /_Resources/Static/Packages/My.Package/d997e1c37edc05ad87d03603e32ad495ee2cfce1
>
>
> while the actual file resides in /Data/Persistent/Resources/
>
> I hope somebody can help me out with this.
> Flow version: 1.1.0
>
> Kind regards
> Alex



More information about the FLOW3-general mailing list