close ad
Databridge V2 with MySQLi support IS Now Available!
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues


Rename uploaded file with local date - time

Thread began 5/20/2015 5:41 am by Paul | Last modified 5/20/2015 1:37 pm by Ray Borduin | 633 views | 2 replies |

PaulBeta Tester

Rename uploaded file with local date - time

In process of using DA to build an file upload page.
I'm renaming the file with the registered users credential and i would like to include the date time at the end and before the image extension.

Following is a snip from my upload page - everything works apart from the date/time printing.

// WA_UploadResult1 Params Start
$WA_UploadResult1_Params = array();
// WA_UploadResult1_1 Start
$WA_UploadResult1_Params["WA_UploadResult1_1"] = array(
'UploadFolder' => "photos/".$row_rsGetUser['UserLastName'] ."_".$_SESSION['SecurityAssist_UserID'] ."",
'FileName' => "".$row_rsGetUser['UserLastName'] ."_".$_SESSION['SecurityAssist_UserID'] ."_<? php echo date(\"d-m-Y h:i:sa\"); ?>",

Can any point me in right direction please?

Thanks, Paul.

Sign in to reply to this post

PaulBeta Tester

Ok, so here's my solution;

Replaced <? php echo date(\"d-m-Y h:i:sa\"); ?>

With <?php echo date("l_F_d_Y_h:i_A"); ?>

Works fine - albeit takes server time and not local, but it provides a unique ref.

Anyone with a local time version, please post reply to this.

Sign in to reply to this post

Ray BorduinWebAssist

You could put the local time into a hidden form element and then use the posted form element in the file name.

Sign in to reply to this post

Build websites with a little help from your friends

Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.

Build websites from already-built web applications

These out-of-the-box solutions provide you proven, tested applications that can be up and running now.  Build a store, a gallery, or a web-based email solution.

Want your website pre-built and hosted?

Close Windowclose

Rate your experience or provide feedback on this page

Account or customer service questions?
Please user our contact form.

Need technical support?
Please visit support to ask a question





Ease of use


security code refresh image

We do not respond to comments submitted from this page directly, but we do read and analyze any feedback and will use it to help make your experience better in the future.

Close Windowclose

We were unable to retrieve the attached file

Close Windowclose

Attach and remove files

add attachmentAdd attachment
Close Windowclose

Enter the URL you would like to link to in your post

Close Windowclose

This is how you use right click RTF editing

Enable right click RTF editing option allows you to add html markup into your tutorial such as images, bulleted lists, files and more...

-- click to close --

Uploading file...