Bhanu Prakash wrote:
HI All,
Is there a way to Validate the fields of a
form? Say I have a
text field, and I should show an error to the user if
he does not enter
anything while submitting the form?
Can somebody give me some sample script?! with some
high level explaination?
Thanks
The text file that I want to insert is
dougs.txt
= Which has two sentences =
Hey it works...
Happy Belated Birthday...
==
The Code
dougs1.cgi
=
#!/usr/bin/perl
print
Not exactly sure what you're trying to do...Try something like this.
#!/usr/bin/perl
print Content-type: text/html, \n\n;
print HTML\nHEAD\n;
print titletest page/title\n;
print /head\n;
print body\n;
open TEXT, ../cards/dougs.txt;
while (TEXT) {
print $_BR;
At 11:37 21/02/02, you wrote:
Bhanu Prakash wrote:
HI All,
Is there a way to Validate the fields of a
form? Say I have a
text field, and I should show an error to the user if
he does not enter
anything while submitting the form?
Can somebody give me some sample script?! with
What do I need to do to get the Output to look like dougs.txt?
and
How come my newline \n; didn't seem to work??? Where did the dots come
from?
You must use HTML code! Newlines are ignored by the browser. Instead
print BR for a new line.
btw what do you want to do with Test 2? I do not
I have a form that people are going to be filling out online. I am using
JavaScript on the front-end to validate the form. However, for security
sake and for my own knowledge, I would like to know how to limit the length
of form submissions on my server validation sequence. I don't want to cut
Thank you,,, Joshua Hayden
That was exactly what I was trying to do.
[EMAIL PROTECTED]
- Original Message -
From: Joshua Hayden [EMAIL PROTECTED]
To: Sir Douglas Cook [EMAIL PROTECTED];
[EMAIL PROTECTED]
Sent: Thursday, February 21, 2002 9:58 AM
Subject: Re: selecting a text file for
use CGI ':standard';
if (length(param('field')) 25) {
subroutine(Please limit your response to 25 characters.);
} elsif ...
Best Regards,
JOSHUA D. HAYDEN
Owner/Operator of www.PinnacleSiteDesign.com
- Original Message -
From: Hughes, Andrew [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Hi all,
I want to make a form to let the visitors to type a text.
In this text, I want to allow them to insert a variable.
For example a $name variable.
I would like to allow them to insert something like:
My name is XXX and I would like to meet name from LA.
And on the next page (as a test)
On Wed, Feb 20, 2002 at 08:58:41AM -0800, Bhanu Prakash wrote:
when a user submits a form, the input entered by him should be
mailed to the address he specifies in one of teh input fileds.!
If you put that one on a public webserver, you should consider a way
to prevent bad people from using
try FormMail
http://worldwidemart.com/scripts/formmail.shtml
-Original Message-
From: Bhanu Prakash [mailto:[EMAIL PROTECTED]]
Sent: 20 February 2002 16:59
To: [EMAIL PROTECTED]
Subject: Sending Mail
Hi,
I'm new to Perl and am trying to write some cgi
programs in Perl.
Currently
Bhanu,
Not sure what operating system you are using, but I have just done
something very similar in Windows. The form the user input data into was on
their intranet, and then the details of the form were mailed out to the
client (in html orginally, but my clients are large insurance firms
Chris,
I'm using Solaris to run my perl script. Did
you have a chance to write script in Solaris anytime?!
Should the script be different for Solaris and
Windows?
Thanks
Bhanu.
Bhanu,
Not sure what operating system you are using, but I
have just done
something very similar in
HI All,
Is there a way to Validate the fields of a
form? Say I have a
text field, and I should show an error to the user if
he does not enter
anything while submitting the form?
Thanks for the help
Bhanu.
=
Bhanu Prakash G V S
__
I would do this using javascript within the form. Then when the field loses
focus you can validate it. This means the form doesn't have to be submitted
before the user is alerted of a problem.
For extra robustness you can also validate the submitted results in the perl
script and return the user
Hi
How do you do it
Give me two different methods in subroutines, that will:
match together all of its parameters into on large list.
Many thanks to the following people: Brett, Micheal F, Zentara, Stephen H, Edward)
Appreciate all you asistance)
Cheers
Bruce
--
To unsubscribe, e-mail:
John,
Thanks much for that information. It would be of
great help to me if you can provide me with some
sample scripts that will do these functions.!
Of course I'd like to add more robustness to my
script.! But, I don't know how to :(
Looking for your help
Bhanu.
I would do this using
Hi all
I,am newbie perl ,i have text file like this
INPUT FILE
SUSCP:SNB=704131,LIST;
SUBSCRIBER DATA
SNBDEVDETYSUT SCL MIS COS
704131 LI3-37891 IPT-1
I am afraid this is a OT. Please consult with good Javascript
documentation available online from Netscape and Microsoft Websites.
You can write a javascript function, say 'checkThis' which would accept
a parameter that corresponds to your text object and associate that with
the onBlur event
You might have more luck asking this in the Perl CGI Beginners list. I
haven't got any scripts that do this, but I know it's possible.
See http://learn.perl.org to subscribe to the CGI list.
John
-Original Message-
From: Bhanu Prakash [mailto:[EMAIL PROTECTED]]
Sent: 21 February 2002
Is there a way to find out the current possition in a
file when you have unset $/?
Err... unset $/ and the first time you read you've just
grabbed the whole file - that means you're at the end.
And that's all you know, unless:
perldoc -f tell
perldoc -f seek
Jonathan Paton
--- Wagner-David [EMAIL PROTECTED] wrote:
Though s(world .. worked w/o /, it should be written
s/(world | how )//gi;
s/\b(world|how)\b//gi;
The \b is a word boundary, which is going to work as
expected more frequently.
Jonathan Paton
__
Do
is this homework? Your other posts looks very homeworkish...
/jon
Bruce Ambraal wrote:
Hi
How do you do it
Give me two different methods in subroutines, that will:
match together all of its parameters into on large list.
Many thanks to the following people: Brett, Micheal F,
On Wed, 20 Feb 2002 13:54:05 -0600, [EMAIL PROTECTED] (Elaine -Hfb- Ashton)
wrote:
zentara [[EMAIL PROTECTED]] quoth:
*
*All my searches on the net seem to indicate that bleedperl
*is the latest version; but the BerkeleyDB docs say
*it will need only perl version 5.004; and I have v5.6.0.
Oh..I
I kinda cheated.
open(FH, . $file) or die print Cannot read $file;
local $/ = undef;
my $seek = 0;
while (FH) {
while (/^(START(.*)^END)/smg) {
if (!$seek){ $seek= (pos) - length $1;}
}
}
$seek will eventually get the number which represents the number of
charaters read.
Then I got the
Hi everyone
I am trying to learn Perl looking into some scripts.
One of them has a regular expression inside.
First of all, I need to know what two specific lines are doing. The code is
bellow.
$req =~ s/\r//g ;
$req =~ s/([^\n]{72,72})\n([^\n]{1,71})\n([^\n]{1,71})$/$1\n$2$3/
I know they
From: Daniel Falkenberg [EMAIL PROTECTED]
Just wondering if any one has seen this error before when installing a
Active Perl Module. I have RTFM. I have run...
c:\ppm
then...
PPMinstall HTML-TableExtract.ppd
but then I recieve the following error...
Error
$req =~ s/\r//g ;
# This is replacing all carriage return special characters with nothing
globally.
# s/(replace)\r(carriage return special char)/(with nothing i.e delete
them)/g(globally. i.e for every match in the string, not just the first)/;
$req =~
John
Thank you very much for the explanation and for the links.
Lilian.
-Mensagem original-
De: John Edwards [mailto:[EMAIL PROTECTED]]
Enviada em: quinta-feira, 21 de fevereiro de 2002 11:11
Para: 'Lilian Alvarenga Caravela Godoy'; '[EMAIL PROTECTED]'
Assunto: RE: Regular Expression
Not sure if this is Perl or apache related,
but have spent hours trawling through web sites for the answer
Gettin a bit desperate now so any help would be much appreciated.
I have a perl script that runs fine using netscape fastrack server
but when I use Apache 1.3.22 I don't get as many $ENV's
JON MOLIN many thanks to you too..., if that's what you want to hear.
Don't have time for these question need to get myself skilled in Perl soonest.
I surpose the name [EMAIL PROTECTED] is meant for people like me
SUSAN not to worry I am two weeks in the game too, worken on the
above problem,
On Thu, Feb 21, 2002 at 02:42:31PM -, IT Workflow - Terry
Honeyford wrote:
but when I use Apache 1.3.22 I don't get as many $ENV's back from
the server, in particular the one my script is looking for -
($ENV{remote_user})
In apache's httpd.conf, you should enable these lines:
Darren,
Can I run this formmail from another cgi program?
Say I have some code fragment like this?
if(param(myinfo)) {
Can I invoke formmail here?
}
Would you mind explaining me, how ?
Thanks
Bhanu.
try FormMail
http://worldwidemart.com/scripts/formmail.shtml
-Original Message-
Hi guys,
I was wondering if anyone knows how to execute Unix
commands in a Perl Script?
system(echo Hello World);
my $output = qx(echo Hello There);
print The shell said :$output\n;
perldoc -f system
perldoc perlop
Jonathan Paton
__
Do You
Greetings listers,
I have the following code snippet:
my @result;
@result =`ping $hostname`;
my $aPing = @result;
my $Pcount = 0;
$Status = $entryS-Entry-delete(1.0, end);
while ($aPing 0){
print DUMPFILE * @result[$Pcount];
if ( substr(@result[$Pcount],0, 12) == 'Packets:' ) {
On Thu, Feb 21, 2002 at 08:46:54AM -, Darren Simpson wrote:
try FormMail
http://worldwidemart.com/scripts/formmail.shtml
Be careful with formmail, for there are lots of script kiddies out
there, trying to abuse it. Although I don't have it on my webserver,
people occasionally try to
Any thought to storing links to the docs in a db
rather than the data itself, maybe with some keywords
you can search on?
I don't see why, the database will handle it just fine.
All you need to do is write a couple of simple wrapper
CGI scripts. Using only the database is far easier to
make
don't use == for string comparison. Use eq in place of the ==
see:
perldoc perlop
-Original Message-
From: Chris [mailto:[EMAIL PROTECTED]]
Sent: Thursday, February 21, 2002 10:22 AM
To: [EMAIL PROTECTED]
Subject: Need help with if statement - please
Greetings listers,
I have the
Basically, you want to run ifconfig to get a list of which interfaces
are up and then look for ppp devices:
open IFCONFIG, ifconfig |;
my @interfaces;
while(IFCONFIG){
next unless /^(ppp\d+)/;
push @interfaces, $1;
}
close IFCONFIG;
This should give you what an array of what
On Tue, Feb 19, 2002 at 02:54:33PM -0800, Lance Prais wrote:
I am not sure how to do this. I wrote a perl script that searches a doc
table and I need to have it called when I reference a web page.
Write a perl-script (with the help of man CGI)
and just put it in your webserver's /cgi-bin/
Also there are no delimiting characters to search.
And one more problem is that they rarely end the
sentence with a period. The only good news is that
there are never more than 4 lines. But because there
is almost always a newline, I can't use:
while
because it searches line by
Hi Perl Gurus
Is there a way to compare the values in perl?
something like..
my $user = remote_user()
if ($user == $owner_of_page ) {
do_something
} else {
do_something_else
}
Thanks
Bhanu.
__
Do You Yahoo!?
Yahoo! Sports - Coverage of the 2002
Nikola Janceski wrote:
don't use == for string comparison. Use eq in place of the ==
see:
perldoc perlop
-Original Message-
From: Chris [mailto:[EMAIL PROTECTED]]
Sent: Thursday, February 21, 2002 10:22 AM
To: [EMAIL PROTECTED]
Subject: Need help with if statement - please
Perl Gurus,
Can somebody tell me what is the difference between
the two , with some examples?
open(|/usr/users/mydir/myfile);
and
open(/usr/users/mydir/myfile);
Thanks for the response
Bhanu.
=
Bhanu Prakash G V S
__
Do You Yahoo!?
Yahoo!
On Wed, 20 Feb 2002 16:37:56 +0200, [EMAIL PROTECTED] (Bruce Ambraal) wrote:
1. (see subject)
2. Explain lines 3 , 4
3.Why does'nt this coding return anything2
sub routine {
my @arr = (0, 'a' 1, 'b');
@_ = @arr;
my $retun_me = shift;
return( $return_me )
};
Try this one, it captures the
On Wed, 20 Feb 2002 17:17:20 +, [EMAIL PROTECTED] (Craig Eberly) wrote:
Hmm, I've tried this but it doesn't seem to change the file permissions at
all on the backup file. I checked into it, and my stat command or $mode in
this case is equal to 33261. Is that a normal output for the mode
Hello:
I subscribe to the perl newsletters,I am wondering
what is the best way to announce to the group that I
am looking for someone to install some perl scripts on
my website for as reasonable as possible?
Ed
__
Do You Yahoo!?
Yahoo! Sports -
On Thu, 21 Feb 2002 11:09:59 -0500, [EMAIL PROTECTED] (Zentara) wrote:
Ooops, made a dumb error. Corrected below.
The 33261 is file permissions and file type in decimal.
Under linux, chmod accepts this value, maybe under solaris
you have to to have the octal value?
Try this instead:
dude1e == dude1e [EMAIL PROTECTED] writes:
dude1e I subscribe to the perl newsletters,I am wondering
dude1e what is the best way to announce to the group that I
dude1e am looking for someone to install some perl scripts on
dude1e my website for as reasonable as possible?
Post your request on
if ( $user eq $owner_of_page)
do something;
At 07:48 AM 2/21/2002 -0800, Bhanu Prakash wrote:
Hi Perl Gurus
Is there a way to compare the values in perl?
something like..
my $user = remote_user()
if ($user == $owner_of_page ) {
do_something
} else {
do_something_else
}
Thanks
Bhanu.
Zentara == Zentara [EMAIL PROTECTED] writes:
Zentara On Wed, 20 Feb 2002 17:17:20 +, [EMAIL PROTECTED] (Craig Eberly) wrote:
Hmm, I've tried this but it doesn't seem to change the file permissions at
all on the backup file. I checked into it, and my stat command or $mode in
this case
I've searched high and low for a module, any module, that would allow me to
make called to the postgres database in Windows, but have come up empty.
There doesn't even seem to be a way to do it from DBI. Does anyone have any
experience with this? I would love it if someone could prove to me I
Though s(world .. worked w/o /, it should be written
s/(world | how )//gi;
s/\b(world|how)\b//gi;
The \b is a word boundary, which is going to work as
expected more frequently.
The first example doesn't work if the word is followed by a punctuation
mark.
The second example doesn't get
I have a weird question for you: Is there anyway to use subroutines written
in another language from within perl (like the xs package for C). In
particular, I want to use Fortran code from perl scripts.
Any ideas?
Thanks
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands,
$req =~ s/([^\n]{72,72})\n([^\n]{1,71})\n([^\n]{1,71})$/$1\n$2$3/
# This regex appears to do nothing. It's looking for three matches, then
replacing them with the matches found. It's like saying look for all
instances of one two three in the string and replace them with one two
three.
This is correct, but for the sake of readability I'd put the /\s+/ in there
anyway.
-Original Message-
From: Deen Hameed [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, February 20, 2002 10:39 PM
To: Daniel Falkenberg
Cc: [EMAIL PROTECTED]
Subject: Re: Splitting variable...
# split
There may be a solution using split, but I am much more familiar with
regular expressions, so I crafted the following:
use strict;
use warnings;
my $str = UaBitEssdSi;
my @dpt = ();
while ($str =~ /([A-Z][a-z]*)/g) {
push @dpt,($1);
}
foreach my $i (0..$#dpt) {
print
On Feb 20, Tim Musson said:
The people who control the data want to remove the _ chars and make
the delimiter based on the case of the chars (first char of each part
is uc, all others are lc)...
So the source would look like this
UaBitEssdSi
I still need to put the same elements into @dpt, so
Hey all,
My current source looks like this
ua_bit_essd_si
I split on _ into @dpt.
The people who control the data want to remove the _ chars and make
the delimiter based on the case of the chars (first char of each part
is uc, all others are lc)...
So the source would look like this
On Feb 21, Deen Hameed said:
# split works on whitespace by default
@somearray = split $string;
Err, that splits $_ on the contents of $string. Yes, split() uses
whitespace by default, but that default is the FIRST argument.
What I'm saying is that
split;
is equivalent to
split ' ';
On Feb 21, Antonis Zamout said:
I have a weird question for you: Is there anyway to use subroutines written
in another language from within perl (like the xs package for C). In
particular, I want to use Fortran code from perl scripts.
There might be Inline::Fortran. If not, I'm not sure what
Hi all-
I'd like to be able to filter text in a large number of PDF files,
ideally opening the pdf, filtering the text and then saving the
stream back again as a pdf. Can anyone point me towards an easy way
to do this? Preliminary research on CPAN showed a large number of
modules that deal
This reminds me of an antacid commercial on TV,
because technically,
You just did!
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
On Feb 21, Mark Anderson said:
The first example doesn't work if the word is followed by a punctuation
mark. The second example doesn't get rid of the space, which is fine for
HTML, but not for other uses.
Well, you have to define the word-removal. If you're removing the word at
the beginning
Hi everyone
I am trying to upload a windows txt file to a Linux server.
There are an application running in my Linux server that reads the txt file
to extract some information.
But the application doesn't recognize the file because it's originally from
windows.
I know that I could solve it
Invoking a Perl script from a TN3270 terminal (Linux/390)
Want to issue the shell clear command to clear the screen.
Using Bash shell 1.14.7(1)
clear works ok from the command line.
Does not clear the screen when issued from the script. Displays1
instead
Have tried these syntaxes (if
Chris [EMAIL PROTECTED] wrote on 21 Feb 2002:
if ( substr(@result[$Pcount],0, 12) == 'Packets:' ) {
How about
if ( substr($result[$Pcount],0, 12) eq 'Packets:' ) {
$result[$Pcount] is a scalar, not an array.
or
if ( $result[$Pcount] =~ /^\s+Packets:/ ) {
But I think
A brett ...
Any headway on the code I sent you?
On Wed, 20 Feb 2002, Brett W. McCoy wrote:
On Wed, 20 Feb 2002, phinney wrote:
I have an object method that allocates quite a bit of memory through
fillung up an array. I then pass that array back to the calling
program. Now, if I
use system(clear)
system displays output to the terminal where ` (backtick) returns the output
to the perl script not the terminal.
-Original Message-
From: Hewlett Pickens [mailto:[EMAIL PROTECTED]]
Sent: Thursday, February 21, 2002 2:26 PM
To: zPerl Beginners
Subject: How to issue
Try typing this at the command line:
$ perldoc -f system
;-)
-_-Aaron
-Original Message-
From: Hewlett Pickens [mailto:[EMAIL PROTECTED]]
Sent: Thursday, February 21, 2002 11:26 AM
To: zPerl Beginners
Subject: How to issue CLEAR command from Perl
Invoking a Perl script from a
David Wall wrote:
Chris [EMAIL PROTECTED] wrote on 21 Feb 2002:
if ( substr(@result[$Pcount],0, 12) == 'Packets:' ) {
How about
if ( substr($result[$Pcount],0, 12) eq 'Packets:' ) {
$result[$Pcount] is a scalar, not an array.
or
if ( $result[$Pcount] =~
request for help. I am having the following problem with a test script.
I issue the stmt: @lines = $t-cmd(who);
And my script times out at that statement.
I have the Dump_Log turned on. I can see that my command executes
successfully on the remote host. But, I want to finish the remaining
Lilian Alvarenga Caravela Godoy wrote:
Hi everyone
I am trying to learn Perl looking into some scripts.
One of them has a regular expression inside.
First of all, I need to know what two specific lines are doing. The code is
bellow.
$req =~ s/\r//g ;
This is replacing all the \r
Thank you - the system(clear)did the trick.
And Aaron Shurts' suggestion about reading perldoc resolved a reading
problem I've been having.
Items like Cexec LIST and Cwait() have meant nothing when I've come
across them. Now - it dawns on me that they are c calls.
Hewlett
--
To
On Feb 21, Hewlett Pickens said:
Items like Cexec LIST and Cwait() have meant nothing when I've come
across them. Now - it dawns on me that they are c calls.
No, you're looking at raw Pod markup. It's like seeing bwhoa/b
instead of rendered HTML.
C... means that the text should be shown
This looks like an issue we ran into when connecting with MS-SQL 7. Try
using two different database handles, one handles the query and the
other one to perform the inserts.
You also were missing a semi-colon after your print, but I think that
was probably an error in copying the code to the
Between one of my colleagues and myself, we stumbled on to the problem. It
was an incorrect Prompt assignment when I was doing a new on my telnet
object. Those darn typos.
Sorry,
Bill Barrett
-Original Message-
From: Bill Barrett [mailto:[EMAIL PROTECTED]]
Sent: Thursday, February 21,
Read 'perldoc perlpod' for a description of the markup
Thank you. That clears up my mis-understanding and provides a lot more
information besides.
As time goes by, things gradually becoming less murky. Am still on my back
flailing with arms and legs, but getting closer to the crawling
If you don't already have it, invest some coin in the 3rd edition of
'Programming Perl'.
-_-Aaron
-Original Message-
From: Hewlett Pickens [mailto:[EMAIL PROTECTED]]
Sent: Thursday, February 21, 2002 2:15 PM
To: [EMAIL PROTECTED]; zPerl Beginners
Subject: RE: How to issue CLEAR command
Hi all,
I've noticed some interesting behavior when trying to shift an array that
you're iterating over. For example:
my @ary = (0..1000);
for (@ary)
{
if($_ = 1000)
{
shift @ary;
}
}
print scalar @ary, \n;
This prints 500 on my NT box with ActiveState
I inserted a print statement into your code that may help you understand
what's happening:
my @ary = (0..1000);
for (@ary)
{
if($_ = 1000)
{
print;
shift @ary;
}
}
print scalar @ary, \n;
## my comments:
the for
Using the following code, I want to create a hash or individual lists. Of
course, this code doesn't work
What do I need to change to correct my error?
--- Code follows ---
#!/perl/bin/perl
use strict;
my %printQueue;
push($printQueue{A}, 'This is the first line in
Hello List,
The code below of coarse will count all characters in the string $string
$string = 4556jhkl;
$count = $string =~ tr/a-zA-Z0-9//;
How would I go about only allowing numbers and letters of the alpahbet?
if ( $string =~ /\dw/)) {
print Only letters and numbers allowed: NO SPECIAL
On Feb 22, Daniel Falkenberg said:
The code below of coarse will count all characters in the string $string
$string = 4556jhkl;
$count = $string =~ tr/a-zA-Z0-9//;
How would I go about only allowing numbers and letters of the alpahbet?
You could say:
if ($string =~ tr/a-zA-Z0-9//c) {
On Feb 21, [EMAIL PROTECTED] said:
Using the following code, I want to create a hash or individual lists. Of
course, this code doesn't work
What do I need to change to correct my error?
push() requires an array. $foo{bar} is a scalar. @{ $foo{bar} } is an
array.
push($printQueue{A},
If you don't mind having underscores in your text, you could also do this:
if($string !~ /^\w+$/){ #If the string does not have only letters, digits,
and underscores from start to finish (\w)
print There's a special character in there somewhere.\n;
}
-Original Message-
From: Jeff
On Thu, Feb 21, 2002 at 10:47:43AM +1030, Daniel Falkenberg wrote:
$string = BusinessPersonalFAD AFD:test(Regional);
@line = split/\s+/, $string;
Now $line[1] prints nothing? Am I doing something wrong here?
perl -wle '@line = split(/\s+/, $ARGV[0]; print $line[1];'
At 02:00 PM 2/21/02 +1030, Daniel Falkenberg wrote:
Hey all,
Just wondering if any one know what the oposite of $response-is_success
in the code below? I have tried $response-is_fail and
$response-is_failure.
Oh so close :-)
$response-is_error
I have also RTFM but I can't find anywhere what
Here's another way, which I suppose is simply an alternative to the system call:
Notice how you just print the *value* from the captured backtick in the following
line:
perl -e '$c=`clear`; print Testing ...\n; sleep 1 ; print $c;'
Matt
--- Hewlett Pickens [EMAIL PROTECTED] wrote:
Invoking
I have encountered a behavior that I think it is a little
odd and I have discovered it has to do with the standard
module Cwd. I had a Perl script which was called by
a Java application via Runtime.getRuntime().exec()
I have discovered that it was a good idea to use the
form that includes not
Timothy == Timothy Johnson [EMAIL PROTECTED] writes:
Timothy If you don't mind having underscores in your text, you could also do this:
Timothy if($string !~ /^\w+$/){ #If the string does not have only letters, digits,
Timothy and underscores from start to finish (\w)
Nope, that also permits
Okay, I get what you're saying about \z, sort of, assuming that the user
doesn't have to enter in the text at a prompt and you're not reading from a
file where lines are delimited by newlines, but I don't get where this ties
into security. Could you explain?
-Original Message-
From:
Timothy == Timothy Johnson [EMAIL PROTECTED] writes:
Timothy Okay, I get what you're saying about \z, sort of, assuming
Timothy that the user doesn't have to enter in the text at a prompt
Timothy and you're not reading from a file where lines are delimited
Timothy by newlines, but I don't get
Hey All,
Just wondering how I would go about extracting all the data from heading
1 (h1) in the following HTML code. I figured I could have used
HTML::TableExtract but then I realized ( :) ) there are not tables in
the following HTML. Would I now have to go ahead and use HTML::parser
or
I have some data which looks like this:
Key CPU Mirror
$AUDIT 8 Y
$AUDIT1 7 Y
$DATA1 7 Y
$DATA2 7 Y
$DATA3 6 Y
This data has already been sorted, but I
Here is one attempt:
$_ = 'mykey {{ abc xyz nnn mmm }} mykey2 {{ aaa bbb ccc ddd}}';
my @MyData = ();
while ( /\{{2}([a-z0-9\s]+)\}{2}/g ) {
push(@MyData, $1);
}
my $MyId = 1;
foreach ( @MyData ) {
printf %3d: %s\n, $MyId++, $_;
}
Output:
1: abc xyz nnn mmm
2: aaa
Daniel Falkenberg wrote:
Hi All,
I am just testing my Perl CGI script on Netscape browser at the moment
and I am getting a weird error occur. I can execute my script fine but
when I go to use a link in the script such as...
Hi Wags,
Whoops! That seems to solve the purpose.! But, How
do I read this data from a file into an array?!
Thanks
Bhanu.
$_ = 'mykey {{ abc xyz nnn mmm }} mykey2 {{ aaa bbb
ccc ddd}}';
my @MyData = ();
while ( /\{{2}([a-z0-9\s]+)\}{2}/g ) {
push(@MyData, $1);
}
my $MyId = 1;
Hi All,
I have a problem with the Perl format command.
If I use the '' for Justify left. I get the error message: Missing
right curly or square braket.
So this code below does not work:
format STDOUT =
ZIPPKG: @
$zippkg
NAME: @
$zippkgName
CATEGORY: @
Hi Dave,
My apologize for not getting back to the list sooner. I have figured
out exactly what my problem was. I didn't add the following into my
HTML code...
$nameofscript = perlscript.pl;
form method=post action=$nameofscript
Netscape didn't automatically use the script it was executing.
1 - 100 of 114 matches
Mail list logo