Skip to content

Instantly share code, notes, and snippets.

@cafuego
Created August 2, 2010 22:21
Show Gist options
  • Save cafuego/505424 to your computer and use it in GitHub Desktop.
Save cafuego/505424 to your computer and use it in GitHub Desktop.
<?php
$count = 50000;
if(module_exists("devel"))
dpm("The count before increment:" . $count);
if ($node = menu_get_object('node')) {
if ($node->type == 'webform') {
$count = db_result(db_query('SELECT count(*) FROM {webform_submissions} WHERE nid = %d', $node->nid));
if(module_exists("devel"))
dpm("This is the count after increment: \$" . $count);
}
}
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment