All pastes #367704 Raw Edit

Unnamed

public text v1 · immutable
#367704 ·published 2007-02-22 15:02 UTC
rendered paste body
my $z     = 5; 
my $child = 0;
foreach my $paraa (@price)
{
  $z++;
  if(defined($paraa->att('adult')) && $paraa->att('adult')*1)
  {
    $insert->bind_param($z, $paraa->att('adult'));
  }
  elsif (defined($paraa->att('child')) && $paraa->att('child')*1)  
  {
    $insert->bind_param($z, '');
    $insert->bind_param(9, $paraa->att('child'));
    $child = 1;
  }
}
$insert->bind_param($z, '') for ($x=$z;$x<10;$x++);
$insert->bind_param(9, '') if (! $child);