You are here

function simplenews_statistics_click in Simplenews Statistics 6

Same name and namespace in other branches
  1. 6.3 simplenews_statistics.module \simplenews_statistics_click()
  2. 6.2 simplenews_statistics.module \simplenews_statistics_click()

simplenews_statistics_click.

Gathers the clicks

1 string reference to 'simplenews_statistics_click'
simplenews_statistics_menu in ./simplenews_statistics.module
Implementation of hook_menu().

File

./simplenews_statistics.module, line 74
Gathers newsletter statistics.

Code

function simplenews_statistics_click() {
  if ($_GET['mail'] && $_GET['nid'] && $_GET['url']) {
    db_query("INSERT INTO {simplenews_statistics_clicks} (email, nid, url, timestamp) VALUES ('%s', %d, '%s', %d)", $_GET['mail'], $_GET['nid'], urldecode($_GET['url']), time());
  }
  drupal_goto(urldecode($_GET['url']));
}