Joshua Scott wrote at Wed, 02 Jul 2003 21:25:34 -0400:
> I'm trying to copy data from one database field to another. The problem is
> that the field contains various newline and other types of control
> characters. Whenever the script runs, it processes those as perl code
> instead of data like
On Wed, 2 Jul 2003, Ling F. Zhang wrote:
> I use /pattern/g to progressively match a string (who
> content is read from a file)
> I want the cut the string off after the n-th match (if
> there is no n-th match, the string is unaltered)
> how can I do this without using a loop?
> right now, I am
>Hi all!
>I have this while loop in my script:
>while (($type ne "Windows") || ($type ne "Linux")) {
>print "Enter TYPE of server to build. Linux or Windoze [linux, windows]:\n";
>$type = ;
>chomp $type;
>$type =~ tr/a-z/A-Z/;
>if (($type eq "LINUX") || ($type eq "L")) {
>$type = "Linux"; }
>i
Hi Rob,
The text of the files is short (15 words at the most), so it can be either copy of
another file, or a text I would edit inside the file.
The names of my directory tree looks like this:
dir1
/ | \
Bill Akins <[EMAIL PROTECTED]> wrote:
:
: while (($type ne "Windows") || ($type ne "Linux")) {
This will always be true. Try:
while ( $type ne 'Windows' && $type ne 'Linux' ) {
^^
HTH,
Charles K. Clarkson
--
Head Bottle Washer,
Clarkson Energy Homes, Inc.
Sorry...
In article <[EMAIL PROTECTED]>, Kevin Pfeiffer wrote:
> In article <[EMAIL PROTECTED]>, Kevin Pfeiffer wrote:
>
>
>> Here's an 'or' version:
>> my $type1 = '';
>> while ( $type1 !~ /wisteria|lime/i ) {
>>print "Enter COLOR of server. Lime or Wisteria [lime, wisteria]: ";
>>chom
In article <[EMAIL PROTECTED]>, Kevin Pfeiffer wrote:
> Here's an 'or' version:
> my $type1 = '';
> while ( $type1 !~ /wisteria|lime/i ) {
>print "Enter COLOR of server. Lime or Wisteria [lime, wisteria]: ";
>chomp( $type1 = ucfirst lc );
>$type1 = 'Wisteria' if $type1 eq 'W';
>$
In article <[EMAIL PROTECTED]>, John W. Krahn wrote:
> Bill Akins wrote:
>>
>> Hi all!
>
> Hello,
>
>> I have this while loop in my script:
>>
>> while (($type ne "Windows") || ($type ne "Linux")) {
>
> Your problem is that you are using or when you should be using and.
>
>
>> print "Enter
> > while (($type ne "Windows") || ($type ne "Linux")) {
> Right here, you must have the full string "Windows" or "Linux"
Yes, correct.
> > print "Enter TYPE of server to build. Linux or Windoze
> > [linux, windows]:
> > \n";
> > $type = ;
> > chomp $type;
> > $type =~ tr/a-z/A-Z/;
>
> Here yo
I'm trying to copy data from one database field to another. The problem is
that the field contains various newline and other types of control
characters. Whenever the script runs, it processes those as perl code
instead of data like I'd like it to. How can I prevent it from doing this?
Here i
It was Wednesday, July 02, 2003 when Ling F. Zhang took the soap box, saying:
: I use /pattern/g to progressively match a string (who
: content is read from a file)
: I want the cut the string off after the n-th match (if
: there is no n-th match, the string is unaltered)
: how can I do this withou
I use /pattern/g to progressively match a string (who
content is read from a file)
I want the cut the string off after the n-th match (if
there is no n-th match, the string is unaltered)
how can I do this without using a loop?
right now, I am doing this:
while ($string =~ /pattern/g){
$count++;
Bill Akins wrote:
>
> Hi all!
Hello,
> I have this while loop in my script:
>
> while (($type ne "Windows") || ($type ne "Linux")) {
Your problem is that you are using or when you should be using and.
> print "Enter TYPE of server to build. Linux or Windoze [linux, windows]:
> \n";
> $type =
> -Original Message-
> From: Bill Akins [mailto:[EMAIL PROTECTED]
> Sent: Wednesday, July 02, 2003 3:48 PM
> To: [EMAIL PROTECTED]
> Subject: While loop, confused...
>
>
> Hi all!
>
> I have this while loop in my script:
>
> while (($type ne "Windows") || ($type ne "Linux")) {
Right
Hi all!
I have this while loop in my script:
while (($type ne "Windows") || ($type ne "Linux")) {
print "Enter TYPE of server to build. Linux or Windoze [linux, windows]:
\n";
$type = ;
chomp $type;
$type =~ tr/a-z/A-Z/;
if (($type eq "LINUX") || ($type eq "L")) {
$type = "Linux"; }
if (($type
> -Original Message-
> From: Rob Dixon [mailto:[EMAIL PROTECTED]
> Sent: Wednesday, July 02, 2003 3:15 PM
> To: [EMAIL PROTECTED]
> Subject: Re: how to remove last comma in file?
>
>
> Rob Dixon wrote:
> > Hi Shaunn.
> >
> > Shaunn Johnson wrote:
> > > Howdy:
> > >
> > > First off, many t
Rob Dixon wrote:
> Hi Shaunn.
>
> Shaunn Johnson wrote:
> > Howdy:
> >
> > First off, many thanks to all (esp. R. Dixon and T. Lowery)
> > for the help with the 'using table_info()' thread.
> >
> > I'm just about done with that script, but I have
> > one tiny problem.
> >
> > In my SECOND while loo
Hi Shaunn.
Shaunn Johnson wrote:
> Howdy:
>
> First off, many thanks to all (esp. R. Dixon and T. Lowery)
> for the help with the 'using table_info()' thread.
>
> I'm just about done with that script, but I have
> one tiny problem.
>
> In my SECOND while loop, I place a comma (,) at the end
> so t
> Greetings list
Go to cpan and check out Mail::Sender or Net::SMTP
>
> does anyone have the script which uses the minimal LIB or
> modules to send an email to the administrator..
HTH
Dmuey
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
Greetings list
does anyone have the script which uses the minimal LIB or modules to send an
email to the administrator..
I already have got cgiemail running.. but I want to customize it .. and it
wont let me!..
So I decided to look at other options where they all have there own
requirements..
Howdy:
First off, many thanks to all (esp. R. Dixon and T. Lowery)
for the help with the 'using table_info()' thread.
I'm just about done with that script, but I have
one tiny problem.
In my SECOND while loop, I place a comma (,) at the end
so that when the *.ddl files are built, it looks
just
Jenda Krynicky wrote:
> Date sent: Tue, 1 Jul 2003 00:56:10 -0700 (PDT)
> From: "Ling F. Zhang" <[EMAIL PROTECTED]>
> Send reply to: [EMAIL PROTECTED]
> Subject:combining array to scalar
> To: [EMAIL PROTECTED]
>
> > say I have array:
> > @a=["I","LOVE","PERL"]
>
I'm having a problem in a rather large program, so I've written this small
example to illustrate.
What this does is fork a process, then exec in the child to run a separate
program without waiting. In reality my main program doesn't end, so I need
to reap the children as they finish. After I exec
Kevin -
Thanks for the rec! I've been eyeing that book from my Safari account.
I've been suffering a bout of "I've been diddling with Perl since 1995, don't
you think I'd know it by now?" Keyword: diddling. I think if I'd been lucky
enough to have a job *doing* something with Perl, I'd be way
Just got the "Learning More Perl" aka "POR&M", aka "the alpaca book" today.
It does a nice job of building up examples and models, explaining enough of
the underlying structure for complex data structures, references, etc. so
that one can see a little of the how and why (though still without too
Thanks to all who answered! I don't need for this process to fork
(yet!), but thanks for the pointers.
I thought I was reading for new messages from the same client, but
instead I was looking for a new client while hanging on my first client. I
was missing a whole level of the
Charles K. Clarkson wrote at Wed, 02 Jul 2003 13:43:26 -0500:
> Read 'perlexwarn' in the perl documentation
^
Better to read
perldoc perllexwarn
^^
> for a complete discussion.
Greetings,
Janek
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands
Michael,
Read 'perlexwarn' in the perl documentation
for a complete discussion.
HTH,
Charles K. Clarkson
--
Head Bottle Washer,
Clarkson Energy Homes, Inc.
Mobile Home Specialists
254 968-8328
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTE
Greetings!
Is there any difference between
#!/bin/perl -w
and
#!/bin/perl
use warnings;
?
Thanx!
-Michael
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
From: "John W. Krahn" <[EMAIL PROTECTED]>
> Jenda Krynicky wrote:
> >
> > Assuming you meant
> >
> > @a=("I","LOVE","PERL");
> >
> > $b = join(' ', map {ucfirst(lc($_))} @a) . "\n";
>
> $b = qq<@{[map"\u\L$_",@a]}\n>; # :-)
($b=lc"@a\n")=~s/\b(.)/\U$1/g;
or
($b="[EMAIL PROTECTED]")
> But my server only ever sees the first message from any
> given client.
> Subsequent messages to my server are ignored. Does anyone
> know what I have
> to do to get my server to handle more than one message?
>
> #!/usr/bin/perl
> use warnings;
> use strict;
> my ($server, $server_port
Actually Rob your tips are very handy...
I have a nasty habit of posting only part of the code when
asking questions here, gotta break that habit.
> use strict; # always
> use warnings; # usually
Doing those :)
> - What's this 'move' thing? Have you sneakily added 'use File::Copy without
> t
- Original Message -
From: "McMahon, Christopher x66156" <[EMAIL PROTECTED]>
Date: Wednesday, July 2, 2003 12:55 pm
Subject: TCP/IP question
Hello Christopher,
>
> I think I'm missing a concept here...
>I built a very simple TCP/IP server like the one on p. 441 of
> the Camel
McMahon, Christopher x66156 wrote:
> I think I'm missing a concept here...
> I built a very simple TCP/IP server like the one on p. 441 of the
> Camel book.
> But my server only ever sees the first message from any given
> client. Subsequent messages to my server are ignored. Does any
- Original Message -
From: isao <[EMAIL PROTECTED]>
Date: Tuesday, July 1, 2003 7:07 pm
Subject: stdout+stderr to file?
> I'm writing scripts that are basically wrappers for Linux shell
> commands.
> I want to be able to 1) print messages to screen along with say
> the first
> line of
Jenda Krynicky wrote:
>
> Assuming you meant
>
> @a=("I","LOVE","PERL");
>
> $b = join(' ', map {ucfirst(lc($_))} @a) . "\n";
$b = qq<@{[map"\u\L$_",@a]}\n>; # :-)
> print $b;
John
--
use Perl;
program
fulfillment
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional comm
Hi Ronen.
You need to give us a foothold here.
Ronen Kfir wrote:
> How would I create a bunch of files with the same name
These files are to be a copy of an existing file? Or have some other prescribed
content?
> save them under the same root directory but only in part of the subdirectories
Hello:
I have a form entirely design with perl and it has many radio button.
What I trying to do is to make some fields required and if one is
missed, then the a subroutine is called and it will display the list of
the missed fields. Here is the sub:
sub process_form
{
my
($one,$two,$three,$f
George P. wrote:
> On Wed, 2 Jul 2003, Clinton wrote:
>
> > Hi
> > Using WinNt and ActiveState 5.6
> > I have a script reading data from a modem. For some reason it will not run
> > with a while loop. (I'm using a module which I don't fully understand, yet)
> > I can run the script from the command
Hi Anthony.
Anthony Akens wrote:
> Just want to check and make sure this snippet of code will do what I think it will.
>
> Trying to copy all files from $reportsdir to $oldreportsdir
Well you shouldn't be asking us, as we can make guesses - usually
Very Good Guesses - as to whether it will work,
I think I'm missing a concept here...
I built a very simple TCP/IP server like the one on p. 441 of the Camel
book.
But my server only ever sees the first message from any given client.
Subsequent messages to my server are ignored. Does anyone know what I have
to do to get my serve
Just want to check and make sure this snippet of code will do what I think it will.
Trying to copy all files from $reportsdir to $oldreportsdir
my $reportsdir = '/usr2/reports';
my $oldreportsdir = '/usr2/oldreports';
# Move everything from the report directory to the old report directory
opendi
Hi,
How would I create a bunch of files with the same name, save them under the same root
directory, but only in part of the subdirectories & change one word in the text inside
the files?
?Ronen Kfir
System Administrator
T.A.U Computing Division
Tel: 972-3-6407416
Fax: 972-3-6405158
Cellular:
Hamish,
There are lots of ways to do object orientedness and inheritance. How
you do it depends very much on the problem(s) you are trying to solve,
and often on personal style...I'll try to answer your questions in-line.
Hamish Whittal <[EMAIL PROTECTED]> writes:
> Hi Folks,
>
> I have an ob
Hi List
Is it possible to extract the contents of MS Outlook pst file
using "perl"?.
TIA
Free multi-lingual web-based and POP3 email service with a
generous 15MB of storage, a choice of themes for your mailbox,
message filtering, plus spam and virus protectio
> Greetings to all that is Perl
Howdy
>
> Is it possible to specify using a cgi script to read and
> output a Pure HTML file as output.. so that it can process
> the form data..
Do you mean can it output an html form to a browser, process it on submit and return
html to the browser?
Sure
I don't think you can tell mysql to run any commands whena records is inserted.
But what I do to achievge asimilar effect is this:
In the table I have a INT(1) field, say, Proc.
INSERT INTO Proc=1 ...
Then I cron a script to do this every hour or whatever:
SELECT ... WHERE Proc=1..
Foreach
In article <[EMAIL PROTECTED]>,
[EMAIL PROTECTED] (James Kipp) writes:
>$template = 'S n C4 x8';
>$| = 1;
>socket(MY_SOCKET, AF_INET, SOCK_STREAM, 0) || die "Socket: $!\n";
>
>$addr = (gethostbyname("10.1.101.12"))[4];
>$paddr = pack($template,AF_INET,$port,$addr);
>bind(MY_SOCKET, $paddr) || die
From: "Biju Ramachandran" <[EMAIL PROTECTED]>
To: [EMAIL PROTECTED], [EMAIL PROTECTED]
Subject: RE: reading a text file
Date: Mon, 30 Jun 2003 13:51:50 -0400
This is an extract from spl liscenece log file
06/16/03 10:07:46 NOTICE: "./spm_key (Ver.1.1.11)" started to install
licenses.
06/16/03
Hi Folks,
I have an object called Cisco:cs2600. I have a constructor that will new
that will initialise all the object with all the relavant information.
Now, I call the constructor to create a new instance of this object.
$deviceType = Cisco::cs2600->new($systemObjectID);
So, now I have an obj
Date sent: Tue, 1 Jul 2003 00:56:10 -0700 (PDT)
From: "Ling F. Zhang" <[EMAIL PROTECTED]>
Send reply to: [EMAIL PROTECTED]
Subject:combining array to scalar
To: [EMAIL PROTECTED]
> say I have array:
> @a=["I","LOVE","PERL"
From: "Nick Diel" <[EMAIL PROTECTED]>
> I am working on a project where machines will use a perl script to
> write to a table in a MySQL database. I want a perl script to run
> everytime there is a new entry, but I don't know how to trigger the
> perl script when there is a new entry (the perl to
From: "Azubi CAI" <[EMAIL PROTECTED]>
> Hi there,
>
> I need to substitute a string in a .rtf file with a string from an
> HTML form. I thought about using placeholders in the .rtf document and
> then searching and overwriting them with the data from the HTML form.
> I tried it out with that code:
Howdy, # Perly ;-?
### What I'm trying to do (the socket part) ###
I wrote in Perl CGI app for Xitami web server, which (my app) is LRWP
(Long_Running_Web_Process) - it does 'socket/connect' with web server on
startup and then sysread/syswrite to talk to the web server to handle requests
(
From: "PANNEER SELVAN" <[EMAIL PROTECTED]>
> Here is a simple program which runs an exe and does two
> key functions{ tab and enter}.. Basically i want to apply
> these key functions after start of the exe.These keys
> functions are required for succe
just send me the same if any body replies to ur query,
since i need to access the same
rgds
venkat
-Original Message-
From: Aman Thind [mailto:[EMAIL PROTECTED]
Sent: Wednesday, 2 July 2003 4:20 PM
To: [EMAIL PROTECTED]
Subject: Authenticating to the proxy
Hullo Friends
I need to auth
UNCLASSIFIED
Thank you both for the great script to do this.
I was doing it the long way, querying each DC, and getting the last logon
time of each user.
Where can I find more information on different methods/properties like you
used in the script?
-Original Message-
From: Tim Dumas [m
Hullo Friends
I need to authenticate to a proxy server in order to access the internet.
How can I do this so that my lwp scripts may run ?
I tried this but am still unable to connect to the net :
use LWP::UserAgent;
$ua = LWP::UserAgent->new;
$ua->proxy(['http', 'ftp'] => 'http://myproxyser
Shaunn Johnson wrote:
> Howdy:
>
> I would like to use the table_info() method for getting
> database / table metadata from a database. In this case,
> PostgreSQL 7.2.x.
>
> I am reading the "Programming the Perl DBI" book and
> I am using the following for my script to get a list of
> tables and
On Wed, 2 Jul 2003, Clinton wrote:
> Hi
> Using WinNt and ActiveState 5.6
> I have a script reading data from a modem. For some reason it will not run
> with a while loop. (I'm using a module which I don't fully understand, yet)
> I can run the script from the command line, let it finish and re
Hi
Using WinNt and ActiveState 5.6
I have a script reading data from a modem. For some reason it will not run with a
while loop. (I'm using a module which I don't fully understand, yet)
I can run the script from the command line, let it finish and rerun it manually every
thing works fine (with so
Panneer Selvan wrote:
Hi,
By this program key functions are execute after running the exe.. I want to execute the key funtions before completion of exe
use Win32::GuiTest qw(FindWindowLike GetWindowText
SetForegroundWindow SendKeys);
syste
I am working on a project where machines will use a perl script to write to
a table in a MySQL database. I want a perl script to run everytime there is
a new entry, but I don't know how to trigger the perl script when there is a
new entry (the perl to be triggered will be sitting on the same box a
I'm writing scripts that are basically wrappers for Linux shell commands.
I want to be able to 1) print messages to screen along with say the first
line of any STDERR, and 2) print messages, STDOUT, and STDERR to go to a
file.
The best I've come up with is something like the followng, which doesn
64 matches
Mail list logo