set (Not
very useful for my problem because regex is generic and simply designed
to achieve a statistical objective)
YAPE::Regex - Yet Another Parser/Extractor for Regular Expressions
YAPE::Regex::Explain
Mark.
On Fri, 2004-08-27 at 09:21, Chris Devers wrote:
On Fri, 27 Aug 2004, Mark Maunder
Hi,
I've google'd and CPAN'd and no luck. Is there a tool out there that
will generate a regular expression based on a series of string inputs
that are similar but have parts that differ. Ideally I'd like to be able
to create an regex generator object into which I can feed strings. Then
call a
G'day.
$string =~ s/(.{4})(?=.)/$1 /g;
FYI, the ?= at the end is a zero-width look ahead assertion that stops a
space from being inserted after the last 4 chars. Please see 'perldoc
perlre' for details.
Mark.
On Fri, 2004-08-27 at 05:51, JP wrote:
I am trying to split up a given string of
Hi,
I'm matching html using regex and use something like this to grab a
chunk of text up to the next html tag:
font([^]+)/font
But I'd like to say match everything that does not include the string
br rather than match everything that does not include a
character. Anyone got any suggestions?
Thanks Jeff, that helps. I use HTML::Parser for various tasks, but for
this particular one, I need exact matching, hence the regex.
On Mon, 2004-01-26 at 09:57, Jeff 'japhy' Pinyan wrote:
On Jan 26, Mark Maunder said:
I'm matching html using regex and use something like this to grab a
chunk
What are you trying to match? If it's just the dir name then:
/\/(tmp_\w)/ will do it and set $1 to equal your directory name.
~mark.
http://www.workzoo.com/
Zysman, Roiy wrote:
Hi All,
As we all know Regular Expressions are very greedy and tries to big as big
as possible.
How do i limit
You have two dollar signs before the 'name' variable in the loop. That probably works
provided the value of the variable is not a number, but it may be causing the
strangeness you're experiencing. Always 'use strict' in your scripts. You should be
storing your params in a hash and doing
Also, check out PerlMagick - a perl interface into the ImageMagick library of
image manipulation. The homepage is at:
http://www.imagemagick.org/www/perl.html
You can resize images to create thumbnails, and insert text into images (like your
site's URL for example) and do a bunch of other cool
Perhaps you learnt to program with something like Apple Basic like I did
nostalgia modewhen I was 10 years old on the Apple IIe/nostalgia
mode which requires line numbers. Perl doesn't need them.
gkotsovilis wrote:
How do you keep line numbering straight in a perl script.
--
To unsubscribe,
Hey Farshad,
Check out mod_perl at http://perl.apache.com/guide/
It's a persistent perl interpreter which offers all the features you've specified,
used by some major sites such as my own:
http://www.workzoo.com/
If you're looking for documentation see the Eagle book 'Apache modules in C and
[EMAIL PROTECTED] wrote:
Servlets are more scalable than CGIs and that is what is one of the biggest
advantages!
A Servlet is instantiated for the first request and any subsequent requests
to the same servlet spawns a separate thread, whereas CGIs are costly and
had to be instantiated
RAHUL SHARMA wrote:
Can anyone please help me if I can use threads in perl;
If yes then what all library files I have to include.
Thanks,
Rahul.
Perl supports threads, but it's not mature technology yet. You may need
to compile your own version of Perl as the default install doesn't
Hi,
How does one sort an array of strings by best match to a search string?
Search string could be: testing perl
Some elements (already sorted) could be:
1. testing perl functionality
2. test perl features
3. perl is useful
I guess I'm looking for something that you can use to compare a
Likewise from us in London. We have been glued to the news for the last two days,
haven't really been able to focus on anything productive. Our thoughts are with you
during this trying
time.
--
Mark Maunder
Senior Architect
SwiftCamel Software
http://www.swiftcamel.com
mailto:[EMAIL PROTECTED
This is probably an oldie, but assigning an undef to a hash creates a hash
with a single element (which I'm guessing is undef). Isn't this counter
intuitive. I would have expected the hash to be empty if the undef that is
assigned is in scalar context.
--
To unsubscribe, e-mail: [EMAIL
Thanks Troy and Bob. Your explanation makes perfect sense. I usually
dont code with perl -w, although I know I should and in this case it
would have saved me some trouble.
Bob Showalter wrote:
-Original Message-
From: Mark Maunder [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, August
says that it can't call method get_data() on an
unblessed reference. What should I do?
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
--
Mark Maunder
Senior Architect
SwiftCamel Software
http://www.swiftcamel.com
mailto:[EMAIL PROTECTED
The URL is what you're requesting. Unless you receive a redirect with
LWP::UserAgent, you must know what you're requesting. Either its the first
page you hit on the site, or you've grabbed the URL from an HREF in a
requested document. To avoid transparent redirects, subclass LWP::UserAgent
and
Hi Jon,
Your script should look something like this:
#!/usr/bin/perl
use CGI qw( :standard );
open(LOGFILE, logfile.txt) or die Can't open logfile: $!\n;
while($line = (LOGFILE)) #
{
chomp $line;
push(@links, $line);
#This was the main problem. You were doing
# $line = $link
Hi, I need some advice from someone who has cut their teeth on inheritance a
few times...
I'm using __PACKAGE__-method() to call a method that exists in a class
higher up the inheritance tree when $self in the current method is a blessed
object from a class lower down the inheritance tree
way to do this?
-Original Message-
From: Jeff 'japhy/Marillion' Pinyan [mailto:[EMAIL PROTECTED]]
Sent: Thursday, July 19, 2001 10:15 PM
To: Mark Maunder
Cc: Beginners@Perl. Org
Subject: Re: Is __PACKAGE__-method() the best way...
On Jul 19, Mark Maunder said:
I'm using __PACKAGE__-method
-
From: Michael Fowler [mailto:[EMAIL PROTECTED]]
Sent: Thursday, July 19, 2001 11:25 PM
To: Mark Maunder
Cc: Beginners@Perl. Org
Subject: Re: Is __PACKAGE__-method() the best way...
On Thu, Jul 19, 2001 at 10:20:48PM +0100, Mark Maunder wrote:
Also, calling SUPER:: on the original object wont
Sorry, just read the rest of your message.
Sortof. Grandfather has some utility methods in it that Son and Father both
use. Son calls a method (call it save() )which it has defined. Within this
method it uses one of the utility methods (lets call it
Grandfather::get_name() ) defined within
.
-Original Message-
From: Michael Fowler [mailto:[EMAIL PROTECTED]]
Sent: Friday, July 20, 2001 12:15 AM
To: Mark Maunder
Cc: Beginners@Perl. Org
Subject: Re: Is __PACKAGE__-method() the best way...
On Thu, Jul 19, 2001 at 11:31:20PM +0100, Mark Maunder wrote:
But I still want to know if __PACKAGE__
24 matches
Mail list logo