Re: doubt in code

2008-08-22 Thread Dr.Ruud
"Irfan J Sayed (isayed)" schreef:


Irfan, trim your postings. Cut out any piece of text that is no longer
relevant. You quoted all the nonsense that Stewart Anderson thinks he
needs to include. Clean up your act.


> Agree, but where is the file name??
> $server will just store the server name right?

There is no file involved. Did you read `perldoc IO::Socket`?

-- 
Affijn, Ruud

"Gewoon is een tijger."


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/




RE: doubt in code

2008-08-21 Thread Irfan J Sayed (isayed)

Hi,

Can somebody please help.

Regards
Irfan. 

-Original Message-
From: Irfan J Sayed (isayed) 
Sent: Friday, August 22, 2008 11:12 AM
To: 'Stewart Anderson'; beginners@perl.org
Subject: RE: doubt in code

Agree, but where is the file name??
$server will just store the server name right?

Regards
Irf 

-Original Message-
From: Stewart Anderson [mailto:[EMAIL PROTECTED]
Sent: Thursday, August 21, 2008 8:25 PM
To: beginners@perl.org
Cc: Stewart Anderson
Subject: RE: doubt in code


> -Original Message-
> From: Irfan J Sayed (isayed) [mailto:[EMAIL PROTECTED]
> Sent: 21 August 2008 15:49
> To: beginners@perl.org
> Subject: doubt in code
> 
> Hi All,
> 
> I have sample code like this:
> 
> #!/usr/bin/perl
> 
> # file: lgetr.pl
> 
> # Figure 1.2: Read the first line from a remote server
> 
> use IO::Socket;
> 
> my $server = shift;
> 
> my $fh = IO::Socket::INET->new($server);
> 
> my $line = <$fh>;
> 
> print $line;
> 
> As per comment it says that, it prints the first line of a file from 
> remote server. So my understanding is that, it will go to remote 
> server,read the file and then prints the first line of a file on the 
> existing console. is it right ?? if yes then in the code where are we 
> giving the filename??
> 
> Please suggest.
> 
> Regards
> 
> Irfan.
> 
> 

[Stewart Anderson] 

 my $fh = IO::Socket::INET->new($server);

is   where the  file handle $fh gets assigned



Information in this email including any attachments may be privileged,
confidential and is intended exclusively for the addressee. The views
expressed may not be official policy, but the personal views of the
originator. If you have received it in error, please notify the sender
by return e-mail and delete it from your system. You should not
reproduce, distribute, store, retransmit, use or disclose its contents
to anyone. Please note we reserve the right to monitor all e-mail
communication through our internal and external networks. SKY and the
SKY marks are trade marks of British Sky Broadcasting Group plc and are
used under licence. British Sky Broadcasting Limited (Registration No.
2906991), Sky Interactive Limited (Registration No. 3554332),
Sky-In-Home Service Limited (Registration No. 2067075) and Sky
Subscribers Services Limited (Registration No. 2340150) are direct or
indirect subsidiaries of British Sky Broadcasting Group plc
(Registration No. 2247735). All of the companies mentioned in this
paragraph are incorporated in England and Wales and share the same
registered office at Grant Way, Isleworth, Middlesex TW7 5QD.

--
To unsubscribe, e-mail: [EMAIL PROTECTED] For additional
commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/



--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/




RE: doubt in code

2008-08-21 Thread Irfan J Sayed (isayed)
Agree, but where is the file name??
$server will just store the server name right?

Regards
Irf 

-Original Message-
From: Stewart Anderson [mailto:[EMAIL PROTECTED] 
Sent: Thursday, August 21, 2008 8:25 PM
To: beginners@perl.org
Cc: Stewart Anderson
Subject: RE: doubt in code


> -Original Message-
> From: Irfan J Sayed (isayed) [mailto:[EMAIL PROTECTED]
> Sent: 21 August 2008 15:49
> To: beginners@perl.org
> Subject: doubt in code
> 
> Hi All,
> 
> I have sample code like this:
> 
> #!/usr/bin/perl
> 
> # file: lgetr.pl
> 
> # Figure 1.2: Read the first line from a remote server
> 
> use IO::Socket;
> 
> my $server = shift;
> 
> my $fh = IO::Socket::INET->new($server);
> 
> my $line = <$fh>;
> 
> print $line;
> 
> As per comment it says that, it prints the first line of a file from 
> remote server. So my understanding is that, it will go to remote 
> server,read the file and then prints the first line of a file on the 
> existing console. is it right ?? if yes then in the code where are we 
> giving the filename??
> 
> Please suggest.
> 
> Regards
> 
> Irfan.
> 
> 

[Stewart Anderson] 

 my $fh = IO::Socket::INET->new($server);

is   where the  file handle $fh gets assigned



Information in this email including any attachments may be privileged,
confidential and is intended exclusively for the addressee. The views
expressed may not be official policy, but the personal views of the
originator. If you have received it in error, please notify the sender
by return e-mail and delete it from your system. You should not
reproduce, distribute, store, retransmit, use or disclose its contents
to anyone. Please note we reserve the right to monitor all e-mail
communication through our internal and external networks. SKY and the
SKY marks are trade marks of British Sky Broadcasting Group plc and are
used under licence. British Sky Broadcasting Limited (Registration No.
2906991), Sky Interactive Limited (Registration No. 3554332),
Sky-In-Home Service Limited (Registration No. 2067075) and Sky
Subscribers Services Limited (Registration No. 2340150) are direct or
indirect subsidiaries of British Sky Broadcasting Group plc
(Registration No. 2247735). All of the companies mentioned in this
paragraph are incorporated in England and Wales and share the same
registered office at Grant Way, Isleworth, Middlesex TW7 5QD.

--
To unsubscribe, e-mail: [EMAIL PROTECTED] For additional
commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/



--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/




RE: doubt in code

2008-08-21 Thread Stewart Anderson

> -Original Message-
> From: Irfan J Sayed (isayed) [mailto:[EMAIL PROTECTED]
> Sent: 21 August 2008 15:49
> To: beginners@perl.org
> Subject: doubt in code
> 
> Hi All,
> 
> I have sample code like this:
> 
> #!/usr/bin/perl
> 
> # file: lgetr.pl
> 
> # Figure 1.2: Read the first line from a remote server
> 
> use IO::Socket;
> 
> my $server = shift;
> 
> my $fh = IO::Socket::INET->new($server);
> 
> my $line = <$fh>;
> 
> print $line;
> 
> As per comment it says that, it prints the first line of a file from
> remote server. So my understanding is that, it will go to remote
> server,read the file and then prints the first line of a file on the
> existing console. is it right ?? if yes then in the code where are we
> giving the filename??
> 
> Please suggest.
> 
> Regards
> 
> Irfan.
> 
> 

[Stewart Anderson] 

 my $fh = IO::Socket::INET->new($server);

is   where the  file handle $fh gets assigned



Information in this email including any attachments may be privileged, 
confidential and is intended exclusively for the addressee. The views expressed 
may not be official policy, but the personal views of the originator. If you 
have received it in error, please notify the sender by return e-mail and delete 
it from your system. You should not reproduce, distribute, store, retransmit, 
use or disclose its contents to anyone. Please note we reserve the right to 
monitor all e-mail communication through our internal and external networks. 
SKY and the SKY marks are trade marks of British Sky Broadcasting Group plc and 
are used under licence. British Sky Broadcasting Limited (Registration No. 
2906991), Sky Interactive Limited (Registration No. 3554332), Sky-In-Home 
Service Limited (Registration No. 2067075) and Sky Subscribers Services Limited 
(Registration No. 2340150) are direct or indirect subsidiaries of British Sky 
Broadcasting Group plc (Registration No. 2247735). All of the companies 
mentioned in this paragraph are incorporated in England and Wales and share the 
same registered office at Grant Way, Isleworth, Middlesex TW7 5QD.

--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/