Exemplo n.º 1
0
            if (ctype_lower($changing)) {
                capitalizeAndFind($newGoal, $i);
            }
        }
    }
}
$input = null;
if (array_key_exists(1, $argv)) {
    $input = $argv[1];
}
$goal = find_address($input);
if ($goal) {
    echo "Seeking Address Matching: ", $goal, "\n\n";
    capitalizeAndFind($goal, 1);
} else {
    $decoded = $bitcoin->decodeBase58($input);
    $length = strlen($decoded);
    if (!$input) {
        echo "Error: Missing address pattern.\n";
    } else {
        if (!$decoded) {
            echo "Error: Invalid characters in address pattern.\n";
        } else {
            if (!($length == 50)) {
                echo "Error: Address with decoded length of ", $length, " is impossible.\n";
                echo "Please try again, the length must be exactly 50.\n";
            } else {
                echo "Unknown Error.\n";
            }
        }
    }