Re: Calculate the distance between 2 coordinates

2002-01-10 Thread Mel Matsuoka
try. Two words: Pythagorean Theorem :) Aloha, mel -- mel matsuoka Technical Director/Trained Primate Hawaiian Image Productions [vox] +1 808.531.5474 [fax] +1 808.526.4040 [e-mail] [EMAIL PROTECTED] [www] http://www.hawaiianimage.com -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands,

Re: Any quicker way of writing the following...?

2001-11-26 Thread Mel Matsuoka
'user', 'password'); foreach my $reset_key (@reset_keys) { foreach my $U (keys %PASS) { $PASS{$U}{$reset_key} = undef; } } HTH..aloha mel -- mel matsuoka[EMAIL PROTECTED] Head Geek

Re: off topic - javascript question

2001-10-29 Thread Mel Matsuoka
t=400")> > Try comp.lang.javascript instead. This is the wrong forum for Javascript questions, even if you declare "off topic" in the subject header. Cheers, mel -- mel matsuoka (vox)1.808.531.5474 Head Geek (fax)1.80

Re: Need help with CGI module

2001-10-28 Thread Mel Matsuoka
At 01:12 AM 10/28/01 -0700, Dave Turner wrote: >I have scanned the docs and can't seem to find the answer to this anywhere. > >I want to change the color of the text and the font size on a web page >using CGI:pm. > >my code looks like: > >$q->h2( "Something witty here"); > >but I'd like to have t

Re: no luck pie charts and perl

2001-10-25 Thread Mel Matsuoka
erldoc strict Turning on strict mode requires that you declare your variable scope before using them. This is the source of your errors. Aloha, mel -- mel matsuoka (vox)1.808.531.5474 Head Geek (fax)1.808.526.4040 Hawaiian Image Prod

Re: finding text in a gif image

2001-10-20 Thread Mel Matsuoka
f all you want to do is "crop" the text out the image, it's extremely easy using GD.pm Aloha, mel -- mel matsuoka (vox)1.808.531.5474 Head Geek (fax)1.808.526.4040 Hawaiian Image Productions [EMAIL

Re: Don't print...

2001-10-03 Thread Mel Matsuoka
;/etc/ppp/ppp"); Probably something in your ifconfig routine is sending its output to STDOUT... Aloha, mel -- mel matsuokaHawaiian Image Productions Chief Executive Alphageek (vox)1.808.531.5474 [EMAIL PROTECTED] (fax)1.808.526.4040

Re: Please Stop (was: Re: eval problem)

2001-10-02 Thread Mel Matsuoka
ing a simple task done, when said newbie is still in the stages of learning the core language and methodologies first. I can imagine this is why many people are turned off by Perl because they see a lot of compact, "read only" code written by experienced Perl jockeys :) Just my

Re: Please solve the problem

2001-09-26 Thread Mel Matsuoka
instead of trying to re-invent this particular wheel. I personally dont use Webmin, cause it still freaks me out to be doing root-level configurations using a webbrowser, unless you restrict access only to localhost. HTH, Aloha, mel -- mel matsuokaHawaiian Image P

Re: printing out yesterdays date

2001-09-26 Thread Mel Matsuoka
ould just use Date::Calc, but thats just not as fun ;) Aloha, mel -- mel matsuokaHawaiian Image Productions Chief Executive Alphageek (vox)1.808.531.5474 [EMAIL PROTECTED] (fax)1.808.526.4040 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For a

Re: how to open a .iso file

2001-09-19 Thread Mel Matsuoka
even bother to refer the OP to >dictionary.com) ( none of that - pesonal) >(obviously I don't know the rules of borderline vulgarity on this list, >hope i don't get kicked off...) Actually, either way is wrong. You should know by now that spelling-flames are the hallmark of a newbie

Re: DBI limitations

2001-09-19 Thread Mel Matsuoka
i script. Please show us your code so we can help you better. I have used DBI for everything as simple as a 3 field table all the way up to a ridiculous 20 field table, so your problem is almost certainly an issue with errors in your Perl code, and not DBI itself. What DBD are you using, btw? A

Re: how to open a .iso file

2001-09-19 Thread Mel Matsuoka
At 05:30 PM 09/19/2001 +0200, Andy McDowell wrote: >Spam... since when was asking questions and wanting to learn something spam?? > Asking questions and wanting to learn is not spam. Crossposting your questions to multiple unrelated mailing lists, on the other hand, technically IS spam and con

Re: how to open a .iso file

2001-09-19 Thread Mel Matsuoka
ink it was entirely inappropriate for some people to flame the OP in the manner that they did. This is not comp.lang.perl.misc., if you want to be a bully to newbies, then you probably should hang out there instead ;) Aloha, mel -- mel matsuokaHawaiian Image Productions

Re: Perl - charts/graphs??

2001-09-17 Thread Mel Matsuoka
abel placement) that forces me to create my own GD drawing routines to work around. aloha, mel -- mel matsuoka Hawaiian Image Productions Chief Executive Alphageek(vox)1.808.531.5474 [EMAIL PROTECTED](fax)1.808.526.4040

Re: help - what is this?

2001-08-21 Thread Mel Matsuoka
iously off-topic here. As such, your logic about HTML questions doesn't follow. For HTML related questions, I would highly recommend the Webmonster (formerly Lynda Weinman's) webdesign-l . http://www.webmonster.net Aloha, mel -- mel matsuokaHawaiian Image Produc

Re: Graphing with PERL and HTML

2001-08-16 Thread Mel Matsuoka
priciated. Use GD::Graph. http://search.cpan.org aloha, mel -- mel matsuoka Hawaiian Image Productions Chief Executive Alphageek(vox)1.808.531.5474 [EMAIL PROTECTED](fax)1.808.526.4040 -- To unsubscribe, e-mail: [EM

Stumped over GD::Text strangeness....

2001-08-16 Thread Mel Matsuoka
halign => 'left', color => $gd_black); $align->set_text($textstring); $align->set_halign($alignment); $align->set_valign('top'); # $align->set_font(gdGiantFont); # works when value is

Re: Check file permissions

2001-08-09 Thread Mel Matsuoka
At 03:47 PM 08/09/2001 -0500, Baartmans, Hans wrote: >Is there a module or command that returns the permissions of a file or >directory? > >Thanks, >Hans use the stat() function. Aloha; mel -- mel matsuokaHawaiian Image Productions Chief Exec

Re: Image not coming in perl script while displaying n simple html with the same path..Why?

2001-08-09 Thread Mel Matsuoka
will not be allowed to access it, for security reasons. Save your images under the normal webserver document-root and reference them in your HTML using relative or absolute paths. Aloha, mel -- mel matsuokaHawaiian Image Productions Chief Executive Alphageek (vo

Re: After I load Perl

2001-08-08 Thread Mel Matsuoka
At 08:29 AM 08/08/2001 -0600, Kent Mercer wrote: >How do I begin my first script? > >And how do I save it ? > >Something simple like "Hello World" > >Just started 2 days ago >Need pointed in the right direction Check out the resources and FAQs located at http://www.perl.com Theres a plethora o

Re: Creating a hash

2001-08-08 Thread Mel Matsuoka
At 03:15 PM 08/08/2001 -0700, Sofia wrote: >I have the following hash of first names and last >names: > >%hash = ( > joe => "smith", > jim => "jones", > sof => "comes", >); > >If for example, jim now has two last names ie jones >taylor, how do I represent that on the hash? You'd basically w

Re: Graphs in perl ....

2001-08-08 Thread Mel Matsuoka
st stop before asking about the existence of a module :) aloha, mel -- mel matsuokaHawaiian Image Productions Chief Executive Alphageek (vox)1.808.531.5474 [EMAIL PROTECTED] (fax)1.808.526.4040 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For addition

Re: Is there an easy way to reject certain types of input?

2001-08-08 Thread Mel Matsuoka
At 02:52 AM 08/08/2001, Mel Matsuoka wrote: > >You should optimize this code by using a dispatch table, which is basically >a hash which maps keys to references to subroutines: > > %menuChoices = ( '0' => \&readFile, >

Re: Is there an easy way to reject certain types of input?

2001-08-08 Thread Mel Matsuoka
erence the subroutine mapped to $menuchoice $menuChoices{$menuchoice}->(); } else { $lastMsg = "That was not a valid choice!"; callMenu(); } HTH..Aloha, mel -- mel matsuokaHawaiian Image Productions Chief Executive Alphageek (vox)1.808.531.5474 [EMAIL PROTECTED] (fax)1.808.526.4040 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

Re: very funny...

2001-08-07 Thread Mel Matsuoka
ortant as the process you took in order to arrive at that answer. Aloha, mel -- mel matsuoka Hawaiian Image Productions Chief Executive Alphageek(vox)1.808.531.5474 [EMAIL PROTECTED](fax)1.808.526.4040 -- To unsubscr

Re: very funny...

2001-08-07 Thread Mel Matsuoka
red. Every moment of emotional energy you spend being "offended" at faceless people on the internet is time wasted on otherwise learning valuable lessons. just my unsolicited .02 Aloha -- mel matsuoka Hawaiian Image Productions Chief Executive Alph

Re: database connectivity

2001-08-06 Thread Mel Matsuoka
ser of Win32::ODBC, I recommend giving DBI a try instead, using the DBD::ODBC driver. You'll thank yourself down the road when you need to port this code over to another DBMS. I find DBI much more convenient to use than Win32::ODBC...though I suppose of you need to do real

Re: isEmail function

2001-08-05 Thread Mel Matsuoka
perlfaq(9). A better, more workable alternative would be to check for a valid MX record for the given domain name. Aloha, mel -- mel matsuokaHawaiian Image Productions Chief Executive Alphageek (vox)1.808.531.5474 [EMAIL PROTECTED] (fax)1.808

Re: Reading file line by line regardless of type of end-of-line?

2001-08-05 Thread Mel Matsuoka
er got around to using it (and /learning it) on that box...then again I never had a use for it, since AOS had that cool built-in ARexx interprocess scripting language (like Applescript). Ah, I sort of miss the good ol' days of the Video Toaster on my A2000 (souped up with a BLAZING Zeus 680

Re: Your vendor has not defined Fcntl macro

2001-08-01 Thread Mel Matsuoka
state Perl on Win98. IRCd on a Windows box eh? You certainly are a masochist :) Cheers, Mel (aka Mr_Me on Afternet) -- mel matsuokaHawaiian Image Productions Chief Executive Alphageek (vox)1.808.531.5474 [EMAIL PROTECTED] (fax)1.808.526.404

Re: sending mail (learning perl program)

2001-07-30 Thread Mel Matsuoka
At 10:56 AM 07/30/2001, Mel Matsuoka wrote: >At 01:39 PM 07/30/2001 -0700, [EMAIL PROTECTED] wrote: >>> "Stephen P. Potter" <[EMAIL PROTECTED]> said: >> >>> | >>> | open (MAIL, "|/usr/sbin/sendmail $email") >>> |

Re: sending mail (learning perl program)

2001-07-30 Thread Mel Matsuoka
lity waiting to be exploited. What if the user-supplied value of $email was something like ";rm -rf ." ? Not good. You should really be using sendmail with the -t flag to avoid shell exploits like this. Aloha, mel -- mel matsuoka Hawaiian Image Productions Chief Ex

Re: Using Perl with Apache

2001-07-29 Thread Mel Matsuoka
At 03:14 PM 07/29/2001 -1000, . wrote: >I'm currently running a RedHat 7.1 box, with Perl 5.005 (I think), and >Apache webserver 1.3.12. > >My problem is that, after having followed the directions for configuring >Apache to handle cgi scripts (from both www.apache.org and the httpd.conf >documenta

Re: CGI to rewrite a URL

2001-07-27 Thread Mel Matsuoka
t's probably easy to do, but my experience with CGI is next to >nothing. If you're using Apache (and you realy should if you aren't :)), you might want to look into mod_rewrite. Aloha, mel -- mel matsuokaHawaiian Image Productions Chief Executive Alphageek

Re: Whole Script, global symbol?

2001-07-25 Thread Mel Matsuoka
$action )= split(/\t/); You need to declare your variable scope using 'my'. The strict pragma spanks you if you use global variables without specifically intending it: my($email, action) Aloha, mel -- mel matsuoka Hawaiian Image Productions Chief Execu

Re: Linux commands in perl

2001-07-25 Thread Mel Matsuoka
At 01:33 AM 07/25/2001, Mel Matsuoka wrote: >Off the top of my head, perhaps a more secure method would be to have your >CGI script serve as a "wrapper" to pass username/passwd data to another >script (which has root or sudo root execute permissions) which is located >out

Re: Linux commands in perl

2001-07-25 Thread Mel Matsuoka
l world experience with them so I couldnt attest to thier security. HTH, aloha, mel -- mel matsuokaHawaiian Image Productions Chief Executive Alphageek (vox)1.808.531.5474 [EMAIL PROTECTED] (fax)1.808.526.4040 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

Re: Which perl book is the best for a newbie?

2001-07-25 Thread Mel Matsuoka
At 04:41 PM 07/25/2001 +0900, Super Newbie wrote: >Which Perl book is the best for a newbie? Any recommendation? > "Elements of Programming with Perl" from Andrew Johnson. "Learning Perl" by Randal Schwartz. Both books rock. Aloha, mel -- mel matsuoka

RE: basename ?

2001-07-24 Thread Mel Matsuoka
At 01:48 PM 07/24/2001 -0500, Mooney Christophe-CMOONEY1 wrote: >Why not just use a regex? > >($basename)=$file_string=~m!([^/]+)$!; Why not just use File::Basename? ;) Aloha, mel -- mel matsuokaHawaiian Image Productions Chief Executive Alphageek

Re: stupid question

2001-07-19 Thread Mel Matsuoka
!/usr/bin/perl -w use CGI; use strict; my $q = new CGI; print $q->header; print "Hello World!\n"; Also remember to ALWAYS use strict and -w, no matter how trivial the script. HTH..aloha, mel -- mel matsuoka Hawaiian Image Productions Chief E