RSS Feed/News How to pass file input into _postSave?

Status
Not open for further replies.

ENXF NET

Administrator
Staff member
Administrator
Moderator
+Lifetime VIP+
S.V.I.P.S Member
S.V.I.P Member
V.I.P Member
Collaborate
Registered
Joined
Nov 13, 2018
Messages
23,698
Points
823

Reputation:

I have an input field called 'upload':

Code:

<xf:upload name="upload" accept=".mp3" label="Upload" />

I'm accessing it in my controller like this:

Code:

$upload_file = $this->request->getFile('upload', false, false);

In my saveProcess method:

Code:

Code:
$form = $this->formAction();
$form->basicEntitySave($store, $input);

I want to be able to move the uploaded file in the _postSave method so I'm trying this:

Code:

Code:
protected function _postSave() {

$dataDir =...

Read more

Continue reading...
 
Status
Not open for further replies.
Top