Re: Perfecting index.pl some more!
- From: Brian McCauley <nobull@xxxxxxxx>
- Date: Sat, 30 Apr 2005 13:29:51 +0100
Nikos wrote:
Also maybe thre is a better wau to create the $data variable instead of constant concatenations as i have it.
You mean like where you say:
$data = "Charset I lack " .$host. "! more stuff";
Well it's more ideomatic to use interpolation:
$data = "Charset I lack $host! more stuff";
$sth = $dbh->prepare( $sql{update_visitor} );
$sth->execute($host);
Since you don't use that statment handle again after the execute() you may want to condisder the shorthand form:
$dbh->do( $sql{update_visitor}, {}, $host); else
{
if ($host ne "Íßêïò")
{
You may want to consider elsif (that's not a typo, there really is no 'e' in Perl's spelling of 'elseif').
.
- Follow-Ups:
- Re: Perfecting index.pl some more!
- From: Nikos
- Re: Perfecting index.pl some more!
- References:
- Perfecting index.pl some more!
- From: Nikos
- Re: Perfecting index.pl some more!
- From: Tassilo v. Parseval
- Re: Perfecting index.pl some more!
- From: Nikos
- Perfecting index.pl some more!
- Prev by Date: Re: multiples ifs
- Next by Date: Re: Module file writing problem
- Previous by thread: Re: Perfecting index.pl some more!
- Next by thread: Re: Perfecting index.pl some more!
- Index(es):