1 batch_example.module _batch_example_get_http_requests()

Utility function to count the HTTP requests in a session variable.

Return value

int Number of requests.

Related topics

File

modules/examples/batch_example/batch_example.module, line 312
Outlines how a module can use the Batch API.

Code

function _batch_example_get_http_requests() {
  return !empty($_SESSION['http_request_count']) ? $_SESSION['http_request_count'] : 0;
}