[ic] how to remove path from file upload when updating database

Lyn St George interchange-users@icdevgroup.org
Tue Nov 26 06:30:01 2002


On Mon, 25 Nov 2002 11:07:47 -0800 (PST), Thanh Luong wrote:

>I have a form which adds new data to a table every
>time it is submitted.  On the form there are some
><input type=file ...> everytime the "Browse" button is
>clicked the name reads C:\somedir\somefile.jpg and
>thus the database table records
>C:\somedir\somefile.jpg. I would like the database to
>record only the last portion, somefile.jpg and have
>the path removed.

As you're using this on Windows, therein  lies your problem. This kind 
of thing works flawlessly on Unix (Linux, *BSD, Solaris, even on OS/2 ...) 
but on Windows all bets are off. You'll find this comment in the faq:
" ... there are numerous anomalies and it may be difficult to get [IC on Windows] 
operating reliably". Sorry, but that's it. 

>I have managed to get the file to save the name in my
>upload directory correctly, but I cant get the table
>to save the name properly. Any suggestions on how I
>could go about doing this.
>using ic 4.8.6, mysql
>
>Thanks for any help,
>Tom
>
>
>__________________________________________________
>Do you Yahoo!?
>Yahoo! Mail Plus – Powerful. Affordable. Sign up now.
>http://mailplus.yahoo.com
>_______________________________________________
>interchange-users mailing list
>interchange-users@icdevgroup.org
>http://www.icdevgroup.org/mailman/listinfo/interchange-users
>

-
Cheers
Lyn St George
+---------------------------------------------------------------------------------
+ http://www.zolotek.net .. eCommerce hosting, consulting
+ http://www.os2docs.org .. some 'How To' stuff ...
+----------------------------------------------------------------------------------