Regexpr FTP

From: MC (madcow_at_false)
Date: 02/04/05

  • Next message: John Silver: "Generate UUID"
    Date: Fri, 4 Feb 2005 10:31:05 +0100
    
    

    Hi,

    i'm trying to make a regexpr wether an ftp-input is valid or not.
    this is what i have:

    $var = "ftp://user:pass@localhost:21";
    if ( $var =~ /^ftp:\/\/([^:]*):([^@]*)@([^:]*):(.*)$/i ) { print
    "$1:$2@".$3.":$4\n"; }Can anyone tell me if something is wrong with
    this?For some reason it won't accept the "@" in the middle,if i replace it
    with "!" for example the expr works just fine.i've also tried escaping it,
    also no luck.Thanks


  • Next message: John Silver: "Generate UUID"