Re: [Zope] path of a fileupload instance

2012-11-14 Thread robert rottermann

to my knowledge, for security reason no modern browser submits the path anymore.
If you need the path, you have to create your own file uploader or use a tool 
like uploadify (http://www.uploadify.com)

I *think* javascript gets you access to the full path.

robert
On 11/14/2012 08:35 AM, Kees de Brabander wrote:

I was using IE and filename is just the file name, no directory information. So 
I will have to take another approach. Does a FileUpload instance have any other 
attributes than filename and header?

On Nov 13, 2012, at 6:11 PM, Andreas Jung wrote:


-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

This is subject to browser. All browser - except IE (afaik) - only
submit the filename without directory information.

- -aj

Kees de Brabander wrote:

Correct, but the filename attribute contains just the filename, not
the path of the directory where it was uploaded from? cb On Nov 13,
2012, at 11:04 AM, Andreas Jung wrote:

REQUEST.yourfile.filename. The FileUpload instance has a 'filename'
attributes.

-aj

Kees de Brabander wrote:

Hiya

I have a form with a field for a FileUpload object, which works
ok. However, in my application I want to capture the path of
that file, because I want to open still other files that I know
by name from that very same directory. Any idea how to do that?
The REQUEST simple contains the FileUpload instance.

___ Zope maillist
- Zope@zope.org https://mail.zope.org/mailman/listinfo/zope **
No cross posts or HTML encoding!  ** (Related lists -
https://mail.zope.org/mailman/listinfo/zope-announce
https://mail.zope.org/mailman/listinfo/zope-dev )


- -- 
ZOPYX Limited | Python | Zope | Plone | MongoDB

Hundskapfklinge 33| Consulting & Development
D-72074 Tübingen  | Electronic Publishing Solutions
www.zopyx.com | Scalable Web Solutions
- --
Produce & Publish - www.produce-and-publish.com


-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.11 (Darwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iQGUBAEBAgAGBQJQon9AAAoJEADcfz7u4AZjSwsLv0Q6WXixh/gYddZObYa1O3F4
EmhCoFjfAwgFtT8WkWpTkP4l0myjOUqPdOhJvvBxPIAtqTDPu6V6YEXM5nK1loE4
Shjz3feKRsxP784arefzD1CpRiN/YQhMSn+ZYMyy/IpHV1Ypy7vsF1HJSaCY8sqm
yaItArafhVrCrrSwGxOCaUNG83w6m0X0MlEg/phCmW3Lkz4lvwcgehEuiqHGYnrE
TwpAiBnS4ucjdgR+Zkf9sSmxKkjUiBuYenHgsHZiXwDxYaXQra1NHeCrQha1DASx
EliQuhN9Qz/A+4ZiAHj9yMwrVDEeK4oCwAxBuSsIxhO48Bj9mjXm33iSkyi0L7o7
1I0DQqCKl/1Rh6gFUmBtztzAvcz/vtB5tfjZ71u9zdQARd9zX2YKkdRQnA/l+tIG
WgwbsR/Ium2xyDp9Piqfw0rGlZzLZrp3ekbAHVwdAHR7hqGUh6nXotbJVgCOjTDz
PorJJ9CA/DZ+SWHQcQXyC8wtImS6zAI=
=aN3X
-END PGP SIGNATURE-


___
Zope maillist  -  Zope@zope.org
https://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists -
  https://mail.zope.org/mailman/listinfo/zope-announce
  https://mail.zope.org/mailman/listinfo/zope-dev )


___
Zope maillist  -  Zope@zope.org
https://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists -
https://mail.zope.org/mailman/listinfo/zope-announce
https://mail.zope.org/mailman/listinfo/zope-dev )


Re: [Zope] path of a fileupload instance

2012-11-13 Thread Kees de Brabander
I was using IE and filename is just the file name, no directory information. So 
I will have to take another approach. Does a FileUpload instance have any other 
attributes than filename and header?

On Nov 13, 2012, at 6:11 PM, Andreas Jung wrote:

> -BEGIN PGP SIGNED MESSAGE-
> Hash: SHA1
> 
> This is subject to browser. All browser - except IE (afaik) - only
> submit the filename without directory information.
> 
> - -aj
> 
> Kees de Brabander wrote:
>> Correct, but the filename attribute contains just the filename, not
>> the path of the directory where it was uploaded from? cb On Nov 13,
>> 2012, at 11:04 AM, Andreas Jung wrote:
>> 
>> REQUEST.yourfile.filename. The FileUpload instance has a 'filename'
>> attributes.
>> 
>> -aj
>> 
>> Kees de Brabander wrote:
> Hiya
> 
> I have a form with a field for a FileUpload object, which works
> ok. However, in my application I want to capture the path of
> that file, because I want to open still other files that I know
> by name from that very same directory. Any idea how to do that?
> The REQUEST simple contains the FileUpload instance.
> 
> ___ Zope maillist
> - Zope@zope.org https://mail.zope.org/mailman/listinfo/zope **
> No cross posts or HTML encoding!  ** (Related lists - 
> https://mail.zope.org/mailman/listinfo/zope-announce 
> https://mail.zope.org/mailman/listinfo/zope-dev )
>>> 
>> 
> 
> - -- 
> ZOPYX Limited | Python | Zope | Plone | MongoDB
> Hundskapfklinge 33| Consulting & Development
> D-72074 Tübingen  | Electronic Publishing Solutions
> www.zopyx.com | Scalable Web Solutions
> - --
> Produce & Publish - www.produce-and-publish.com
> 
> 
> -BEGIN PGP SIGNATURE-
> Version: GnuPG v1.4.11 (Darwin)
> Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/
> 
> iQGUBAEBAgAGBQJQon9AAAoJEADcfz7u4AZjSwsLv0Q6WXixh/gYddZObYa1O3F4
> EmhCoFjfAwgFtT8WkWpTkP4l0myjOUqPdOhJvvBxPIAtqTDPu6V6YEXM5nK1loE4
> Shjz3feKRsxP784arefzD1CpRiN/YQhMSn+ZYMyy/IpHV1Ypy7vsF1HJSaCY8sqm
> yaItArafhVrCrrSwGxOCaUNG83w6m0X0MlEg/phCmW3Lkz4lvwcgehEuiqHGYnrE
> TwpAiBnS4ucjdgR+Zkf9sSmxKkjUiBuYenHgsHZiXwDxYaXQra1NHeCrQha1DASx
> EliQuhN9Qz/A+4ZiAHj9yMwrVDEeK4oCwAxBuSsIxhO48Bj9mjXm33iSkyi0L7o7
> 1I0DQqCKl/1Rh6gFUmBtztzAvcz/vtB5tfjZ71u9zdQARd9zX2YKkdRQnA/l+tIG
> WgwbsR/Ium2xyDp9Piqfw0rGlZzLZrp3ekbAHVwdAHR7hqGUh6nXotbJVgCOjTDz
> PorJJ9CA/DZ+SWHQcQXyC8wtImS6zAI=
> =aN3X
> -END PGP SIGNATURE-
> 

___
Zope maillist  -  Zope@zope.org
https://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists -
 https://mail.zope.org/mailman/listinfo/zope-announce
 https://mail.zope.org/mailman/listinfo/zope-dev )


Re: [Zope] path of a fileupload instance

2012-11-13 Thread Andreas Jung
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

This is subject to browser. All browser - except IE (afaik) - only
submit the filename without directory information.

- -aj

Kees de Brabander wrote:
> Correct, but the filename attribute contains just the filename, not
> the path of the directory where it was uploaded from? cb On Nov 13,
> 2012, at 11:04 AM, Andreas Jung wrote:
> 
> REQUEST.yourfile.filename. The FileUpload instance has a 'filename'
> attributes.
> 
> -aj
> 
> Kees de Brabander wrote:
 Hiya
 
 I have a form with a field for a FileUpload object, which works
 ok. However, in my application I want to capture the path of
 that file, because I want to open still other files that I know
 by name from that very same directory. Any idea how to do that?
 The REQUEST simple contains the FileUpload instance.
 
 ___ Zope maillist
 - Zope@zope.org https://mail.zope.org/mailman/listinfo/zope **
 No cross posts or HTML encoding!  ** (Related lists - 
 https://mail.zope.org/mailman/listinfo/zope-announce 
 https://mail.zope.org/mailman/listinfo/zope-dev )
>> 
> 

- -- 
ZOPYX Limited | Python | Zope | Plone | MongoDB
Hundskapfklinge 33| Consulting & Development
D-72074 Tübingen  | Electronic Publishing Solutions
www.zopyx.com | Scalable Web Solutions
- --
Produce & Publish - www.produce-and-publish.com


-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.11 (Darwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iQGUBAEBAgAGBQJQon9AAAoJEADcfz7u4AZjSwsLv0Q6WXixh/gYddZObYa1O3F4
EmhCoFjfAwgFtT8WkWpTkP4l0myjOUqPdOhJvvBxPIAtqTDPu6V6YEXM5nK1loE4
Shjz3feKRsxP784arefzD1CpRiN/YQhMSn+ZYMyy/IpHV1Ypy7vsF1HJSaCY8sqm
yaItArafhVrCrrSwGxOCaUNG83w6m0X0MlEg/phCmW3Lkz4lvwcgehEuiqHGYnrE
TwpAiBnS4ucjdgR+Zkf9sSmxKkjUiBuYenHgsHZiXwDxYaXQra1NHeCrQha1DASx
EliQuhN9Qz/A+4ZiAHj9yMwrVDEeK4oCwAxBuSsIxhO48Bj9mjXm33iSkyi0L7o7
1I0DQqCKl/1Rh6gFUmBtztzAvcz/vtB5tfjZ71u9zdQARd9zX2YKkdRQnA/l+tIG
WgwbsR/Ium2xyDp9Piqfw0rGlZzLZrp3ekbAHVwdAHR7hqGUh6nXotbJVgCOjTDz
PorJJ9CA/DZ+SWHQcQXyC8wtImS6zAI=
=aN3X
-END PGP SIGNATURE-
<>___
Zope maillist  -  Zope@zope.org
https://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists -
 https://mail.zope.org/mailman/listinfo/zope-announce
 https://mail.zope.org/mailman/listinfo/zope-dev )


Re: [Zope] path of a fileupload instance

2012-11-13 Thread Kees de Brabander
Correct, but the filename attribute contains just the filename, not the path of 
the directory where it was uploaded from…
cb
On Nov 13, 2012, at 11:04 AM, Andreas Jung wrote:

> -BEGIN PGP SIGNED MESSAGE-
> Hash: SHA1
> 
> REQUEST.yourfile.filename.
> The FileUpload instance has a 'filename' attributes.
> 
> - -aj
> 
> Kees de Brabander wrote:
>> Hiya
>> 
>> I have a form with a field for a FileUpload object, which works ok.
>> However, in my application I want to capture the path of that file,
>> because I want to open still other files that I know by name from
>> that very same directory. Any idea how to do that? The REQUEST simple
>> contains the FileUpload instance.
>> 
>> ___ Zope maillist  -
>> Zope@zope.org https://mail.zope.org/mailman/listinfo/zope **   No
>> cross posts or HTML encoding!  ** (Related lists - 
>> https://mail.zope.org/mailman/listinfo/zope-announce 
>> https://mail.zope.org/mailman/listinfo/zope-dev )
> 
> - -- 
> ZOPYX Limited | Python | Zope | Plone | MongoDB
> Hundskapfklinge 33| Consulting & Development
> D-72074 Tübingen  | Electronic Publishing Solutions
> www.zopyx.com | Scalable Web Solutions
> - --
> Produce & Publish - www.produce-and-publish.com
> 
> 
> -BEGIN PGP SIGNATURE-
> Version: GnuPG v1.4.11 (Darwin)
> Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/
> 
> iQGUBAEBAgAGBQJQohsbAAoJEADcfz7u4AZjiH0Lv1x/09r2C6AakDK3H49l9jh5
> 8XvCLHBqbwKep4Ue+f8kKj3BdyDRZsg7ZkaISajndKPO2kyo1eNtBVD7v7XIhCGS
> oTKCLv7BqE5M7Or9YTkhAJR9C4yE+5EWRk7bchkh3f3w4wlFgf/cXaATnD8qm6uL
> CjmzwA3bapX39yyufaIqrifToyzvYu/BgF1g0uEf8NkxwbXP54T0b3hWaDXQZoQ2
> XdWpTKQveV4G9HH5d5koAwD8gDYLIfrTh1T32ESLtrY26qct4fYvC4UU/AgRdbV1
> TWhFNDSmYVXirHsK4odxS2tjCs0yqNAkzPsDMo82d5ZtSw0k7bqspFZrAf0vcZXA
> 6joAfyTVX5QI/RliExze4XOF6w+n/g+InV/2ErZtcN0pwk5Y2YcZTrrG8p2v3UxD
> JUpDXsDHzP5A4iQ19VI2eiwdvOXpkFMKkKxcKid7hLuccIUyc2SpygsRnhPXDbpp
> kuo+RIrcYzDs63gJD/jlaWN/BhRROu4=
> =XQX4
> -END PGP SIGNATURE-
> 

___
Zope maillist  -  Zope@zope.org
https://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists -
 https://mail.zope.org/mailman/listinfo/zope-announce
 https://mail.zope.org/mailman/listinfo/zope-dev )


Re: [Zope] path of a fileupload instance

2012-11-13 Thread Andreas Jung
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

REQUEST.yourfile.filename.
The FileUpload instance has a 'filename' attributes.

- -aj

Kees de Brabander wrote:
> Hiya
> 
> I have a form with a field for a FileUpload object, which works ok.
> However, in my application I want to capture the path of that file,
> because I want to open still other files that I know by name from
> that very same directory. Any idea how to do that? The REQUEST simple
> contains the FileUpload instance.
> 
> ___ Zope maillist  -
> Zope@zope.org https://mail.zope.org/mailman/listinfo/zope **   No
> cross posts or HTML encoding!  ** (Related lists - 
> https://mail.zope.org/mailman/listinfo/zope-announce 
> https://mail.zope.org/mailman/listinfo/zope-dev )

- -- 
ZOPYX Limited | Python | Zope | Plone | MongoDB
Hundskapfklinge 33| Consulting & Development
D-72074 Tübingen  | Electronic Publishing Solutions
www.zopyx.com | Scalable Web Solutions
- --
Produce & Publish - www.produce-and-publish.com


-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.11 (Darwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iQGUBAEBAgAGBQJQohsbAAoJEADcfz7u4AZjiH0Lv1x/09r2C6AakDK3H49l9jh5
8XvCLHBqbwKep4Ue+f8kKj3BdyDRZsg7ZkaISajndKPO2kyo1eNtBVD7v7XIhCGS
oTKCLv7BqE5M7Or9YTkhAJR9C4yE+5EWRk7bchkh3f3w4wlFgf/cXaATnD8qm6uL
CjmzwA3bapX39yyufaIqrifToyzvYu/BgF1g0uEf8NkxwbXP54T0b3hWaDXQZoQ2
XdWpTKQveV4G9HH5d5koAwD8gDYLIfrTh1T32ESLtrY26qct4fYvC4UU/AgRdbV1
TWhFNDSmYVXirHsK4odxS2tjCs0yqNAkzPsDMo82d5ZtSw0k7bqspFZrAf0vcZXA
6joAfyTVX5QI/RliExze4XOF6w+n/g+InV/2ErZtcN0pwk5Y2YcZTrrG8p2v3UxD
JUpDXsDHzP5A4iQ19VI2eiwdvOXpkFMKkKxcKid7hLuccIUyc2SpygsRnhPXDbpp
kuo+RIrcYzDs63gJD/jlaWN/BhRROu4=
=XQX4
-END PGP SIGNATURE-
<>___
Zope maillist  -  Zope@zope.org
https://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists -
 https://mail.zope.org/mailman/listinfo/zope-announce
 https://mail.zope.org/mailman/listinfo/zope-dev )


[Zope] path of a fileupload instance

2012-11-13 Thread Kees de Brabander
Hiya

I have a form with a field for a FileUpload object, which works ok. However, in 
my application I want to capture the path of that file, because I want to open 
still other files that I know by name from that very same directory.
Any idea how to do that? The REQUEST simple contains the FileUpload instance.

___
Zope maillist  -  Zope@zope.org
https://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists -
 https://mail.zope.org/mailman/listinfo/zope-announce
 https://mail.zope.org/mailman/listinfo/zope-dev )