Re: Example Input Datas

2007-03-09 Thread Rodrigo Tavares
Hello Jeff, I believe my english is very bad. Bush is in Brazil, I'll go pratice my english with him :) In true, I desire the dest_ip will be informed by user, using a HTML file. Still, i don't say the value. The user will define this value in textbox of HTML. Thanks ! Rodrigo Faria > >> >>

Re: Example Input Datas

2007-03-08 Thread Jeff Pang
> >Hi Jeff, > >This IP 192.168.1.1 will replaced by IP defined from user. > >example: > >Enter with IP : 10.0.0.1 >Submit > >When somebody to type one value, it will replaced the file value. > >IP: 192.168.1.1 -> will be replaced -> 10.0.0.1 > Got it.Then your script is may right. The only note

Re: Example Input Datas

2007-03-08 Thread Rodrigo Faria Tavares
From: "Jeff Pang" <[EMAIL PROTECTED]> To: Sent: Thursday, March 08, 2007 12:23 PM Subject: Re: Example Input Datas Now it's change the file. Very funny :) if I want the user type one IP. I saw the example guestbook.cgi. Perhaps still : my $ip; print IP "T

Re: Example Input Datas

2007-03-08 Thread Jeff Pang
>Now it's change the file. >Very funny :) > >if I want the user type one IP. >I saw the example guestbook.cgi. > >Perhaps still : > > >my $ip; >print IP "To: $ip\n"; >for (@file) > { >s/192.168.1.85/$ip/g; > print FILE $_; > } > What would you like to say? -- http://home.arcor.de/jef

Re: Example Input Datas

2007-03-08 Thread Rodrigo Tavares
Hello, Now it's change the file. Very funny :) if I want the user type one IP. I saw the example guestbook.cgi. Perhaps still : my $ip; print IP "To: $ip\n"; for (@file) { s/192.168.1.85/$ip/g; print FILE $_; } thanks again ! --- Jeff Pang <[EMAIL PROTECTED]> escreveu: > >

Re: Example Input Datas

2007-03-08 Thread Jeff Pang
> s/192.168.1.85/10.0.0.1/g > print FILE $_; hello, Here the first line you lost a ';' at the end. The whole script I've tested fine as below: use CGI qw(:standard); use CGI::Carp qw(warningsToBrowser fatalsToBrowser); use strict; print header; print start_html("Modify Information"); my $f

Re: Example Input Datas

2007-03-08 Thread Rodrigo Tavares
,$_; > > Here comma is not needed. > change to: > > print FILE $_; > > Also I'd suggest you always add the "use strict" at > the begin of your cgi scripts. > > -Original Message- > >From: Rodrigo Tavares <[EMAIL PROTECTED]> >

Re: Example Input Datas

2007-03-08 Thread Jeff Pang
ners-cgi@perl.org >Subject: Re: Example Input Datas > >Hello Jeff, > >Well, thanks your help. >More one thing. >When I try to run the cgi in browser come this message > > >Software error: > >No comma allowed after filehandle at >/home/faria/public_html/cgi-bin/p

Re: Example Input Datas

2007-03-08 Thread Rodrigo Tavares
Hello Jeff, Well, thanks your help. More one thing. When I try to run the cgi in browser come this message Software error: No comma allowed after filehandle at /home/faria/public_html/cgi-bin/perl/entrada-dados.cgi line 19. See my below code. print header; print start_html("Modify Informati

Re: Example Input Datas

2007-03-07 Thread Jeff Pang
>I'm beginner in Perl with CGI. >I create a two input box; > >In the first input box, I'll put the ip adress. >In the second input box I'll put the port > >Then when i click em submit, the cgi must make: > >perl -pi -e 's/192.168.1.1/10.0.0.1/g' /opt/myfile > >How I can to do it ? > At first you