Pure PHP Upload 3 Support Product Page

Under investigation

Make file name unique is not working?

Reported 04 Apr 2013 22:23:06
1
has this problem
04 Apr 2013 22:23:06 Carl Carl posted:
Just upgraded from pur php2 and now it does not make the file name unique. It just overwrites??

Replies

Replied 05 Apr 2013 06:45:16
05 Apr 2013 06:45:16 Vulcho Vulev replied:
Hello Carl.

Our developers are investigating the problem.

Regards:Vulcho.
Replied 13 Apr 2013 21:30:03
13 Apr 2013 21:30:03 Carl Carl replied:
Any luck with this issue?
Replied 15 Apr 2013 07:52:32
15 Apr 2013 07:52:32 Vulcho Vulev replied:
Hello Carl.

I will notify you in the thread, when our developers find solution.

Regards:Vulcho.
Replied 19 Apr 2013 06:51:09
19 Apr 2013 06:51:09 Vulcho Vulev replied:
Hello Carl.

Please try the suggested workaround from Miro:



There is a workaround until a fix is available.
In Bindings Panel you should have a folder named Upload File(fileFieldName)
In that folder there is an entry named fileName.

Bind it somewhere on your page. It will look like that in the code:
<?php echo $ppu->files("fileFieldName")->fileName ?>

then find in your code the place, where your file field is passed to Inser/Update PHP code ( must be something like this:

 GetSQLValueString( $_POST["fileFieldName"], "text"));

)
and make it look like this:
 GetSQLValueString( $ppu->files("fileFieldName")->fileName, "text"));

you get the
$ppu->files("fileFieldName")->fileName

part from the bind and substitute with it the
$_POST["fileFieldName"]
part in the Insert/Update code.

Regards.

Reply to this topic