Rick Reumann wrote:

Isn't Babu, Kosmo Kramer's mom's name?


No. You are a veddy, veddy bod mon.


Michael McGrady wrote:

Bill Siggelkow wrote:

Okay -- what you need to do is first stand on one foot ... now with your nose and your right index finger press Ctrl-Alt-F7.
Then spin around three times while singing "I am a little teapot ..."


This should solve your problem -- if it doesn't maybe you can provide more details.

babu wrote:

i've a form which has AttachmentName and URL and 3 buttons[add,update,delete]
the screen first appear as 1)for the relevant attachment name one select box will be display,user has provision to select the attachment from the select box and change the URL ,then it will added to the DB.
2) when the add button is clicked for the relevant attachmentname on textfield will be display, user has provision to enter the attachment name in the textfield and its pair in the URL textfield.again when the update button is clicked the entered value will updated into the DB.
How i do it? plz give suggestion [ i'm using struts1.1 only and not using struts-EL tags]


Sounds to me like you are trying to do a file upload, with a few extras (such as letting the user delete and rename existing files).


There are a couple areas of complication here, but nothing you can't handle if you are willing to do your homework. Start with the Struts file upload example which comes with the 1.1 distribution. Look at the JSP (the form) and the source code for the form bean and the action. FormFile is the key. Once you get a simple file upload working, the rest is just Java IO and JDBC programming.

Next, you'll need to design a database to hold your file metadata, and allocate a directory on the server box where you can begin a storage tree for uploaded files. I suggest keeping all files on the filesystem and keeping all information about the files in the database. There is the possibility of keeping the file data in the database as well, but I wouldn't consider doing that until you know you have a good reason, unless the files are very small.

I would suggest scratching out some possible method signatures such as renameFile(String oldName, String newName), renameFileByPrimaryKey(String pk, String newName), deleteFileByPrimaryKey(String pk), etc., so you'll know ahead of time what you've got to implement.

Since you also have more than one submit button, you'll need to do a little research on multiple submit buttons with Struts (and in general). There have been many threads on this topic in this list, so search the archives (www.mail-archive.com, etc.).

Hope that helps,
Erik




Is there a question here or just a request to do the coding. My apologies if there is a language barrier.



--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]




--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to