This topic is locked

Unique Stamp ID for an uploaded file !

8/27/2010 2:59:50 PM
PHPRunner General questions
N
netmedia59 author

Hello,
Is there a way to stamp an uploaded file with another stamp than the datetime, for example, a User ID ...

Thanks
Olivier
Lille (FRANCE)

romaldus 8/27/2010



Hello,
Is there a way to stamp an uploaded file with another stamp than the datetime, for example, a User ID ...

Thanks
Olivier
Lille (FRANCE)



read this post:

http://www.asprunner.com/forums/topic/15019-import-data-from-excel-and-insert-default-value/

N
netmedia59 author 8/28/2010

Hey Romaldus,
Thanks, that's usefull to import spreasheets, but that's not exactly what i needed.

What I need is to have an unique ID when a user add a picture or a file, and not the standard DateTime ID but a userID (for example) ath the begining of the imported picture or file (doc, xls, ...)

Don't know if it's clear enough ?

Thanks again
Olivier

Lille (FRANCE)



read this post:

http://www.asprunner.com/forums/topic/15019-import-data-from-excel-and-insert-default-value/

A
ann 8/30/2010

Hi,
to rename uploaded files based on ID field use the sample:

http://xlinesoft.com/phprunner/docs/rename_uploaded_file.htm

N
netmedia59 author 8/30/2010

Hey Ann,
Thanks

What if it's not a picture ? (for example a .doc, .pdf, ...)

And in fact, it doesn't seem to work very well.

It changes the uploaded filename, but not the uploaded file ?

Thanks again
Olivier



Hi,
to rename uploaded files based on ID field use the sample:

http://xlinesoft.com/phprunner/docs/rename_uploaded_file.htm

A
ann 8/31/2010

Olivier,
here is a sample code for an arbitrary extension:

$filename = $values["FieldName"];

$exttype=strtoupper(substr($filename,strlen($filename)-4));

...

$files_move[$key][1] = "files_folder/".$values["ID"].".".$exttype;


Editing the file directly requires a lot of custom coding in the generated files. Unfortunately we don't have a ready to go solution for this.