Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #53559 > unrolled thread
| Started by | Ferrous Cranus <nikos@superhost.gr> |
|---|---|
| First post | 2013-09-03 10:48 +0300 |
| Last post | 2013-09-05 12:33 -0400 |
| Articles | 5 on this page of 45 — 13 participants |
Back to article view | Back to comp.lang.python
Cannot form correctly the FORM part of the header when sending mail Ferrous Cranus <nikos@superhost.gr> - 2013-09-03 10:48 +0300
Re: Cannot form correctly the FORM part of the header when sending mail feedthetroll@gmx.de - 2013-09-03 02:33 -0700
Re: Cannot form correctly the FORM part of the header when sending mail Ferrous Cranus <nikos@superhost.gr> - 2013-09-03 13:44 +0300
Re: Cannot form correctly the FORM part of the header when sending mail Piet van Oostrum <piet@vanoostrum.org> - 2013-09-03 22:14 -0400
Re: Cannot form correctly the FORM part of the header when sending mail Ferrous Cranus <nikos.gr33k@gmail.com> - 2013-09-04 02:31 -0700
Re: Cannot form correctly the FORM part of the header when sending mail Piet van Oostrum <piet@vanoostrum.org> - 2013-09-04 12:16 -0400
Re: Cannot form correctly the FORM part of the header when sending mail Piet van Oostrum <piet@vanoostrum.org> - 2013-09-04 17:38 -0400
Re: Cannot form correctly the FORM part of the header when sending mail Ferrous Cranus <nikos@superhost.gr> - 2013-09-05 09:31 +0300
Re: Cannot form correctly the FORM part of the header when sending mail Steven D'Aprano <steve@pearwood.info> - 2013-09-05 08:58 +0000
Re: Cannot form correctly the FORM part of the header when sending mail Ferrous Cranus <nikos@superhost.gr> - 2013-09-05 12:34 +0300
Re: Cannot form correctly the FORM part of the header when sending mail Ferrous Cranus <nikos@superhost.gr> - 2013-09-05 12:36 +0300
Re: Cannot form correctly the FORM part of the header when sending mail Dave Angel <davea@davea.name> - 2013-09-05 10:33 +0000
Re: Cannot form correctly the FORM part of the header when sending mail Ferrous Cranus <nikos@superhost.gr> - 2013-09-05 13:48 +0300
Re: Cannot form correctly the FORM part of the header when sending mail feedthetroll@gmx.de - 2013-09-05 04:02 -0700
Re: Cannot form correctly the FORM part of the header when sending mail Ferrous Cranus <nikos@superhost.gr> - 2013-09-05 14:20 +0300
Re: Cannot form correctly the FORM part of the header when sending mail feedthetroll@gmx.de - 2013-09-05 05:18 -0700
Re: Cannot form correctly the FORM part of the header when sending mail Ferrous Cranus <nikos@superhost.gr> - 2013-09-05 15:36 +0300
Re: Cannot form correctly the FORM part of the header when sending mail feedthetroll@gmx.de - 2013-09-05 06:29 -0700
Re: Cannot form correctly the FORM part of the header when sending mail Ferrous Cranus <nikos@superhost.gr> - 2013-09-05 16:38 +0300
Re: Cannot form correctly the FORM part of the header when sending mail Ferrous Cranus <nikos@superhost.gr> - 2013-09-05 17:01 +0300
Re: Cannot form correctly the FORM part of the header when sending mail alex23 <wuwei23@gmail.com> - 2013-09-06 13:38 +1000
Re: Cannot form correctly the FORM part of the header when sending mail feedthetroll@gmx.de - 2013-09-05 08:00 -0700
Re: Cannot form correctly the FORM part of the header when sending mail Ferrous Cranus <nikos@superhost.gr> - 2013-09-05 18:59 +0300
Re: Cannot form correctly the FORM part of the header when sending mail feedthetroll@gmx.de - 2013-09-05 09:50 -0700
Re: Cannot form correctly the FORM part of the header when sending mail Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2013-09-05 17:50 +0000
Re: Cannot form correctly the FORM part of the header when sending mail Piet van Oostrum <piet@vanoostrum.org> - 2013-09-06 00:48 -0400
Re: Cannot form correctly the FORM part of the header when sending mail Ferrous Cranus <nikos@superhost.gr> - 2013-09-06 09:44 +0300
Re: Cannot form correctly the FORM part of the header when sending mail Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2013-09-05 17:28 +0000
Re: Cannot form correctly the FORM part of the header when sending mail Piet van Oostrum <piet@vanoostrum.org> - 2013-09-05 11:19 -0400
Re: Cannot form correctly the FORM part of the header when sending mail Ferrous Cranus <nikos.gr33k@gmail.com> - 2013-09-04 02:57 -0700
Re: Cannot form correctly the FORM part of the header when sending mail Dave Angel <davea@davea.name> - 2013-09-04 11:15 +0000
Re: Cannot form correctly the FORM part of the header when sending mail Ferrous Cranus <nikos@superhost.gr> - 2013-09-04 14:29 +0300
Re: Cannot form correctly the FORM part of the header when sending mail Dave Angel <davea@davea.name> - 2013-09-04 12:21 +0000
Re: Cannot form correctly the FORM part of the header when sending mail Piet van Oostrum <piet@vanoostrum.org> - 2013-09-04 12:22 -0400
Re: Cannot form correctly the FORM part of the header when sending mail Heiko Wundram <modelnine@modelnine.org> - 2013-09-04 14:18 +0200
Re: Cannot form correctly the FORM part of the header when sending mail Ferrous Cranus <nikos@superhost.gr> - 2013-09-04 17:29 +0300
Re: Cannot form correctly the FORM part of the header when sending mail Piet van Oostrum <piet@vanoostrum.org> - 2013-09-04 13:33 -0400
Re: Cannot form correctly the FORM part of the header when sending mail Piet van Oostrum <piet@vanoostrum.org> - 2013-09-04 12:06 -0400
How to exit a cgi file after a download Ferrous Cranus <nikos@superhost.gr> - 2013-09-04 12:49 -0400
How to exit a cgi file after a download. inq1ltd <inq1ltd@inqvista.com> - 2013-09-04 14:44 -0400
Re: How to exit a cgi file after a download. Joel Goldstick <joel.goldstick@gmail.com> - 2013-09-04 15:42 -0400
Re: How to exit a cgi file after a download. alex23 <wuwei23@gmail.com> - 2013-09-05 09:56 +1000
Re: How to exit a cgi file after a download random832@fastmail.us - 2013-09-04 16:23 -0400
Re: How to exit a cgi file after a download Benjamin Kaplan <benjamin.kaplan@case.edu> - 2013-09-04 13:51 -0700
Re: How to exit a cgi file after a download inq1ltd <inq1ltd@inqvista.com> - 2013-09-05 12:33 -0400
Page 3 of 3 — ← Prev page 1 2 [3]
| From | Joel Goldstick <joel.goldstick@gmail.com> |
|---|---|
| Date | 2013-09-04 15:42 -0400 |
| Subject | Re: How to exit a cgi file after a download. |
| Message-ID | <mailman.56.1378323756.5461.python-list@python.org> |
| In reply to | #53623 |
This same message comes up under one of Niko's many aliases. Is this
another? Why post twice?
On Wed, Sep 4, 2013 at 2:44 PM, inq1ltd <inq1ltd@inqvista.com> wrote:
> Python help.
>
> I use the following code in a cgi file
> to give the client a download link to
> download a file.
>
> ---
>
> print "%s" % ('<a href = "Setup.zip"> Down
> Load </a>')
>
> ----
>
> A click on "Down Load" opens a pop up browser
> window which allows the user to choose where
> to download the "Setup.zip" file, then after
> the download, the pop up window closes.
>
> My problem is that I want the cgi form, which
> contains the link, to also close after the
> download. The only way I can figure out to
> close the cgi window is to give the user a
> button to close it.
>
> Without closing it, the client can download
> again and forever if they choose to because
> the cgi window is open and the link is still
> active.
>
> I am trying to find a way to close the cgi
> file or call another file after the download
> without adding a close button and asking the
> client to close the window.
>
> jd
>
>
>
> --
> https://mail.python.org/mailman/listinfo/python-list
--
Joel Goldstick
http://joelgoldstick.com
[toc] | [prev] | [next] | [standalone]
| From | alex23 <wuwei23@gmail.com> |
|---|---|
| Date | 2013-09-05 09:56 +1000 |
| Subject | Re: How to exit a cgi file after a download. |
| Message-ID | <l08hb9$m84$1@dont-email.me> |
| In reply to | #53646 |
On 5/09/2013 5:42 AM, Joel Goldstick wrote: > This same message comes up under one of Niko's many aliases. Is this > another? Why post twice? Because he's a troll.
[toc] | [prev] | [next] | [standalone]
| From | random832@fastmail.us |
|---|---|
| Date | 2013-09-04 16:23 -0400 |
| Subject | Re: How to exit a cgi file after a download |
| Message-ID | <mailman.59.1378326215.5461.python-list@python.org> |
| In reply to | #53623 |
On Wed, Sep 4, 2013, at 12:49, Ferrous Cranus wrote: > Without closing it, the client can download > again and forever if they choose to because > the cgi window is open and the link is still > active. Why is this a problem? They usually won't want to, and if they do want to (for example if they accidentally canceled the download) I don't see why not to let them. The solution should be to give them a unique download link that will only work once (or only for a certain period of time), not to close the window.
[toc] | [prev] | [next] | [standalone]
| From | Benjamin Kaplan <benjamin.kaplan@case.edu> |
|---|---|
| Date | 2013-09-04 13:51 -0700 |
| Subject | Re: How to exit a cgi file after a download |
| Message-ID | <mailman.61.1378328245.5461.python-list@python.org> |
| In reply to | #53623 |
[Multipart message — attachments visible in raw view] — view raw
On Sep 4, 2013 1:29 PM, "Ferrous Cranus" <nikos@superhost.gr> wrote:
>
> Python help.
>
> I use the following code in a cgi file
> to give the client a download link to
> download a file.
>
> ---
>
> print "%s" % ('<a href = "Setup.zip"> Down
> Load </a>')
>
> ----
>
> A click on "Down Load" opens a pop up browser
> window which allows the user to choose where
> to download the "Setup.zip" file, then after
> the download, the pop up window closes.
>
> My problem is that I want the cgi form, which
> contains the link, to also close after the
> download. The only way I can figure out to
> close the cgi window is to give the user a
> button to close it.
>
> Without closing it, the client can download
> again and forever if they choose to because
> the cgi window is open and the link is still
> active.
>
> I am trying to find a way to close the cgi
> file or call another file after the download
> without adding a close button and asking the
> client to close the window.
>
> jd
>
>
There is no such thing as a "cgi form" or "cgi window". Your cgi script
runs when the user requests a Web page, generates a page, and then ends. At
that point, python has stopped running. If your want the client's browser
window to close, that's not a python problem. If you want to invalidate the
download link after one successful download, you'll have to add a unique
identifier to the url and keep track of which identifiers are still valid.
[toc] | [prev] | [next] | [standalone]
| From | inq1ltd <inq1ltd@inqvista.com> |
|---|---|
| Date | 2013-09-05 12:33 -0400 |
| Subject | Re: How to exit a cgi file after a download |
| Message-ID | <mailman.100.1378400867.5461.python-list@python.org> |
| In reply to | #53559 |
[Multipart message — attachments visible in raw view] — view raw
There is no such thing as a "cgi form" or "cgi window". Your cgi script runs when the user requests a Web page, generates a page, and then ends. At that point, python has stopped running. If your want the client's browser window to close, that's not a python problem. If you want to invalidate the download link after one successful download, you'll have to add a unique identifier to the url and keep track of which identifiers are still valid. Thanks for responding, Technically cgi is a script. But a form is what a cgi script file can create. The form I asked about is html, it was generated by a cgi script file. So I should have written; a cgi script file generated html form, or a cgi script file generated html window. Lazy writing. My mistake. However I asked a question which now is mute. Once the user downloads the data the user can copy it, so why limit the download?. I appreciate the response, jd inqvista.com
[toc] | [prev] | [standalone]
Page 3 of 3 — ← Prev page 1 2 [3]
Back to top | Article view | comp.lang.python
csiph-web