On 2004.8.26, at 04:45 AM, Bill Stephenson wrote:
On Aug 25, 2004, at 10:59 AM, Mark Wheeler wrote:
Hi Joel,
Thanks for your input. In regards to filename, I'm assuming you are
talking about the filename passed within the HTML, right? I think
what I will probably do is pass an ID number to the sc
Thanks for your input. In regards to filename, I'm assuming you are
talking about the filename passed within the HTML, right?
If I know what you meant be that, I'd be more able to say.
So I'll dodge and try explaining it this way: Any script that could
potentially be called by someone typing it
On Aug 25, 2004, at 10:59 AM, Mark Wheeler wrote:
Hi Joel,
Thanks for your input. In regards to filename, I'm assuming you are
talking about the filename passed within the HTML, right? I think what
I will probably do is pass an ID number to the script and then process
it that way. I will still c
On Aug 25, 2004, at 10:59 AM, Mark Wheeler wrote:
Hi Joel,
Thanks for your input. In regards to filename, I'm assuming you are
talking about the filename passed within the HTML, right? I think what
I will probably do is pass an ID number to the script and then process
it that way. I will still c
Hi Andy,
I'll give it a try and let you know. I just tried the current version
of the script (the one that IE Mac has a problem with) on a PC and it
works great. So it seems to just be IE Mac. So I'll try the new thing
and let you know.
Thanks,
Mark
On Aug 25, 2004, at 5:47 AM, Andrew Mace w
Hi Joel,
Thanks for your input. In regards to filename, I'm assuming you are
talking about the filename passed within the HTML, right? I think what
I will probably do is pass an ID number to the script and then process
it that way. I will still check for "../" andywhere the passed ID, as
we
Just a few nosy comments --
Untitled Page
picture link
Not sure why you want to bother with javascript in there. ICBW, but I
don't think it buys you anything. And some of your family may decide to
turn javascript in their browsers off.
Andrew Mace wrote:
IE just displays the graphic but doesn't download it. The script
does not seem to be overriding whatever the settings are in IE
regarding MIME types and what to do with them -- I'm guessing. Is
there a way to override that?
You could try changing the Content-Type to appli
IE just displays the graphic but doesn't download it. The script does
not seem to be overriding whatever the settings are in IE regarding
MIME types and what to do with them -- I'm guessing. Is there a way to
override that?
You could try changing the Content-Type to application/download. Th
Hi Andy,
Yup, that was it. I was using a relative path, not abslute. That fixed
it. I script now works great in Netscape and Safari, but not in IE.
(All on a Mac - I'll check out the PC tomorrow). IE just displays the
graphic but doesn't download it. The script does not seem to be
overridin
$path is a system path, right? As in, like, not relative to the
webserver? Just making sure...
Also, I messed up and used $length in one place and $size in another,
though that doesn't explain your troubles.
I mean, you could do a lot of things to debug. A quick thing you could
do would
Hi Chris,
I'm not at home (where the server is) so I'll give that a try, too. The
drawback on this method would be that I would only be able to use it on
a server that I had access to the Apache config file. This works well
at home, but not so well with a paid outside hosting service. But I'm
g
Hi Andy (another andy),
I tried your changes, but not go. On a PC, a 0k file is saved. On a
Mac, the browser (Safari 1.2.2) gives me a blank screen with nothing
d/l or a save dialog box - nothing. Any ideas?
Thanks,
Mark
On Aug 24, 2004, at 4:10 PM, Andy Turner wrote:
I would also recommend us
Hi Andy,
Thanks for the input. I should have check the "read/write" method -- my
bad.
I tried both the slurp and the read methods, but the same thing still
happens. On a PC the save dialog comes up but the file saved is 0k, and
on a Mac, the the progress bar is just a spinning barber poll. A
On Tue, 24 Aug 2004, Andy Turner wrote:
I would agree that slurping the entire file is a bad idea.
This whole project is, in hindsight, a bad idea.
This can be done more safely & easily in the Apache config.
Assume that the image tree lives in /Library/WebServer/Documents/photos,
and is ordinarily
I would also recommend using PATH_INFO instead of a query string. This will
more reliably set the filename then the content disposition will.
The HTML would be:
Untitled Page
picture
link
I would agree that slurping the entire file is a bad idea. However you
don't need to use read. You
Hey Mark -
A few things.
- You want to open the file for reading, not to write.
- You should undef $/ to slurp the file if you're using < > to read.
- You should stat the file before opening it to add the Content-Length
header, if you want.
- For larger files, it would make more sense to use read
Hi all,
Here is my first attempt to write this script. I will be adding the
protection/whitelisting/etc. after I get the basic this running. Here
is what I have so far, and here is what happens. On a PC, the dialog
box comes up and saves the file, but it is 0K -- nothing in it. On a
Mac, th
On Mon, 23 Aug 2004, william ross wrote:
On 23 Aug 2004, at 12:14, Chris Devers wrote:
On Mon, 23 Aug 2004, william ross wrote:
This will mean that jpegs in that directory can't ever be used on pages
-- which would kind of ruin the fun.
There seems to be an easy workaround though: symlink ~/Sites/
On 23 Aug 2004, at 12:14, Chris Devers wrote:
On Mon, 23 Aug 2004, william ross wrote:
This will mean that jpegs in that directory can't ever be used on
pages
-- which would kind of ruin the fun.
There seems to be an easy workaround though: symlink ~/Sites/images
(or whatever it is) to something
On 23 Aug 2004, at 18:49, Morbus Iff wrote:
>Perhaps set the path of the image directory
>into the script, hardcoded like so:
>
> $path = '/home/fubar/www/images';
>
>or something like that so you are restricting to a certain directory,
>and not just letting any file be read in by the cgi and sen
I think that's what I'm looking for. One question. What do you mean
"whitelist" the filepaths". My only reference point is email.
"Whitelist" for me means that email address on my "whitelist" always
get through, even though the spam software might initially think it's
spam. Can you clarify?
If
Morbus Iff wrote:
>Perhaps set the path of the image directory
>into the script, hardcoded like so:
>
> $path = '/home/fubar/www/images';
>
>or something like that so you are restricting to a certain directory,
>and not just letting any file be read in by the cgi and sent to the
This isn't
>Perhaps set the path of the image directory
>into the script, hardcoded like so:
>
> $path = '/home/fubar/www/images';
>
>or something like that so you are restricting to a certain directory,
>and not just letting any file be read in by the cgi and sent to the
This isn't safe either. Someone cou
Mark Wheeler wrote:
Hi William,
I think that's what I'm looking for. One question. What do you mean
"whitelist" the filepaths". My only reference point is email.
"Whitelist" for me means that email address on my "whitelist" always get
through, even though the spam software might initially think
Hi Pete,
I'll keep that in mind. Gotta love IE...
Mark
On Aug 23, 2004, at 6:58 AM, Pete Prodoehl wrote:
william ross wrote:
On 21 Aug 2004, at 20:07, Chris Devers wrote:
On Sat, 21 Aug 2004, Mark Wheeler wrote:
This is untested, but I'm guessing that you could write a simple CGI
script that takes
Hi William,
I think that's what I'm looking for. One question. What do you mean
"whitelist" the filepaths". My only reference point is email.
"Whitelist" for me means that email address on my "whitelist" always
get through, even though the spam software might initially think it's
spam. Can you
william ross wrote:
On 21 Aug 2004, at 20:07, Chris Devers wrote:
On Sat, 21 Aug 2004, Mark Wheeler wrote:
This is untested, but I'm guessing that you could write a simple CGI
script that takes the URL for an image as an argument -- maybe just
using $ENV{'HTTP_QUERY_STRING'} so that the url can b
On Mon, 23 Aug 2004, william ross wrote:
No need. On apache, at least, you can change the mime-type in an
.htaccess file. Assuming the AllowOverride settings permit it, which
they normally would:
AddType application/octet-stream jpg
should do it.
Ok, that's much more clever than I was th
On 21 Aug 2004, at 20:07, Chris Devers wrote:
On Sat, 21 Aug 2004, Mark Wheeler wrote:
I have a picture gallery I building for my family. When a movie or
picture is displayed, I want them to be able to save it. But... if I
just provide a link in the coding to the actual file, it will open up
in
Thanks. I'll check it out.
Mark
On Aug 21, 2004, at 4:17 PM, Joel Rees wrote:
http://reiisi.homedns.org/~joel/cs/shared_code/showpics.pl.text
Thinking twice, I'll be out of pocket for a while, so I'll just go
ahead and post this just in case anyone is interested.
http://reiisi.homedns.org/~joel/cs/shared_code/showpics.pl.text
Contains some shift-jis, which can be stripped out with no ill effects.
--
Joel Rees
It's not the "Here
On 2004.8.22, at 04:07 AM, Chris Devers wrote:
On Sat, 21 Aug 2004, Mark Wheeler wrote:
I have a picture gallery I building for my family. When a movie or
picture is displayed, I want them to be able to save it. But... if I
just provide a link in the coding to the actual file, it will open up
in
Hi Bill,
That's pretty much what Chris said, too. I'll give it a try and let you
know.
On Aug 21, 2004, at 11:27 AM, Bill Stephenson wrote:
Hey Mark,
I sympathize with you, it should be easy to ask them just to "right
click", or "control click" but most of my family just doesn't grasp the
conce
Hi Chris,
That makes sense. I'll give it a try and let you know.
Thanks,
Mark
On Aug 21, 2004, at 12:07 PM, Chris Devers wrote:
On Sat, 21 Aug 2004, Mark Wheeler wrote:
I have a picture gallery I building for my family. When a movie or
picture is displayed, I want them to be able to save it. But..
On Sat, 21 Aug 2004, Mark Wheeler wrote:
I have a picture gallery I building for my family. When a movie or
picture is displayed, I want them to be able to save it. But... if I
just provide a link in the coding to the actual file, it will open up
in the browser window and be displayed. Is there
Hey Mark,
I sympathize with you, it should be easy to ask them just to "right
click", or "control click" but most of my family just doesn't grasp the
concept any better than I do the GameCube keypad commands my son tells
me to use when he's whupping me on a Football game.
I think if you filter
Hi,
I have a picture gallery I building for my family. When a movie or
picture is displayed, I want them to be able to save it. But... if I
just provide a link in the coding to the actual file, it will open up
in the browser window and be displayed. Is there a way to have
download, either autom
38 matches
Mail list logo