Aye. I once made a simple program, just for calculating + and *. I had no
problem with that. Which means somethin' like:
#!usr/bin/perl
print "Enter a number.";
$number = ;
# *ing by 2 (can't get to the right word)
$result = $number * 2;
print "Aye, the result is" . $result;
Which you could do
Hiya!
First of all, hope you had a merry christmas and you will have a happy new
year. Okay, so I'm a beginner, but I'm trying to get some more experince
with Perl (although I use CGI, anyway). (I'm trying to get a job soon so I
can buy my own computer and I'll use Linux/XP so... ;))
Anyway, I
Oops, it's only for Linux. But it looks good. I'll certainly recommend it
for Linux ppl :)
--
Bob Erinkveld (Webmaster Insane Hosts)
www.insane-hosts.net
MSN: [EMAIL PROTECTED]
From: [EMAIL PROTECTED]
To: "Paul Kraus" <[EMAIL PROTECTED]>, "'Perl'" <[EMAIL PROTECTED]>
Subject: RE:
Looks great! I think I'll be giving it a try. I forget things all the time
;)
--
Bob Erinkveld (Webmaster Insane Hosts)
www.insane-hosts.net
MSN: [EMAIL PROTECTED]
##
Well it is probably off topic, but a good discussion anyways. Seems like
some combination of cvs/rcs+bugzilla
Hi there!
I've got a problem. I scripted a nice guestbook script. All working fine,
and then I thought about adding smilies to the script. Now, the only
solution doing this is using tr/// or s///. Tried both, no effect. I really
tried a lot, but still getting some errors. So, I thought, adding
Yeam it's pretty vague. But maybe he needs concentating:
$var = "boo!";
$var .= "eek!";
$var .= "\n";
$var .= "were you scared?";
print $var;
Which will print something like:
boo! eek!
were you scared?
--
Bob Erinkveld (Webmaster Insane Hosts)
www.insane-hosts.net
MSN: [EMAIL PROTECT
No, it's not hard. vec and ord are simply used for translating ASCII
characters to their corresponding characters, well, let's say, numbers.
Say like %20 represents a space. Anyway, check out:
perldoc -f vec
perldoc -f ord
It's really simple :)
--
Bob Erinkveld (Webmaster Insane Hos
I love HTML-kit :-)
_
Ontvang je Hotmail & Messenger berichten op je mobiele telefoon met Hotmail
SMS http://www.msn.nl/jumppage/
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
Yes, I am having the same problem. I don't write much scripts (I'm a newbie)
but when I do, open() doesn't seem to work. I'm pretty sure it has to work
on Windows, but...
--
Bob Erinkveld (Webmaster Insane Hosts)
www.insane-hosts.net
MSN: [EMAIL PROTECTED]
From: Jeff Westman <[EM
0:39 +0100
From: "John W. Krahn" <[EMAIL PROTECTED]>
> Mystik Gotan wrote:
> >
> > Hi there,
>
> Hello,
>
> > another basic Perl question up here. The last time I've seen quite
> > some code using die horribly;. Actually, I've never seen this
Hi there,
another basic Perl question up here. The last time I've seen quite some code
using die horribly;. Actually, I've never seen this before. Is this a new
built-in for 5.8.0? What I want to know, is wat it does. I'm sure it can't
be some text, I have an idea, but I'm not sure. Please, I j
I suggest you take a look @ http://lists.perl.org. They have all official
mailing lists up there. And there are archives, too:
http://archive.develooper.com (or archives, check it out yourself). Ooh, got
some itch there ;-)
--
Bob Erinkveld (Webmaster Insane Hosts)
www.insane-host
$var =~ s/^\,$/|/;
--
Bob Erinkveld (Webmaster Insane Hosts)
www.insane-hosts.net
MSN: [EMAIL PROTECTED]
From: Danny Grzenda <[EMAIL PROTECTED]>
To: "'[EMAIL PROTECTED]'" <[EMAIL PROTECTED]>
Subject: regex help
Date: Thu, 12 Dec 2002 12:52:59 -0600
DB4515C,625.25,378,327,382,
for ($i=0; $i<1024; $i++) {
if ($var =~ /^\\r\\n$/) {
$var =~ s/^\\r(\\n)$/$1/;
}
# First time using $1! Hope it works =)
}
Well, and the for loop ensures the file isn't bigger as 1024, 1mb.
--
Bob Erinkveld (Webmaster Insane Hosts)
www.insane-hosts.net
MSN: [EMAIL PROTECTE
I'd be using:
#!/usr/bin/perl -w
$dir = "/backup";
opendir BACKUPDIR, $dir or die "Cannot open $dir!";
foreach (readdir BACKUPDIR){
unless ($_ eq "." or $_ eq ".."){
#print "$_";
push (@dirs,$_);
}
foreach (@dirs) {
print "$_\n";
}
}
--
Bob Erinkveld (Webmaster Insa
Stuff the variable names into an array, use a regex to delete all the
slashes (as you will declare the names with a slash in front of it).
Or anything like that. Actually, I think the syntax is ok. I'm sure local()
can do this, so why can't my? Just try to accomplish something else with
this con
perldoc -f stat
--
Bob Erinkveld (Webmaster Insane Hosts)
www.insane-hosts.net
MSN: [EMAIL PROTECTED]
From: <[EMAIL PROTECTED]>
To: [EMAIL PROTECTED]
Subject: checksum implementation in perl
Date: Thu, 12 Dec 2002 10:48:46 -0500
Hello,
How do I compute the checksum of a binar
I am running on Windows and don't have much to automate for my own. I am
trying to write Perl scripts on the Internet for all the things I need. I
could've choose PHP, but I began learning Perl and it wasn't a bad choice. I
am sure everything done with PHP can be done with Perl. And Perl has muc
Using cgi.pm, I suggest you use HTML to provide this interactivity, As Perl
has no function for this.
--
Bob Erinkveld (Webmaster Insane Hosts)
www.insane-hosts.net
MSN: [EMAIL PROTECTED]
From: "Jose Vicente Paredes Loor" <[EMAIL PROTECTED]>
Reply-To: [EMAIL PROTECTED]
To: <[EM
Hiya,
most mailing lists (especially perl) are accessible through News Groups.
You can acces news groups with Outlook (or any other), however, many are
accessible through the internet. If I'm correct, they also have a search
function, which is exactly what you're looking for. You declared as typ
EMAIL PROTECTED]
From: Max <[EMAIL PROTECTED]>
To: Mystik Gotan <[EMAIL PROTECTED]>
CC: [EMAIL PROTECTED]
Subject: Re: Spreadsheet::ParseExcel date problem (year is being
reformatted)
Date: Thu, 12 Dec 2002 10:10:16 +0100
My e-mail was changed, I use bold to highlight yy (02) and yyy
#!usr/bin/perl -wT
use strict;
print("$$");
OR
#!usr/bin/perl -wT
use strict;
use English;
print "$PID"; # or $PROCESS_ID. English.Pm simply changes a system variable
into an english word..
--
Bob Erinkveld (Webmaster Insane Hosts)
www.insane-hosts.net
MSN: [EMAIL PROTECTED]
And sprintf(), format().
--
Bob Erinkveld (Webmaster Insane Hosts)
www.insane-hosts.net
MSN: [EMAIL PROTECTED]
From: "Paul Kraus" <[EMAIL PROTECTED]>
To: "'Mariusz'" <[EMAIL PROTECTED]>, "'perl'" <[EMAIL PROTECTED]>
Subject: RE: formatting output
Date: Thu, 12 Dec 2002 07:59:54
[EMAIL PROTECTED]
--
Bob Erinkveld (Webmaster Insane Hosts)
www.insane-hosts.net
MSN: [EMAIL PROTECTED]
From: "NYIMI Jose (BMB)" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>, <[EMAIL PROTECTED]>
Subject: RE: Searchable archive?
Date: Wed, 11 Dec 2002 18:34:41 +0100
An other opt
Hmm. You could try to declare a variabele on STDOUT...
Any more, I dunno...
--
Bob Erinkveld (Webmaster Insane Hosts)
www.insane-hosts.net
MSN: [EMAIL PROTECTED]
From: "Adam Wilson" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Subject: include .pl in html
Date: Tue, 10 Dec 2002
How about using HTML?
$var
Put that in a var and print it out. Ofcourse, set content-type to text-html.
--
Bob Erinkveld (Webmaster Insane Hosts)
www.insane-hosts.net
MSN: [EMAIL PROTECTED]
From: "Paul Kraus" <[EMAIL PROTECTED]>
To: "Perl" <[EMAIL PROTECTED]>
Subject: Center
Regex?
$var =~ s/\b\**\**\b//; # deletes *
--
Bob Erinkveld (Webmaster Insane Hosts)
www.insane-hosts.net
MSN: [EMAIL PROTECTED]
From: Max <[EMAIL PROTECTED]>
To: [EMAIL PROTECTED]
Subject: Spreadsheet::ParseExcel date problem (year is being reformatted)
Date: Tue, 10 Dec 2002
Use eval and check $@ for error checking.
--
Bob Erinkveld (Webmaster Insane Hosts)
www.insane-hosts.net
MSN: [EMAIL PROTECTED]
From: "Paul Kraus" <[EMAIL PROTECTED]>
To: "'Perl'" <[EMAIL PROTECTED]>
Subject: Return Status
Date: Tue, 10 Dec 2002 17:27:36 -0500
instead of setti
@stat = stat $file;
$time = @stat[10];
print $time;
--
Bob Erinkveld (Webmaster Insane Hosts)
www.insane-hosts.net
MSN: [EMAIL PROTECTED]
From: "Jerry Preston" <[EMAIL PROTECTED]>
Reply-To: <[EMAIL PROTECTED]>
To: "Beginners Perl" <[EMAIL PROTECTED]>
Subject: file time
Date: We
ts.net
MSN: [EMAIL PROTECTED]
From: Geraint Jones <[EMAIL PROTECTED]>
To: "Mystik Gotan" <[EMAIL PROTECTED]>, [EMAIL PROTECTED],
[EMAIL PROTECTED], [EMAIL PROTECTED]
Subject: Re: How to get the biggest integers from an array?
Date: Tue, 10 Dec 2002 14:39:42 +
Use
Maybe you're trying to accomplish this:
while ($id == $sth->fetchrow_array) {
I'm pretty sure this will cause the error you're looking for.
--
Bob Erinkveld (Webmaster Insane Hosts)
www.insane-hosts.net
MSN: [EMAIL PROTECTED]
From: Robbie Staufer <[EMAIL PROTECTED]>
To: [EMA
Hiya,
I'm in search for a solution. Let's say I have this array:
@array (5, 6, 7, 89, 1, 0, 456, 298023, 56);
Now, how can I get the biggest integers from this array and give them a
string with their place. Let's say I have a foreach loop where I checked all
the biggest integers (however, I do
If not using length() direcly on @world_list:
@word_list = qw(bla bla bla bla bla joah hey);
foreach $element (@word_list) {
local($content);
my(@lengths);
$content = length($element);
push(@lengths, $element); # or different order, I always forgot this :)
}
--
Bob Erinkveld (Webma
For one, I would use the -d flag to use debugging options and set $^D to
whatever you want.
--
Bob Erinkveld (Webmaster Insane Hosts)
www.insane-hosts.net
MSN: [EMAIL PROTECTED]
From: Mark Goland <[EMAIL PROTECTED]>
To: perl <[EMAIL PROTECTED]>
Subject: linked list's
Date: Sun,
Hiya.
Salt is just a thing which helps you encoding the stuff.
From a book:
The crypt Function
The crypt function encrypts a string using the NBS Data Encryption Standard
(DES) algorithm.
The syntax for the crypt function is
result = crypt (original, salt);
original is the string to be
Hiya,
is there any difference between $count++ and ++$count?
Just wondering.
Thanks.
_
Ontvang je Hotmail & Messenger berichten op je mobiele telefoon met Hotmail
SMS http://www.msn.nl/jumppage/
--
To unsubscribe, e-mail: [EM
I'm not very sure if it works.
I'd rather concentate the whole thing.
$Hash{"User"} = $ANumber;
$Hash{"Page"} .= $ANumber;
$Hash{"NumTimesVisited"} .= $ANumber;
Also note that you should be using $ in your HashKey calls!
--
Bob Erinkveld (Webmaster Insane Hosts)
www.insane-hosts.net
ftp://ftp.cpan.org/pub/CPAN/src/perl-5.8.0.tar.gz
--
Bob Erinkveld (Webmaster Insane Hosts)
www.insane-hosts.net
MSN: [EMAIL PROTECTED]
From: "Paul Kraus" <[EMAIL PROTECTED]>
To: "Perl" <[EMAIL PROTECTED]>
Subject: Newest Version
Date: Thu, 5 Dec 2002 14:40:46 -0500
I see that
It is just the enviroment where you're work. Perl is mostly used on Internet
in association with CGI and Lunix. C/C++ and Python are both used as
programming languages, mostly on whatever platform you want.
These are about the 3 most difficult languages you can imagine.
When trying to make some
Hi.
I'm a young (14, dutch) Perl Programmer (or so however you may call, some
call me, some might don't ;)). Anyway, I'm getting a 500 error on my script.
I changed some things, like print content type in subs, and I put the HTML
form in the script. But no changes for the ISE error. Hope you gu
I suggest using fork() and kill(). Check out perldoc for more info about
this.
--
Bob Erinkveld (Webmaster Insane Hosts)
www.insane-hosts.net
MSN: [EMAIL PROTECTED]
From: Ringo Harmsen <[EMAIL PROTECTED]>
To: [EMAIL PROTECTED]
Subject: Run proces i the background from a running
I can't really figure out what the purpose of wantarray() is.
Can someone please give me a good, decent explanation?
Thanks in advance :-)
--
Bob Erinkveld (Webmaster Insane Hosts)
www.insane-hosts.net
MSN: [EMAIL PROTECTED]
___
No. Use warnings is a module, the -w flag is just some extra for error
trapping (which sometimes really is useful!). But it's alright using both
(along with strict, ofcourse). So -w is a built in 'function' and
warnings.pm is just a module.
(BTW, using the -T flag for Taint Checking can also pr
What do you mean with piece? I know you're way better than me, but why don't
write your pieces (in which case I think output) to STDOUT.
Like:
@array = ('piece', 'of', 'you');
print STDOUT, @array;
Don't think this really helps you, maybe others do :)
--
Bob Erinkveld (Webmaster Ins
Using the 'x' operator, you can use spaces in your matching pattern:
m/^[a-zA-Z]{0,20} [A-Za-z]{0,20}$/x
m/^[a-zA-Z]{0,20}\s [A-Za-z]{0,20}$/
Ofcourse, the +,?,* and so on could be used also for determing the character
count.
m/^\'$/
Maybe this helps you.
Cheers
--
Bob Erinkveld (W
What's the use of "symbolic links" (symlink() ) and usual, normal
"links"(link())?
I don't really understand. I know what it does, but I can only imagine 50%
of what the use is for. Asking because, maybe, it's important ;-)
(I haven't worked with it before and haven't seen any scripts working w
What is while(1) { # code } used for? I know it has something to do with
zero and nonzero values, meaning, if a certain opperation is succeeded or
not. However, my question is, what opperation?
_
Surf voor nieuws, fileinformatie &
My last question... It's getting a bit too much.. I'm sorry for asking so
much.. But I find it quite hard to understand the map() function. Can
anybody explain this?
Again, apologise for asking so much. But I'm just a 14 year old Dutch boy so
sometimes it's a bit hard to follow the English refe
Sorry for bothering all the time, hope you guys don't mind.
What's the use of { # code here # }. I thought this would be intentionally
used for complex code constructions. Do you agree?
Sincerly,
Bob Erinkveld
(Webmaster Insane Hosts)
www.insane-hosts.net
__
What does the underscore exactly do, when using _var?
Example:
package Person;
use Carp;
our $AUTOLOAD; # it's a package global
my %fields = (
name=> undef,
age => undef,
peers => undef,
);
sub new {
my $that = shift;
my $cla
Hiya,
I got some basic Perl questions. Hope you don't mind answerring them?
1) What is the use of just putting $var; on 1 line? Example:
#!usr/bin/perl -wT
# some code
$var;
Does this technique rescopes the variable?
2) Why is exit() or 1; used on the LAST line. I understand it being on some
l
Maybe you should use a foreach loop spitting every character and then
parsing the \ in front of it?
Sincerly,
Bob Erinkveld
(Webmaster Insane Hosts)
www.insane-hosts.net
From: "Jason Rauer" <[EMAIL PROTECTED]>
To: [EMAIL PROTECTED]
Subject: Characters instead of regex patterns
Date: Sat, 2
52 matches
Mail list logo