Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change
 
PerlMonks  

Re: Re: CGI::Push Only Works With Netscape. Now What?

by sierrathedog04 (Hermit)
on Sep 20, 2001 at 01:04 UTC ( #113472=note: print w/ replies, xml ) Need Help??


in reply to Re: CGI::Push Only Works With Netscape. Now What?
in thread CGI::Push Only Works With Netscape. Now What?

Thanks for all the help, people. In order not to violate Merlyn's copyright I am not going to repost his code here, but I wonder whether perhaps his article contains a typo. Line 55 reads

"=55= my $out = IO::File->new($DIR_html,"w") or
Shouldn't this line actually be
"=55= my $out = IO::File->new($URL_html,"w") or
If someone could verify the correct code for me I would appreciate it.


Comment on Re: Re: CGI::Push Only Works With Netscape. Now What?
Re: Re: Re: CGI::Push Only Works With Netscape. Now What?
by merlyn (Sage) on Sep 20, 2001 at 02:07 UTC
    No, $URL_html is the view from the browser. You're doing a unix file open, so it needs to be the view from the Unix side, $DIR_html. That's explained in the column. You did read the column, right?

    -- Randal L. Schwartz, Perl hacker

      Yes, Merlyn, but I became confused and not as a result of anything you wrote.

      In fact, you do say in the article "URL_html contains the same name as $DIR_html, but mapped into the webserver's space so that we can redirect the client's browser to the results file."

      The lesson here is that every static web page has a dual nature. It possesses a physical path in the file system, and it possesses a URL under the http protocol.

      Clearly, it would have been a mistake for me to attempt to try to pass a URL to IO::File->new, which is what my proposed "correction" would have done.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://113472]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others lurking in the Monastery: (18)
As of 2014-10-21 17:27 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    For retirement, I am banking on:










    Results (106 votes), past polls