Function __global->_compare_ip_address

Definitions

sources/global3.php

  • Compare two IP addresses for potential correlation, pre-exploded. Not as simple as equality due to '*' syntax.
  • Visibility: public
  • Is abstract?: No
  • Is static?: No
  • Is final?: No
  • Returns: bool

Parameters

Name Type Passed by reference? Variadic? Default Set Range Description
$wild string No No required parameter N/A N/A The general IP address that is potentially wildcarded
$full_parts array No No required parameter N/A N/A The exploded parts of the specific IP address we are checking
$delimiter string No No required parameter N/A N/A The delimiter

Returns

  • Whether the IP addresses correlate
  • Type: boolean
  • Set: N/A
  • Range: N/A

Preview

Code (PHP)

/**
 * Compare two IP addresses for potential correlation, pre-exploded. Not as simple as equality due to '*' syntax.
 *
 * @param  string $wild The general IP address that is potentially wildcarded
 * @param  array $full_parts The exploded parts of the specific IP address we are checking
 * @param  string $delimiter The delimiter
 * @return boolean Whether the IP addresses correlate
 */

function _compare_ip_address(string $wild, array $full_parts, string $delimiter) : bool