SproutCMS

This is the code documentation for the SproutCMS project

function getHitCount()

Return the number of hits matching given conditions for a given time period

Usage

int RateLimit::getHitCount ( array $conditions , int $time );

Arguments

  1. array $conditions
    Conditions to match, e.g. 'event', 'success', 'username', 'ip_address' fields
  2. int $time
    Time to check in seconds, e.g. 3600 for one hour

Return value

  • int
    Number of hits