Help for this page

Select Code to Download


  1. or download this
    if (/From:/) {
      m/^\w+:(\S+)$/ && push my @addr, Mail::Address->parse($1);
      $address = $addr[0]->address;
      $debug_text .= "Found $address at line $.\n";
    }
    
  2. or download this
           s/PATTERN/REPLACEMENT/egimosx
                       s   Treat string as single line.
                       g   Replace globally, i.e., all occurrences.
    
  3. or download this
    if (/^From:(\S+)$/) {
      push my @addr, Mail::Address->parse($1);
      $address = $addr[0]->address;
      $debug_text .= "Found $address at line $.\n";
    } else { next }