You are here

function _ai_should_inject in Content Injector (formerly AdSense Injector) 6.3

Same name and namespace in other branches
  1. 7.3 adsense_injector.module \_ai_should_inject()

Should we inject now?

Parameters

object $node:

Return value

True if should inject an ad.

1 call to _ai_should_inject()
adsense_injector_nodeapi in ./adsense_injector.module
Implementation of hook_nodeapi().

File

./adsense_injector.module, line 114
Inject adsense ads into node content automatically.

Code

function _ai_should_inject($node) {
  $node_types = variable_get('adsense_injector_nodes', array());
  if (empty($node_types[$node->type])) {
    return false;
  }
  return true;
}