diff --git a/cacheexclude.module b/cacheexclude.module
index 927eebd..57c5761 100644
--- a/cacheexclude.module
+++ b/cacheexclude.module
@@ -72,7 +72,7 @@ function cacheexclude_init() {
   // set the page caching to false temporarily.
   if (strlen($pages) && (drupal_match_path($_GET['q'], $pages) ||
                          drupal_match_path(drupal_get_path_alias($_GET['q']), $pages) )) {
-    $GLOBALS['conf']['cache'] = 0;
+    drupal_page_is_cacheable(FALSE);
     return;
   }
 
@@ -81,7 +81,7 @@ function cacheexclude_init() {
     $types = array_filter(variable_get('cacheexclude_node_types', array()));
 
     if (in_array($node->type, $types)) {
-      $GLOBALS['conf']['cache'] = 0;
+      drupal_page_is_cacheable(FALSE);
     }
   }
 }
