Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

Re^7: Http connection manipulations

by flexvault (Monsignor)
on Jan 14, 2012 at 10:51 UTC ( [id://947886]=note: print w/replies, xml ) Need Help??


in reply to Re^6: Http connection manipulations
in thread Http connection manipulations

Since the client is connected to you on 'port:15000', you could return the "where to go" by using the following in your code:

. . . my $where = "..."; ## $where is the URL of the new destinat +ion print "Content-type: text/html\r\n\r\n"; print '<HTML>'; print '<HEAD>'; print '<META HTTP-EQUIV="Refresh" CONTENT="0; URL=http://' . $wh +ere . '">'; print '</HEAD>'; print "</HTML>";

What the code does, is tell the clients browser to redirect to the new URL. You need to initialize '$where' with the new destination

Good Luck

"Well done is better than well said." - Benjamin Franklin

Replies are listed 'Best First'.
Re^8: Http connection manipulations
by kazak (Beadle) on Jan 14, 2012 at 22:47 UTC
    I've decided to change approach a bit because sometimes it'll be easier to write something new then to fix an old one so could you to refer to a new node for more details:

    http://www.perlmonks.org/?node_id=947916

    Many thanks in advance.

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others cooling their heels in the Monastery: (2)
As of 2024-03-19 06:28 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found