Re: [WebDNA] Write uploaded file with same name

This WebDNA talk-list message is from

2020


It keeps the original formatting.
numero = 115070
interpreted = N
texte = 2699 --Apple-Mail=_263CB01D-BE2A-461A-8665-6414ED94E716 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=us-ascii Hi Ken I have stripped this out of a working file. [FORMVARIABLES name=3D_FILEUPLOAD&exact=3DF][!] [/!][HIDEIF [URL][value][/URL]=3D][!] ------------------------------------ [/!][SHOWIF [url][name][/url]^[url]filename=3D"[/url]][!] [/!][TEXT]FULLFILENAME=3D[MIDDLE = StartAfter=3Dfilename=3D"&endbefore=3D"][name][/MIDDLE][/TEXT][!] -------------- write the file to upload dir = -------------- [/!][HIDEIF [FULLFILENAME]=3D][!] [/!][WRITEFILE = secure=3DF&file=3D[SHORTPATH]/[CompanyID]/[THISFILENAME]][value][/WRITEFIL= E][!] [/!][/HIDEIF][!] [/!][/SHOWIF][!] ------------------------------------ [/!][/HIDEIF][!] [/!][/FORMVARIABLES] However because people do put all sorts of characters in file names I = always clean the name before using it. Kind regards Stuart Tremain Pharoah Lane Software AUSTRALIA webdna@plsoftware.com.au > On 26 Mar 2020, at 09:43, talk@webdna.us wrote: >=20 > My client is uploading a file via http. How do I write the > file on my server with the same name as on the client's > computer? >=20 > In other words, is there a reliable way to extract the > original file name from the uploaded data? >=20 > Regards, > Kenneth Grome > WebDNA Solutions > http://www.webdnasolutions.com > Urgent/Emergency Phone: (228) 222-2917 > Website, Database, Network, and Communication Systems >=20 >=20 >=20 > --------------------------------------------------------- > This message is sent to you because you are subscribed to > the mailing list talk@webdna.us > To unsubscribe, E-mail to: talk-leave@webdna.us > archives: http://www.webdna.us/page.dna?numero=3D55 > Bug Reporting: support@webdna.us --Apple-Mail=_263CB01D-BE2A-461A-8665-6414ED94E716 Content-Transfer-Encoding: quoted-printable Content-Type: text/html; charset=us-ascii Hi = Ken

I have stripped = this out of a working file.

[FORMVARIABLES = name=3D_FILEUPLOAD&exact=3DF][!]
= [/!][HIDEIF [URL][value][/URL]=3D][!]
= ------------------------------------
= [/!][SHOWIF [url][name][/url]^[url]filename=3D"[/url]][!]
= [/!][TEXT]FULLFILENAME=3D[MIDDLE = StartAfter=3Dfilename=3D"&endbefore=3D"][name][/MIDDLE][/TEXT][!]
= -------------- write the file to upload = dir --------------
[/!][HIDEIF = [FULLFILENAME]=3D][!]
= [/!][WRITEFILE = secure=3DF&file=3D[SHORTPATH]/[CompanyID]/[THISFILENAME]][value][/WRIT= EFILE][!]
= [/!][/HIDEIF][!]
= [/!][/SHOWIF][!]
= ------------------------------------
= [/!][/HIDEIF][!]
[/!][/FORMVARIABLES]

However because people do put all sorts = of characters in file names I always clean the name before using = it.




Kind regards

Stuart Tremain
Pharoah Lane Software
AUSTRALIA







On 26 Mar 2020, at 09:43, talk@webdna.us wrote:

My = client is uploading a file via http. How do I write the
file= on my server with the same name as on the client's
computer?

In other words, is = there a reliable way to extract the
original file name = from the uploaded data?

Regards,
Kenneth Grome
WebDNA Solutions
http://www.webdnasolutions.com
Urgent/Emergency Phone: (228) 222-2917
Website, = Database, Network, and Communication Systems



---------------------------------------------------------
This message is sent to you because you are subscribed to
the mailing list talk@webdna.us
To unsubscribe, = E-mail to: talk-leave@webdna.us
archives: = http://www.webdna.us/page.dna?numero=3D55
Bug Reporting: = support@webdna.us

= --------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list talk@webdna.us To unsubscribe, E-mail to: talk-leave@webdna.us archives: http://www.webdna.us/page.dna?numero=3D55 Bug Reporting: support@webdna.us --Apple-Mail=_263CB01D-BE2A-461A-8665-6414ED94E716-- . Associated Messages, from the most recent to the oldest:

    
  1. Re: [WebDNA] Write uploaded file with same name (Stuart Tremain 2020)
  2. Re: [WebDNA] Write uploaded file with same name (Michael Davis 2020)
  3. Re: [WebDNA] Write uploaded file with same name (Stuart Tremain 2020)
  4. [WebDNA] Write uploaded file with same name (WebDNA Solutions 2020)
2699 --Apple-Mail=_263CB01D-BE2A-461A-8665-6414ED94E716 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=us-ascii Hi Ken I have stripped this out of a working file. [FORMVARIABLES name=3D_FILEUPLOAD&exact=3DF][!] [/!][HIDEIF [url][value][/URL]=3D][!] ------------------------------------ [/!][SHOWIF [url][name][/url]^[url]filename=3D"[/url]][!] [/!][text]FULLFILENAME=3D[MIDDLE = StartAfter=3Dfilename=3D"&endbefore=3D"][name][/MIDDLE][/TEXT][!] -------------- write the file to upload dir = -------------- [/!][HIDEIF [FULLFILENAME]=3D][!] [/!][WRITEFILE = secure=3DF&file=3D[SHORTPATH]/[CompanyID]/[THISFILENAME]][value][/WRITEFIL= E][!] [/!][/HIDEIF][!] [/!][/SHOWIF][!] ------------------------------------ [/!][/HIDEIF][!] [/!][/FORMVARIABLES] However because people do put all sorts of characters in file names I = always clean the name before using it. Kind regards Stuart Tremain Pharoah Lane Software AUSTRALIA webdna@plsoftware.com.au > On 26 Mar 2020, at 09:43, talk@webdna.us wrote: >=20 > My client is uploading a file via http. How do I write the > file on my server with the same name as on the client's > computer? >=20 > In other words, is there a reliable way to extract the > original file name from the uploaded data? >=20 > Regards, > Kenneth Grome > WebDNA Solutions > http://www.webdnasolutions.com > Urgent/Emergency Phone: (228) 222-2917 > Website, Database, Network, and Communication Systems >=20 >=20 >=20 > --------------------------------------------------------- > This message is sent to you because you are subscribed to > the mailing list talk@webdna.us > To unsubscribe, E-mail to: talk-leave@webdna.us > archives: http://www.webdna.us/page.dna?numero=3D55 > Bug Reporting: support@webdna.us --Apple-Mail=_263CB01D-BE2A-461A-8665-6414ED94E716 Content-Transfer-Encoding: quoted-printable Content-Type: text/html; charset=us-ascii Hi = Ken

I have stripped = this out of a working file.

[FORMVARIABLES = name=3D_FILEUPLOAD&exact=3DF][!]
= [/!][HIDEIF [url][value][/URL]=3D][!]
= ------------------------------------
= [/!][SHOWIF [url][name][/url]^[url]filename=3D"[/url]][!]
= [/!][text]FULLFILENAME=3D[MIDDLE = StartAfter=3Dfilename=3D"&endbefore=3D"][name][/MIDDLE][/TEXT][!]
= -------------- write the file to upload = dir --------------
[/!][HIDEIF = [FULLFILENAME]=3D][!]
= [/!][WRITEFILE = secure=3DF&file=3D[SHORTPATH]/[CompanyID]/[THISFILENAME]][value][/WRIT= EFILE][!]
= [/!][/HIDEIF][!]
= [/!][/SHOWIF][!]
= ------------------------------------
= [/!][/HIDEIF][!]
[/!][/FORMVARIABLES]

However because people do put all sorts = of characters in file names I always clean the name before using = it.




Kind regards

Stuart Tremain
Pharoah Lane Software
AUSTRALIA







On 26 Mar 2020, at 09:43, talk@webdna.us wrote:

My = client is uploading a file via http. How do I write the
file= on my server with the same name as on the client's
computer?

In other words, is = there a reliable way to extract the
original file name = from the uploaded data?

Regards,
Kenneth Grome
WebDNA Solutions
http://www.webdnasolutions.com
Urgent/Emergency Phone: (228) 222-2917
Website, = Database, Network, and Communication Systems



---------------------------------------------------------
This message is sent to you because you are subscribed to
the mailing list talk@webdna.us
To unsubscribe, = E-mail to: talk-leave@webdna.us
archives: = http://www.webdna.us/page.dna?numero=3D55
Bug Reporting: = support@webdna.us

= --------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list talk@webdna.us To unsubscribe, E-mail to: talk-leave@webdna.us archives: http://www.webdna.us/page.dna?numero=3D55 Bug Reporting: support@webdna.us --Apple-Mail=_263CB01D-BE2A-461A-8665-6414ED94E716-- . Stuart Tremain

DOWNLOAD WEBDNA NOW!

Top Articles:

Talk List

The WebDNA community talk-list is the best place to get some help: several hundred extremely proficient programmers with an excellent knowledge of WebDNA and an excellent spirit will deliver all the tips and tricks you can imagine...

Related Readings:

WC2.0 Memory Requirements (1997) Re[2]: 2nd WebCatalog2 Feature Request (1996) WCS Newbie question (1997) price totals (2003) $purchase WITHOUT creditcar (1997) Plugin or CGI or both (1997) 2.0 Info (1997) WebCatalog for guestbook ? (1997) [WebDNA] How to stop cutting a word (2008) [WebDNA] Ubuntu 18.04.2 ??? (2019) WebCatalog Mac 2.1b3 (1997) Cart passing in URL... (2004) PCS Emailer's role ? (1997) problems with 2 tags (1997) 2nd WebCatalog2 Feature Request (1996) Hyperboard/bulletin board available (1998) [isfile] ? (1997) WebCat2b13 Mac plugin - [sendmail] and checkboxes (1997) [LOOKUP] (1997) Email Line Breaks (2003)