PDA

View Full Version : How do I upload and then display images using dataassist


bluedogconcepts357980
05-13-2009, 04:02 PM
Hi,

I am trying to set up an application to display real estate listings on my web site. I need to be able to have the user upload images to the database (mySQL - php) and then have the images displayed in the results page.

I have tried setting the field to BLOB in mySQL but then the display does not work....

Help appreciated!

Rgds John

fragop363190
05-14-2009, 01:08 AM
You never use BLOB for images your database will become very havy.
You use db to save the filename and you upload the files in a directory on your server.

I suppose you are making an "admin" section for your users. Apart of creating the whole thing by assigning users/permissions and using session to keep track who is uploading what etc (i wont go into this part) you need to use DFP2 to upload the files.

Check the Tutorials of DFP1 so you get the general idea how DFP works with DataAssist and then read DFP2 Help to see the changes in the new version.

In general you replace the Textbox of the DataAssist wizards creation (the image textbox) with a file browser using same name. You apply a DFP2 file upload behavior and progress bar and then you edit the Insert/Update transactions (depending on which page you are editing - you need to edit both by the way) and you change the assignment of the image field to the binding of WAUpload recordset instead of the form it has.
For the update page you insert a new file field/browser and hide the textbox allready created so u keep the old filename in case you dont change the image.

Hope this post was helpfull

bluedogconcepts357980
05-14-2009, 08:44 AM
Hi,

Your help much appreciated - ques - where do I find DFP1 & 2?

Looked under http://www.webassist.com/support/dataassist/ but don't see them....

Thanks!

John

Ray Borduin
05-14-2009, 09:31 AM
You need to use a product called Digital File Pro. Don't worry about v1... it is now v2.

bluedogconcepts357980
05-15-2009, 09:00 AM
Thanks for your help!

Giovanni_
06-18-2009, 02:44 PM
In some cases you DO want the images uploaded to the database.

Can this be done with dataasist?

Information: Depending what you are doing, a database stored image may be quicker to be displayed then one on the servers directories. This depends on many factors, but none the less it still a viable subject.

Ray Borduin
06-18-2009, 03:13 PM
This is not currently supported, but could be added to DataAssist if you know what you are doing in php and with manipulating blob data.

Giovanni_
06-18-2009, 10:54 PM
It would be so much help to simplify our development styles. Adding this capability would help with larger sites where images need to be stored in the database.

Thanks Ray, would be an awesome addition to dataassist.