Index: views_cache.inc =================================================================== --- views_cache.inc (revision 893) +++ views_cache.inc (working copy) @@ -28,7 +28,7 @@ if (!$views_arguments) { $data = cache_get("views_arguments:$locale", 'cache_views'); - $cache = unserialize($data->data); + $cache = $data->data; if (is_array($cache)) { $views_arguments = $cache; } @@ -54,7 +54,7 @@ $views_arguments['title'][$name] = $arg; } $cache = $views_arguments; - cache_set("views_arguments:$locale", 'cache_views', serialize($cache)); + cache_set("views_arguments:$locale", 'cache_views', $cache); } } return ($titles ? $views_arguments['base'] : $views_arguments['title']); @@ -70,20 +70,20 @@ if (!$views_tables) { $data = cache_get("views_tables:$locale", 'cache_views'); - $cache = unserialize($data->data); + $cache = $data->data; if (is_array($cache)) { $views_tables = $cache; } else { $table_data = module_invoke_all('views_tables'); - + // allow modules to alter the definitions supplied others foreach (module_implements('views_tables_alter') as $module) { $function = $module . '_views_tables_alter'; $function($table_data); } - + $views_tables['tables'] = $table_data; foreach ($table_data as $name => $table) { @@ -143,7 +143,7 @@ } } } - cache_set("views_tables:$locale", 'cache_views', serialize($views_tables)); + cache_set("views_tables:$locale", 'cache_views', $views_tables); } } return ($full ? $views_tables : $views_tables['tables']); @@ -224,7 +224,7 @@ if (!$views_default_views) { $data = cache_get("views_default_views:$locale", 'cache_views'); - $cache = unserialize($data->data); + $cache = $data->data; if (is_array($cache)) { $views_default_views = $cache; @@ -243,7 +243,7 @@ $views_default_views[$i] = $view; } } - cache_set("views_default_views:$locale", 'cache_views', serialize($views_default_views)); + cache_set("views_default_views:$locale", 'cache_views', $views_default_views); } } return $views_default_views; @@ -266,7 +266,7 @@ function _views_get_query(&$view, $args, $filters) { if ($view->is_cacheable && ($cached = cache_get('views_query:' . $view->name, 'cache_views'))) { - $info = unserialize($cached->data); + $info = $cached->data; $plugins = _views_get_style_plugins(); if ($plugins[$view->type]['needs_table_header']) { @@ -281,7 +281,7 @@ 'countquery' => _views_replace_args($info['countquery'], $info['args']), ); if ($view->is_cacheable) { - cache_set('views_query:' . $view->name, 'cache_views', serialize($data)); + cache_set('views_query:' . $view->name, 'cache_views', $data); } $info = array_merge($info, $data); } @@ -313,7 +313,7 @@ if (!$views_style_plugins) { $data = cache_get("views_style_plugins:$locale", 'cache_views'); - $cache = unserialize($data->data); + $cache = $data->data; if (is_array($cache)) { $views_style_plugins = $cache; } @@ -328,8 +328,8 @@ $views_style_plugins['base'][$name] = $arg; } $cache = $views_style_plugins; - cache_set("views_style_plugins:$locale", 'cache_views', serialize($cache)); + cache_set("views_style_plugins:$locale", 'cache_views', $cache); } } return ($titles ? $views_style_plugins['title'] : $views_style_plugins['base']); -} \ No newline at end of file +} Index: views.module =================================================================== --- views.module (revision 893) +++ views.module (working copy) @@ -200,10 +200,10 @@ $views[$view->name] = $view->url; } } - cache_set("views_urls", 'cache_views', serialize($views)); + cache_set("views_urls", 'cache_views', $views); } else { - $views = unserialize($cache->data); + $views = $cache->data; } return $views; @@ -302,7 +302,7 @@ } // All views with an empty access setting are available to all roles. - if (!$view->access) { + if (!$view->access) { return TRUE; } @@ -523,7 +523,7 @@ if ($args == NULL) { $args = array(); } - + // if no filter values are passed in, get them from the $_GET array if ($filters == NULL) { $filters = views_get_filter_values(); @@ -832,47 +832,47 @@ */ function _views_view_fields() { return array( - 'vid' => '%d', - 'name' => "'%s'", - 'description' => "'%s'", - 'access' => "'%s'", - 'page' => '%d', - 'page_title' => "'%s'", - 'page_header' => "'%s'", - 'page_header_format' => '%d', - 'page_footer' => "'%s'", - 'page_footer_format' => '%d', - 'page_empty' => "'%s'", - 'page_empty_format' => '%d', - 'page_type' => "'%s'", - 'use_pager' => '%d', - 'nodes_per_page' => '%d', - 'url' => "'%s'", - 'menu' => '%d', - 'menu_tab' => '%d', - 'menu_tab_default' => '%d', - 'menu_tab_weight' => '%d', - 'menu_title' => "'%s'", + 'vid' => '%d', + 'name' => "'%s'", + 'description' => "'%s'", + 'access' => "'%s'", + 'page' => '%d', + 'page_title' => "'%s'", + 'page_header' => "'%s'", + 'page_header_format' => '%d', + 'page_footer' => "'%s'", + 'page_footer_format' => '%d', + 'page_empty' => "'%s'", + 'page_empty_format' => '%d', + 'page_type' => "'%s'", + 'use_pager' => '%d', + 'nodes_per_page' => '%d', + 'url' => "'%s'", + 'menu' => '%d', + 'menu_tab' => '%d', + 'menu_tab_default' => '%d', + 'menu_tab_weight' => '%d', + 'menu_title' => "'%s'", 'menu_tab_default_parent_type' => "'%s'", - 'menu_parent_title' => "'%s'", - 'menu_parent_tab_weight' => '%d', - 'block' => '%d', - 'block_title' => "'%s'", - 'block_use_page_header' => '%d', - 'block_header' => "'%s'", - 'block_header_format' => '%d', - 'block_use_page_footer' => '%d', - 'block_footer' => "'%s'", - 'block_footer_format' => '%d', - 'block_use_page_empty' => '%d', - 'block_empty' => "'%s'", - 'block_empty_format' => '%d', - 'block_type' => "'%s'", - 'nodes_per_block' => '%d', - 'block_more' => '%d', - 'breadcrumb_no_home' => '%d', - 'changed' => '%d', - 'view_args_php' => "'%s'", + 'menu_parent_title' => "'%s'", + 'menu_parent_tab_weight' => '%d', + 'block' => '%d', + 'block_title' => "'%s'", + 'block_use_page_header' => '%d', + 'block_header' => "'%s'", + 'block_header_format' => '%d', + 'block_use_page_footer' => '%d', + 'block_footer' => "'%s'", + 'block_footer_format' => '%d', + 'block_use_page_empty' => '%d', + 'block_empty' => "'%s'", + 'block_empty_format' => '%d', + 'block_type' => "'%s'", + 'nodes_per_block' => '%d', + 'block_more' => '%d', + 'breadcrumb_no_home' => '%d', + 'changed' => '%d', + 'view_args_php' => "'%s'", 'is_cacheable' => '%d', ); } @@ -1314,7 +1314,7 @@ $form['#action'] = url($view->real_url ? $view->real_url : $view->url, NULL, NULL, true); $form['view'] = array('#type' => 'value', '#value' => $view); $form['submit'] = array('#type' => 'button', '#name' => '', '#value' => t('Submit')); - + // clean URL get forms breaks if we don't give it a 'q'. if (!(bool)variable_get('clean_url', '0')) { $form['q'] = array( @@ -1386,7 +1386,7 @@ } $form["filter$count"] = $item; } - + return $form; } @@ -1999,7 +1999,7 @@ $operator = $filter['operator']; $query->add_where("$field $operator NULL"); break; - } + } } /** @@ -2143,4 +2143,4 @@ // An implementation of hook_devel_caches() from devel.module. Must be in views.module so it always is included. function views_devel_caches() { return array('cache_views'); -} \ No newline at end of file +}