Dreamweaver Developer Toolkit File Upload

Experts,

I have created a form using the Dreamweaver Developers Toolkit that will upload a file and insert a new record in a data table (PHP) .  One of the settings in the dialog box is to add the path for the uploaded files.  No problem with any of this, but I need to add the path to the file name during the insert so that the field in the database will accurately reflect the current location of the file.  It currently only inserts the file name.  Since this is a Dreamweaver extension and I am not a really good PHP coder, I don't really know what code to upload so if anyone has experience with the toolkit and has tackled this, I would be grateful for some help.
Quantum_LeaperAsked:
Who is Participating?
 
Jason C. LevineNo oneCommented:
Hi Quantum_Leaper,

Before we go any further:

http://www.adobe.com/products/dreamweaver/addt/

The ADDT is being discontinued, so support for it will be drying up.

>> No problem with any of this, but I need to add the path to the file name during the insert so that the field in the
>> database will accurately reflect the current location of the file.

Why?  If the path is static, you can easily build links without having to store the path in the table.  Also, the ADDT makes this extremely hard to do.
0
 
Quantum_LeaperAuthor Commented:
jason178

Thanks for the feedback on the ADDT.  

I think I get what you mean on the path.  I just added that to the image name variable selected from the database.  That was a good suggestion and certainly changed the way I will do these in the future.  As  right-brainier I don't often climb into the code but this was an easy fix. Thanks for the fresh perspective.

0
 
Jason C. LevineNo oneCommented:
>> Thanks for the fresh perspective.

You're welcome.  FWIW, if you use "plain" PHP to handle file uploads, the path becomes immediately available as a variable in the $_FILES array.  But the ADDT adds a layer of complexity to what is otherwise a simple task and trying to extract the path becomes overly complicated.
0
 
Quantum_LeaperAuthor Commented:
jason1178:

Thanks for the additional information.  I will read up on the $_FILES array and learn how to use that for future forms.
0
 
Jason C. LevineNo oneCommented:
>> I will read up on the $_FILES array and learn how to use that for future forms.

Actually, I'm wrong.  You set the path manually in the PHP code even with plain vanilla upload scripts.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.