Browse Source

upgrade of drupalcore to 6.14

tags/intro_KPN
Bèr Kessels 12 years ago
parent
commit
8ef5150e46
98 changed files with 787 additions and 389 deletions
  1. 27
    1
      CHANGELOG.txt
  2. 3
    3
      COPYRIGHT.txt
  3. 6
    1
      includes/actions.inc
  4. 7
    1
      includes/bootstrap.inc
  5. 5
    5
      includes/cache.inc
  6. 65
    18
      includes/common.inc
  7. 19
    5
      includes/database.inc
  8. 3
    3
      includes/database.mysql-common.inc
  9. 11
    3
      includes/database.mysql.inc
  10. 11
    3
      includes/database.mysqli.inc
  11. 15
    4
      includes/database.pgsql.inc
  12. 18
    11
      includes/file.inc
  13. 18
    13
      includes/form.inc
  14. 10
    6
      includes/locale.inc
  15. 2
    2
      includes/mail.inc
  16. 2
    2
      includes/pager.inc
  17. 2
    2
      includes/tablesort.inc
  18. 4
    4
      includes/theme.inc
  19. 10
    7
      includes/theme.maintenance.inc
  20. 4
    3
      misc/drupal.js
  21. 11
    7
      misc/tabledrag.js
  22. 5
    5
      misc/teaser.js
  23. 3
    3
      modules/aggregator/aggregator.info
  24. 3
    3
      modules/block/block.info
  25. 3
    3
      modules/blog/blog.info
  26. 4
    4
      modules/blog/blog.pages.inc
  27. 3
    3
      modules/blogapi/blogapi.info
  28. 3
    3
      modules/book/book.info
  29. 3
    3
      modules/color/color.info
  30. 2
    2
      modules/color/color.module
  31. 3
    3
      modules/comment/comment.info
  32. 10
    10
      modules/comment/comment.module
  33. 2
    2
      modules/comment/comment.pages.inc
  34. 3
    3
      modules/contact/contact.info
  35. 3
    3
      modules/dblog/dblog.info
  36. 21
    5
      modules/dblog/dblog.install
  37. 3
    3
      modules/filter/filter.info
  38. 3
    3
      modules/filter/filter.module
  39. 1
    2
      modules/forum/forum.admin.inc
  40. 3
    3
      modules/forum/forum.info
  41. 3
    3
      modules/forum/forum.module
  42. 6
    1
      modules/forum/forum.pages.inc
  43. 3
    3
      modules/help/help.info
  44. 3
    3
      modules/locale/locale.info
  45. 3
    3
      modules/menu/menu.info
  46. 2
    2
      modules/node/content_types.inc
  47. 14
    19
      modules/node/node.admin.inc
  48. 3
    3
      modules/node/node.info
  49. 9
    9
      modules/node/node.module
  50. 2
    2
      modules/node/node.tpl.php
  51. BIN
      modules/openid/login-bg.png
  52. 8
    5
      modules/openid/openid.inc
  53. 3
    3
      modules/openid/openid.info
  54. 6
    6
      modules/openid/openid.module
  55. 7
    5
      modules/openid/openid.pages.inc
  56. 3
    3
      modules/path/path.info
  57. 3
    3
      modules/php/php.info
  58. 3
    3
      modules/ping/ping.info
  59. 3
    3
      modules/poll/poll.info
  60. 2
    2
      modules/poll/poll.module
  61. 3
    3
      modules/profile/profile.info
  62. 3
    3
      modules/search/search.info
  63. 12
    1
      modules/search/search.module
  64. 3
    3
      modules/statistics/statistics.info
  65. 20
    3
      modules/statistics/statistics.install
  66. 3
    3
      modules/syslog/syslog.info
  67. 20
    13
      modules/system/system.admin.inc
  68. 3
    3
      modules/system/system.info
  69. 56
    3
      modules/system/system.install
  70. 2
    2
      modules/system/system.js
  71. 54
    5
      modules/system/system.module
  72. 3
    3
      modules/taxonomy/taxonomy.info
  73. 2
    2
      modules/taxonomy/taxonomy.module
  74. 3
    3
      modules/throttle/throttle.info
  75. 3
    3
      modules/tracker/tracker.info
  76. 3
    3
      modules/translation/translation.info
  77. 3
    3
      modules/trigger/trigger.info
  78. 3
    3
      modules/trigger/trigger.module
  79. 8
    1
      modules/update/update.compare.inc
  80. 50
    15
      modules/update/update.fetch.inc
  81. 3
    3
      modules/update/update.info
  82. 12
    1
      modules/update/update.module
  83. 2
    1
      modules/update/update.report.inc
  84. 3
    3
      modules/upload/upload.info
  85. 2
    2
      modules/upload/upload.module
  86. 3
    3
      modules/user/user.info
  87. 8
    1
      modules/user/user.install
  88. 28
    9
      modules/user/user.module
  89. 4
    2
      modules/user/user.pages.inc
  90. 14
    2
      sites/default/default.settings.php
  91. 3
    3
      themes/bluemarine/bluemarine.info
  92. 3
    3
      themes/chameleon/chameleon.info
  93. 3
    3
      themes/chameleon/marvin/marvin.info
  94. 3
    3
      themes/garland/garland.info
  95. 3
    3
      themes/garland/minnelli/minnelli.info
  96. 3
    2
      themes/garland/style.css
  97. 10
    13
      themes/garland/template.php
  98. 3
    3
      themes/pushbutton/pushbutton.info

+ 27
- 1
CHANGELOG.txt View File

@@ -1,4 +1,19 @@
// $Id: CHANGELOG.txt,v 1.253.2.29 2009/05/13 19:11:04 goba Exp $
// $Id: CHANGELOG.txt,v 1.253.2.33 2009/09/16 19:34:13 goba Exp $

Drupal 6.14, 2009-09-16
----------------------
- Fixed security issues (OpenID association cross site request forgeries,
OpenID impersonation and File upload), see SA-CORE-2009-008.
- Changed the system modules page to not run all cache rebuilds; use the
button on the performance settings page to achieve the same effect.
- Added support for PHP 5.3.0 out of the box.
- Fixed a variety of small bugs.

Drupal 6.13, 2009-07-01
----------------------
- Fixed security issues (Cross site scripting, Input format access bypass and
Password leakage in URL), see SA-CORE-2009-007.
- Fixed a variety of small bugs.

Drupal 6.12, 2009-05-13
----------------------
@@ -186,6 +201,17 @@ Drupal 6.0, 2008-02-13
- Removed old system updates. Updates from Drupal versions prior to 5.x will
require upgrading to 5.x before upgrading to 6.x.

Drupal 5.20, 2009-09-16
-----------------------
- Avoid security problems resulting from writing Drupal 6-style menu declarations.
- Fixed security issues (session fixation), see SA-CORE-2009-008.
- Fixed a variety of small bugs.

Drupal 5.19, 2009-07-01
-----------------------
- Fixed security issues (Cross site scripting and Password leakage in URL), see SA-CORE-2009-007.
- Fixed a variety of small bugs.

Drupal 5.18, 2009-05-13
----------------------
- Fixed security issues (Cross site scripting), see SA-CORE-2009-006.

+ 3
- 3
COPYRIGHT.txt View File

@@ -1,6 +1,6 @@
// $Id: COPYRIGHT.txt,v 1.2.2.1 2008/02/06 12:45:55 goba Exp $
// $Id: COPYRIGHT.txt,v 1.2.2.2 2009/09/14 12:50:38 goba Exp $

All Drupal code is Copyright 2001 - 2008 by the original authors.
All Drupal code is Copyright 2001 - 2009 by the original authors.

This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -21,5 +21,5 @@ Drupal includes works under other copyright notices and distributed
according to the terms of the GNU General Public License or a compatible
license, including:

jQuery - Copyright (c) 2008 John Resig
jQuery - Copyright (c) 2008 - 2009 John Resig


+ 6
- 1
includes/actions.inc View File

@@ -1,5 +1,5 @@
<?php
// $Id: actions.inc,v 1.8.2.7 2009/02/16 14:34:30 goba Exp $
// $Id: actions.inc,v 1.8.2.9 2009/08/10 10:39:49 goba Exp $

/**
* @file
@@ -112,6 +112,7 @@ function actions_do($action_ids, &$object, $context = NULL, $a1 = NULL, $a2 = NU
/**
* Discover all action functions by invoking hook_action_info().
*
* @code
* mymodule_action_info() {
* return array(
* 'mymodule_functiondescription_action' => array(
@@ -125,6 +126,7 @@ function actions_do($action_ids, &$object, $context = NULL, $a1 = NULL, $a2 = NU
* )
* );
* }
* @endcode
*
* The description is used in presenting possible actions to the user for
* configuration. The type is used to present these actions in a logical
@@ -312,6 +314,9 @@ function actions_synchronize($actions_in_code = array(), $delete_orphans = FALSE
*
* @param $function
* The name of the function to be called when this action is performed.
* @param $type
* The type of action, to describe grouping and/or context, e.g., 'node',
* 'user', 'comment', or 'system'.
* @param $params
* An associative array with parameter names as keys and parameter values
* as values.

+ 7
- 1
includes/bootstrap.inc View File

@@ -1,5 +1,5 @@
<?php
// $Id: bootstrap.inc,v 1.206.2.12 2009/04/30 00:13:30 goba Exp $
// $Id: bootstrap.inc,v 1.206.2.13 2009/09/14 13:33:39 goba Exp $

/**
* @file
@@ -496,6 +496,8 @@ function variable_init($conf = array()) {
* The default value to use if this variable has never been set.
* @return
* The value of the variable.
*
* @see variable_del(), variable_set()
*/
function variable_get($name, $default) {
global $conf;
@@ -511,6 +513,8 @@ function variable_get($name, $default) {
* @param $value
* The value to set. This can be any PHP data type; these functions take care
* of serialization as necessary.
*
* @see variable_del(), variable_get()
*/
function variable_set($name, $value) {
global $conf;
@@ -531,6 +535,8 @@ function variable_set($name, $value) {
*
* @param $name
* The name of the variable to undefine.
*
* @see variable_get(), variable_set()
*/
function variable_del($name) {
global $conf;

+ 5
- 5
includes/cache.inc View File

@@ -1,5 +1,5 @@
<?php
// $Id: cache.inc,v 1.17.2.1 2009/04/27 14:23:58 goba Exp $
// $Id: cache.inc,v 1.17.2.3 2009/08/10 10:43:55 goba Exp $

/**
* Return data from the persistent cache. Data may be stored as either plain text or as serialized data.
@@ -126,9 +126,9 @@ function cache_set($cid, $data, $table = 'cache', $expire = CACHE_PERMANENT, $he
* argument if $cid is set.
*
* @param $wildcard
* If set to TRUE, the $cid is treated as a substring
* to match rather than a complete ID. The match is a right hand
* match. If '*' is given as $cid, the table $table will be emptied.
* If $wildcard is TRUE, cache IDs starting with $cid are deleted in
* addition to the exact cache ID specified by $cid. If $wildcard is
* TRUE and $cid is '*' then the entire table $table is emptied.
*/
function cache_clear_all($cid = NULL, $table = NULL, $wildcard = FALSE) {
global $user;
@@ -155,7 +155,7 @@ function cache_clear_all($cid = NULL, $table = NULL, $wildcard = FALSE) {
variable_set('cache_flush_'. $table, time());
}
else if (time() > ($cache_flush + variable_get('cache_lifetime', 0))) {
// Clear the cache for everyone, cache_flush_delay seconds have
// Clear the cache for everyone, cache_lifetime seconds have
// passed since the first request to clear the cache.
db_query("DELETE FROM {". $table ."} WHERE expire != %d AND expire < %d", CACHE_PERMANENT, time());
variable_set('cache_flush_'. $table, 0);

+ 65
- 18
includes/common.inc View File

@@ -1,5 +1,5 @@
<?php
// $Id: common.inc,v 1.756.2.52 2009/05/13 19:11:04 goba Exp $
// $Id: common.inc,v 1.756.2.69 2009/09/16 19:34:14 goba Exp $

/**
* @file
@@ -24,6 +24,13 @@ define('SAVED_UPDATED', 2);
*/
define('SAVED_DELETED', 3);

/**
* Create E_DEPRECATED constant for older PHP versions (<5.3).
*/
if (!defined('E_DEPRECATED')) {
define('E_DEPRECATED', 8192);
}

/**
* Set content for a specified region.
*
@@ -48,7 +55,7 @@ function drupal_set_content($region = NULL, $data = NULL) {
* A specified region to fetch content for. If NULL, all regions will be
* returned.
* @param $delimiter
* Content to be inserted between exploded array elements.
* Content to be inserted between imploded array elements.
*/
function drupal_get_content($region = NULL, $delimiter = ' ') {
$content = drupal_set_content();
@@ -216,7 +223,7 @@ function drupal_query_string_encode($query, $exclude = array(), $parent = '') {
$params = array();

foreach ($query as $key => $value) {
$key = drupal_urlencode($key);
$key = rawurlencode($key);
if ($parent) {
$key = $parent .'['. $key .']';
}
@@ -229,7 +236,7 @@ function drupal_query_string_encode($query, $exclude = array(), $parent = '') {
$params[] = drupal_query_string_encode($value, $exclude, $key);
}
else {
$params[] = $key .'='. drupal_urlencode($value);
$params[] = $key .'='. rawurlencode($value);
}
}

@@ -352,6 +359,11 @@ function drupal_not_found() {

watchdog('page not found', check_plain($_GET['q']), NULL, WATCHDOG_WARNING);

// Keep old path for reference, and to allow forms to redirect to it.
if (!isset($_REQUEST['destination'])) {
$_REQUEST['destination'] = $_GET['q'];
}

$path = drupal_get_normal_path(variable_get('site_404', ''));
if ($path && $path != $_GET['q']) {
// Set the active item in case there are tabs to display, or other
@@ -377,6 +389,11 @@ function drupal_access_denied() {

watchdog('access denied', check_plain($_GET['q']), NULL, WATCHDOG_WARNING);

// Keep old path for reference, and to allow forms to redirect to it.
if (!isset($_REQUEST['destination'])) {
$_REQUEST['destination'] = $_GET['q'];
}

$path = drupal_get_normal_path(variable_get('site_403', ''));
if ($path && $path != $_GET['q']) {
// Set the active item in case there are tabs to display or other
@@ -414,6 +431,8 @@ function drupal_access_denied() {
* data and redirect status.
*/
function drupal_http_request($url, $headers = array(), $method = 'GET', $data = NULL, $retry = 3) {
global $db_prefix;

$result = new stdClass();

// Parse the URL and make sure we can handle the schema.
@@ -421,11 +440,13 @@ function drupal_http_request($url, $headers = array(), $method = 'GET', $data =

if ($uri == FALSE) {
$result->error = 'unable to parse URL';
$result->code = -1001;
return $result;
}

if (!isset($uri['scheme'])) {
$result->error = 'missing schema';
$result->code = -1002;
return $result;
}

@@ -443,6 +464,7 @@ function drupal_http_request($url, $headers = array(), $method = 'GET', $data =
break;
default:
$result->error = 'invalid schema '. $uri['scheme'];
$result->code = -1003;
return $result;
}

@@ -475,14 +497,32 @@ function drupal_http_request($url, $headers = array(), $method = 'GET', $data =
// host that do not take into account the port number.
'Host' => "Host: $host",
'User-Agent' => 'User-Agent: Drupal (+http://drupal.org/)',
'Content-Length' => 'Content-Length: '. strlen($data)
);

// Only add Content-Length if we actually have any content or if it is a POST
// or PUT request. Some non-standard servers get confused by Content-Length in
// at least HEAD/GET requests, and Squid always requires Content-Length in
// POST/PUT requests.
$content_length = strlen($data);
if ($content_length > 0 || $method == 'POST' || $method == 'PUT') {
$defaults['Content-Length'] = 'Content-Length: '. $content_length;
}

// If the server url has a user then attempt to use basic authentication
if (isset($uri['user'])) {
$defaults['Authorization'] = 'Authorization: Basic '. base64_encode($uri['user'] . (!empty($uri['pass']) ? ":". $uri['pass'] : ''));
}

// If the database prefix is being used by SimpleTest to run the tests in a copied
// database then set the user-agent header to the database prefix so that any
// calls to other Drupal pages will run the SimpleTest prefixed database. The
// user-agent is used to ensure that multiple testing sessions running at the
// same time won't interfere with each other as they would if the database
// prefix were stored statically in a file or database variable.
if (is_string($db_prefix) && preg_match("/^simpletest\d+$/", $db_prefix, $matches)) {
$defaults['User-Agent'] = 'User-Agent: ' . $matches[0];
}

foreach ($headers as $header => $value) {
$defaults[$header] = $header .': '. $value;
}
@@ -577,7 +617,7 @@ function drupal_error_handler($errno, $message, $filename, $line, $context) {
return;
}

if ($errno & (E_ALL ^ E_NOTICE)) {
if ($errno & (E_ALL ^ E_NOTICE ^ E_DEPRECATED)) {
$types = array(1 => 'error', 2 => 'warning', 4 => 'parse error', 8 => 'notice', 16 => 'core error', 32 => 'core warning', 64 => 'compile error', 128 => 'compile warning', 256 => 'user error', 512 => 'user warning', 1024 => 'user notice', 2048 => 'strict warning', 4096 => 'recoverable fatal error');

// For database errors, we want the line number/file name of the place that
@@ -978,7 +1018,7 @@ function flood_register_event($name) {
*
* @param $name
* The name of the event.
* @param $number
* @param $threshold
* The maximum number of the specified event per hour (per visitor).
* @return
* True if the user did not exceed the hourly threshold. False otherwise.
@@ -1337,8 +1377,8 @@ function format_date($timestamp, $type = 'medium', $format = '', $timezone = NUL
* @param $options
* An associative array of additional options, with the following keys:
* - 'query'
* A query string to append to the link, or an array of query key/value
* properties.
* A URL-encoded query string to append to the link, or an array of query
* key/value-pairs without any URL-encoding.
* - 'fragment'
* A fragment identifier (or named anchor) to append to the link.
* Do not include the '#' character.
@@ -1846,7 +1886,9 @@ function drupal_get_css($css = NULL) {
}

if ($is_writable && $preprocess_css) {
$filename = md5(serialize($types) . $query_string) .'.css';
// Prefix filename to prevent blocking by firewalls which reject files
// starting with "ad*".
$filename = 'css_'. md5(serialize($types) . $query_string) .'.css';
$preprocess_file = drupal_build_css_cache($types, $filename);
$output .= '<link type="text/css" rel="stylesheet" media="'. $media .'" href="'. base_path() . $preprocess_file .'" />'."\n";
}
@@ -2194,7 +2236,9 @@ function drupal_get_js($scope = 'header', $javascript = NULL) {

// Aggregate any remaining JS files that haven't already been output.
if ($is_writable && $preprocess_js && count($files) > 0) {
$filename = md5(serialize($files) . $query_string) .'.js';
// Prefix filename to prevent blocking by firewalls which reject files
// starting with "ad*".
$filename = 'js_'. md5(serialize($files) . $query_string) .'.js';
$preprocess_file = drupal_build_js_cache($files, $filename);
$preprocessed .= '<script type="text/javascript" src="'. base_path() . $preprocess_file .'"></script>'."\n";
}
@@ -2448,6 +2492,8 @@ function drupal_json($var = NULL) {
* characters are double escaped so PHP will still see the encoded version.
* - With clean URLs, Apache changes '//' to '/', so every second slash is
* double escaped.
* - This function should only be used on paths, not on query string arguments,
* otherwise unwanted double encoding will occur.
*
* @param $text
* String to encode
@@ -2614,9 +2660,9 @@ function page_set_cache() {
* Returns TRUE if ran successfully
*/
function drupal_cron_run() {
// If not in 'safe mode', increase the maximum execution time:
if (!ini_get('safe_mode')) {
set_time_limit(240);
// Try to allocate enough time to run all the hook_cron implementations.
if (function_exists('set_time_limit')) {
@set_time_limit($time_limit);
}

// Fetch the cron semaphore
@@ -2713,9 +2759,6 @@ function drupal_system_listing($mask, $directory, $key = 'name', $min_depth = 1)
$searchdir = array($directory);
$files = array();

// Always search sites/all/* as well as the global directories
$searchdir[] = 'sites/all/'. $directory;

// The 'profiles' directory contains pristine collections of modules and
// themes as organized by a distribution. It is pristine in the same way
// that /modules is pristine for core; users should avoid changing anything
@@ -2724,6 +2767,9 @@ function drupal_system_listing($mask, $directory, $key = 'name', $min_depth = 1)
$searchdir[] = "profiles/$profile/$directory";
}

// Always search sites/all/* as well as the global directories
$searchdir[] = 'sites/all/'. $directory;

if (file_exists("$config/$directory")) {
$searchdir[] = "$config/$directory";
}
@@ -3669,7 +3715,8 @@ function drupal_flush_all_caches() {
function _drupal_flush_css_js() {
$string_history = variable_get('css_js_query_string', '00000000000000000000');
$new_character = $string_history[0];
$characters = 'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789';
// Not including 'q' to allow certain JavaScripts to re-use query string.
$characters = 'abcdefghijklmnoprstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789';
while (strpos($string_history, $new_character) !== FALSE) {
$new_character = $characters[mt_rand(0, strlen($characters) - 1)];
}

+ 19
- 5
includes/database.inc View File

@@ -1,5 +1,5 @@
<?php
// $Id: database.inc,v 1.92.2.4 2009/02/16 14:41:58 goba Exp $
// $Id: database.inc,v 1.92.2.8 2009/09/14 10:49:34 goba Exp $

/**
* @file
@@ -32,11 +32,11 @@ define('DB_ERROR', 'a515ac9c2796ca0e23adbe92c68fc9fc');
* For example, one might wish to return a list of the most recent 10 nodes
* authored by a given user. Instead of directly issuing the SQL query
* @code
* SELECT n.title, n.body, n.created FROM node n WHERE n.uid = $uid LIMIT 0, 10;
* SELECT n.nid, n.title, n.created FROM node n WHERE n.uid = $uid LIMIT 0, 10;
* @endcode
* one would instead call the Drupal functions:
* @code
* $result = db_query_range('SELECT n.title, n.body, n.created
* $result = db_query_range('SELECT n.nid, n.title, n.created
* FROM {node} n WHERE n.uid = %d', $uid, 0, 10);
* while ($node = db_fetch_object($result)) {
* // Perform operations on $node->body, etc. here.
@@ -208,7 +208,19 @@ function _db_query_callback($match, $init = FALSE) {

switch ($match[1]) {
case '%d': // We must use type casting to int to convert FALSE/NULL/(TRUE?)
return (int) array_shift($args); // We don't need db_escape_string as numbers are db-safe
$value = array_shift($args);
// Do we need special bigint handling?
if ($value > PHP_INT_MAX) {
$precision = ini_get('precision');
@ini_set('precision', 16);
$value = sprintf('%.0f', $value);
@ini_set('precision', $precision);
}
else {
$value = (int) $value;
}
// We don't need db_escape_string as numbers are db-safe.
return $value;
case '%s':
return db_escape_string(array_shift($args));
case '%n':
@@ -427,6 +439,8 @@ function db_escape_table($string) {
* just map to the according database engine specific
* datatypes. Use 'serial' for auto incrementing fields. This
* will expand to 'int auto_increment' on mysql.
* - 'serialize': A boolean indicating whether the field will be stored
as a serialized string.
* - 'size': The data size: 'tiny', 'small', 'medium', 'normal',
* 'big'. This is a hint about the largest value the field will
* store and determines which of the database engine specific
@@ -443,7 +457,7 @@ function db_escape_table($string) {
* specify '0' as the default value for a type 'int' field it
* will not work because '0' is a string containing the
* character "zero", not an integer.
* - 'length': The maximal length of a type 'varchar' or 'text'
* - 'length': The maximal length of a type 'char', 'varchar' or 'text'
* field. Ignored for other field types.
* - 'unsigned': A boolean indicating whether a type 'int', 'float'
* and 'numeric' only is signed or unsigned. Defaults to

+ 3
- 3
includes/database.mysql-common.inc View File

@@ -1,5 +1,5 @@
<?php
// $Id: database.mysql-common.inc,v 1.17.2.1 2008/02/07 10:17:26 goba Exp $
// $Id: database.mysql-common.inc,v 1.17.2.3 2009/09/14 10:49:34 goba Exp $

/**
* @file
@@ -156,7 +156,7 @@ function _db_process_field($field) {
function _db_create_field_sql($name, $spec) {
$sql = "`". $name ."` ". $spec['mysql_type'];

if (isset($spec['length'])) {
if (in_array($spec['type'], array('varchar', 'char', 'text')) && isset($spec['length'])) {
$sql .= '('. $spec['length'] .')';
}
elseif (isset($spec['precision']) && isset($spec['scale'])) {
@@ -512,7 +512,7 @@ function db_drop_index(&$ret, $table, $name) {
*/

function db_change_field(&$ret, $table, $field, $field_new, $spec, $keys_new = array()) {
$sql = 'ALTER TABLE {'. $table .'} CHANGE '. $field .' '.
$sql = 'ALTER TABLE {'. $table .'} CHANGE `'. $field .'` '.
_db_create_field_sql($field_new, _db_process_field($spec));
if (count($keys_new)) {
$sql .= ', ADD '. implode(', ADD ', _db_create_keys_sql($keys_new));

+ 11
- 3
includes/database.mysql.inc View File

@@ -1,5 +1,5 @@
<?php
// $Id: database.mysql.inc,v 1.89 2008/01/24 10:46:54 goba Exp $
// $Id: database.mysql.inc,v 1.89.2.1 2009/07/21 08:52:29 goba Exp $

/**
* @file
@@ -362,8 +362,16 @@ function db_column_exists($table, $column) {
*/
function db_distinct_field($table, $field, $query) {
$field_to_select = 'DISTINCT('. $table .'.'. $field .')';
// (?<!text) is a negative look-behind (no need to rewrite queries that already use DISTINCT).
return preg_replace('/(SELECT.*)(?:'. $table .'\.|\s)(?<!DISTINCT\()(?<!DISTINCT\('. $table .'\.)'. $field .'(.*FROM )/AUsi', '\1 '. $field_to_select .'\2', $query);
$matches = array();
if (preg_match('/^SELECT(.*?)FROM(.*)/is', $query, $matches)) {
$select = preg_replace(
'/((?:^|,)\s*)(?<!DISTINCT\()(?:'. $table .'\.)?'. $field .'(\s*(?:,|$))/is',
'\1'. $field_to_select .'\2', $matches[1], 1
);
return 'SELECT'. $select .'FROM'. $matches[2];
}
return $query;
}

/**

+ 11
- 3
includes/database.mysqli.inc View File

@@ -1,5 +1,5 @@
<?php
// $Id: database.mysqli.inc,v 1.54 2008/01/23 09:59:29 goba Exp $
// $Id: database.mysqli.inc,v 1.54.2.1 2009/07/21 08:52:30 goba Exp $

/**
* @file
@@ -364,8 +364,16 @@ function db_column_exists($table, $column) {
*/
function db_distinct_field($table, $field, $query) {
$field_to_select = 'DISTINCT('. $table .'.'. $field .')';
// (?<!text) is a negative look-behind (no need to rewrite queries that already use DISTINCT).
return preg_replace('/(SELECT.*)(?:'. $table .'\.|\s)(?<!DISTINCT\()(?<!DISTINCT\('. $table .'\.)'. $field .'(.*FROM )/AUsi', '\1 '. $field_to_select .'\2', $query);
$matches = array();
if (preg_match('/^SELECT(.*?)FROM(.*)/is', $query, $matches)) {
$select = preg_replace(
'/((?:^|,)\s*)(?<!DISTINCT\()(?:'. $table .'\.)?'. $field .'(\s*(?:,|$))/is',
'\1'. $field_to_select .'\2', $matches[1], 1
);
return 'SELECT'. $select .'FROM'.$matches[2];
}
return $query;
}

/**

+ 15
- 4
includes/database.pgsql.inc View File

@@ -1,5 +1,5 @@
<?php
// $Id: database.pgsql.inc,v 1.68.2.4 2009/03/30 13:04:06 goba Exp $
// $Id: database.pgsql.inc,v 1.68.2.7 2009/09/14 10:49:34 goba Exp $

/**
* @file
@@ -611,7 +611,7 @@ function _db_create_field_sql($name, $spec) {
}
}

if (!empty($spec['length'])) {
if (in_array($spec['type'], array('varchar', 'char', 'text')) && isset($spec['length'])) {
$sql .= '('. $spec['length'] .')';
}
elseif (isset($spec['precision']) && isset($spec['scale'])) {
@@ -906,13 +906,24 @@ function db_drop_index(&$ret, $table, $name) {
* table specification but without the 'fields' element.
*/
function db_change_field(&$ret, $table, $field, $field_new, $spec, $new_keys = array()) {
$ret[] = update_sql("ALTER TABLE {". $table ."} RENAME $field TO ". $field ."_old");
$ret[] = update_sql('ALTER TABLE {'. $table .'} RENAME "'. $field .'" TO "'. $field .'_old"');
$not_null = isset($spec['not null']) ? $spec['not null'] : FALSE;
unset($spec['not null']);

if (!array_key_exists('size', $spec)) {
$spec['size'] = 'normal';
}
db_add_field($ret, $table, "$field_new", $spec);

$ret[] = update_sql("UPDATE {". $table ."} SET $field_new = ". $field ."_old");
// We need to type cast the new column to best transfer the data
// db_type_map will return possiblities that are not 'cast-able'
// such as serial - they must be made 'int' instead.
$map = db_type_map();
$typecast = $map[$spec['type'] .':'. $spec['size']];
if (in_array($typecast, array('serial', 'bigserial', 'numeric'))) {
$typecast = 'int';
}
$ret[] = update_sql('UPDATE {'. $table .'} SET '. $field_new .' = CAST('. $field .'_old AS '. $typecast .')');

if ($not_null) {
$ret[] = update_sql("ALTER TABLE {". $table ."} ALTER $field_new SET NOT NULL");

+ 18
- 11
includes/file.inc View File

@@ -1,5 +1,5 @@
<?php
// $Id: file.inc,v 1.121.2.6 2009/04/13 19:07:16 dries Exp $
// $Id: file.inc,v 1.121.2.9 2009/09/16 19:34:14 goba Exp $

/**
* @file
@@ -529,13 +529,6 @@ function file_save_upload($source, $validators = array(), $dest = FALSE, $replac
$file->filepath = $_FILES['files']['tmp_name'][$source];
$file->filemime = file_get_mimetype($file->filename);

// Rename potentially executable files, to help prevent exploits.
if (preg_match('/\.(php|pl|py|cgi|asp|js)$/i', $file->filename) && (substr($file->filename, -4) != '.txt')) {
$file->filemime = 'text/plain';
$file->filepath .= '.txt';
$file->filename .= '.txt';
}

// If the destination is not provided, or is not writable, then use the
// temporary directory.
if (empty($dest) || file_check_path($dest) === FALSE) {
@@ -550,9 +543,23 @@ function file_save_upload($source, $validators = array(), $dest = FALSE, $replac
$errors = array();
foreach ($validators as $function => $args) {
array_unshift($args, $file);
// Make sure $file is passed around by reference.
$args[0] = &$file;
$errors = array_merge($errors, call_user_func_array($function, $args));
}

// Rename potentially executable files, to help prevent exploits.
if (preg_match('/\.(php|pl|py|cgi|asp|js)$/i', $file->filename) && (substr($file->filename, -4) != '.txt')) {
$file->filemime = 'text/plain';
$file->filepath .= '.txt';
$file->filename .= '.txt';
// As the file may be named example.php.txt, we need to munge again to
// convert to example.php_.txt, then create the correct destination.
$file->filename = file_munge_filename($file->filename, $extensions);
$file->destination = file_destination(file_create_path($dest .'/'. $file->filename), $replace);
}


// Check for validation errors.
if (!empty($errors)) {
$message = t('The selected file %name could not be uploaded.', array('%name' => $file->filename));
@@ -640,7 +647,7 @@ function file_validate_extensions($file, $extensions) {
* @param $file_limit
* An integer specifying the maximum file size in bytes. Zero indicates that
* no limit should be enforced.
* @param $$user_limit
* @param $user_limit
* An integer specifying the maximum number of bytes the user is allowed. Zero
* indicates that no limit should be enforced.
* @return
@@ -657,8 +664,8 @@ function file_validate_size($file, $file_limit = 0, $user_limit = 0) {
$errors[] = t('The file is %filesize exceeding the maximum file size of %maxsize.', array('%filesize' => format_size($file->filesize), '%maxsize' => format_size($file_limit)));
}

$total_size = file_space_used($user->uid) + $file->filesize;
if ($user_limit && $total_size > $user_limit) {
// Save a query by only calling file_space_used() when a limit is provided.
if ($user_limit && (file_space_used($user->uid) + $file->filesize) > $user_limit) {
$errors[] = t('The file is %filesize which would exceed your disk quota of %quota.', array('%filesize' => format_size($file->filesize), '%quota' => format_size($user_limit)));
}
}

+ 18
- 13
includes/form.inc View File

@@ -1,5 +1,5 @@
<?php
// $Id: form.inc,v 1.265.2.24 2009/05/13 18:22:29 goba Exp $
// $Id: form.inc,v 1.265.2.28 2009/09/16 17:54:19 goba Exp $

/**
* @defgroup forms Form builder functions
@@ -119,9 +119,8 @@ function drupal_get_form($form_id) {
drupal_process_form($form_id, $form, $form_state);
if ($cacheable && !empty($form['#cache'])) {
// Caching is done past drupal_process_form so #process callbacks can
// set #cache. By not sending the form state, we avoid storing
// $form_state['storage'].
form_set_cache($form_build_id, $original_form, NULL);
// set #cache.
form_set_cache($form_build_id, $original_form, $form_state);
}
}

@@ -132,14 +131,14 @@ function drupal_get_form($form_id) {
// the form will simply be re-rendered with the values still in its
// fields.
//
// If $form_state['storage'] or $form_state['rebuild'] have been
// set by any submit or validate handlers, however, we know that
// we're in a complex multi-part process of some sort and the form's
// workflow is NOT complete. We need to construct a fresh copy of
// the form, passing in the latest $form_state in addition to any
// other variables passed into drupal_get_form().
if (!empty($form_state['rebuild']) || !empty($form_state['storage'])) {
// If $form_state['storage'] or $form_state['rebuild'] has been set
// and the form has been submitted, we know that we're in a complex
// multi-part process of some sort and the form's workflow is NOT
// complete. We need to construct a fresh copy of the form, passing
// in the latest $form_state in addition to any other variables passed
// into drupal_get_form().
if ((!empty($form_state['storage']) || !empty($form_state['rebuild'])) && !empty($form_state['submitted']) && !form_get_errors()) {
$form = drupal_rebuild_form($form_id, $form_state, $args);
}

@@ -272,6 +271,7 @@ function form_get_cache($form_build_id, &$form_state) {
* in here when it is called.
* For example:
*
* @code
* // register a new user
* $form_state = array();
* $form_state['values']['name'] = 'robo-user';
@@ -289,9 +289,14 @@ function form_get_cache($form_build_id, &$form_state) {
* $form_state['values']['name'] = 'robo-user';
* $form_state['values']['op'] = t('Save');
* drupal_execute('story_node_form', $form_state, (object)$node);
* @endcode
*/
function drupal_execute($form_id, &$form_state) {
$args = func_get_args();

// Make sure $form_state is passed around by reference.
$args[1] = &$form_state;
$form = call_user_func_array('drupal_retrieve_form', $args);
$form['#post'] = $form_state['values'];
drupal_prepare_form($form_id, $form, $form_state);
@@ -1624,7 +1629,7 @@ function password_confirm_validate($form, &$form_state) {
$pass1 = trim($form['pass1']['#value']);
if (!empty($pass1)) {
$pass2 = trim($form['pass2']['#value']);
if ($pass1 != $pass2) {
if (strcmp($pass1, $pass2)) {
form_error($form, t('The specified passwords do not match.'));
}
}

+ 10
- 6
includes/locale.inc View File

@@ -1,5 +1,5 @@
<?php
// $Id: locale.inc,v 1.174.2.8 2009/04/08 02:54:00 dries Exp $
// $Id: locale.inc,v 1.174.2.10 2009/09/15 10:40:26 goba Exp $

/**
* @file
@@ -847,8 +847,10 @@ function locale_string_is_safe($string) {
* Validate string editing form submissions.
*/
function locale_translate_edit_form_validate($form, &$form_state) {
// Locale string check is needed for default textgroup only.
$safe_check_needed = $form_state['values']['textgroup'] == 'default';
foreach ($form_state['values']['translations'] as $key => $value) {
if (!locale_string_is_safe($value)) {
if ($safe_check_needed && !locale_string_is_safe($value)) {
form_set_error('translations', t('The submitted string contains disallowed HTML: %string', array('%string' => $value)));
watchdog('locale', 'Attempted submission of a translation string with disallowed HTML: %string', array('%string' => $value), WATCHDOG_WARNING);
}
@@ -1016,9 +1018,9 @@ function locale_add_language($langcode, $name = NULL, $native = NULL, $direction
* Text group to import PO file into (eg. 'default' for interface translations)
*/
function _locale_import_po($file, $langcode, $mode, $group = NULL) {
// If not in 'safe mode', increase the maximum execution time.
if (!ini_get('safe_mode')) {
set_time_limit(240);
// Try to allocate enough time to parse and import the data.
if (function_exists('set_time_limit')) {
@set_time_limit(240);
}

// Check if we have the language already in the database.
@@ -1340,7 +1342,9 @@ function _locale_import_one_string_db(&$report, $langcode, $source, $translation

if (!empty($translation)) {
// Skip this string unless it passes a check for dangerous code.
if (!locale_string_is_safe($translation)) {
// Text groups other than default still can contain HTML tags
// (i.e. translatable blocks).
if ($textgroup == "default" && !locale_string_is_safe($translation)) {
$report['skips']++;
$lid = 0;
}

+ 2
- 2
includes/mail.inc View File

@@ -1,5 +1,5 @@
<?php
// $Id: mail.inc,v 1.8.2.6 2009/04/27 11:07:43 goba Exp $
// $Id: mail.inc,v 1.8.2.7 2009/06/18 12:15:44 goba Exp $

/**
* Compose and optionally send an e-mail message.
@@ -45,7 +45,7 @@
* switch($key) {
* case 'notice':
* $message['subject'] = t('Notification from !site', $variables, $language->language);
* $message['body'] = t("Dear !username\n\nThere is new content available on the site.", $variables, $language->language);
* $message['body'][] = t("Dear !username\n\nThere is new content available on the site.", $variables, $language->language);
* break;
* }
* }

+ 2
- 2
includes/pager.inc View File

@@ -1,5 +1,5 @@
<?php
// $Id: pager.inc,v 1.63 2007/12/06 09:58:30 goba Exp $
// $Id: pager.inc,v 1.63.2.1 2009/07/01 20:51:55 goba Exp $

/**
* @file
@@ -85,7 +85,7 @@ function pager_query($query, $limit = 10, $element = 0, $count_query = NULL) {
function pager_get_querystring() {
static $string = NULL;
if (!isset($string)) {
$string = drupal_query_string_encode($_REQUEST, array_merge(array('q', 'page'), array_keys($_COOKIE)));
$string = drupal_query_string_encode($_REQUEST, array_merge(array('q', 'page', 'pass'), array_keys($_COOKIE)));
}
return $string;
}

+ 2
- 2
includes/tablesort.inc View File

@@ -1,5 +1,5 @@
<?php
// $Id: tablesort.inc,v 1.47 2008/01/04 09:31:48 goba Exp $
// $Id: tablesort.inc,v 1.47.2.1 2009/07/01 20:51:55 goba Exp $

/**
* @file
@@ -136,7 +136,7 @@ function tablesort_cell($cell, $header, $ts, $i) {
* except for those pertaining to table sorting.
*/
function tablesort_get_querystring() {
return drupal_query_string_encode($_REQUEST, array_merge(array('q', 'sort', 'order'), array_keys($_COOKIE)));
return drupal_query_string_encode($_REQUEST, array_merge(array('q', 'sort', 'order', 'pass'), array_keys($_COOKIE)));
}

/**

+ 4
- 4
includes/theme.inc View File

@@ -1,5 +1,5 @@
<?php
// $Id: theme.inc,v 1.415.2.22 2009/05/13 19:11:04 goba Exp $
// $Id: theme.inc,v 1.415.2.24 2009/06/18 12:04:04 goba Exp $

/**
* @file
@@ -1632,7 +1632,7 @@ function theme_username($object) {
$output .= ' ('. t('not verified') .')';
}
else {
$output = variable_get('anonymous', t('Anonymous'));
$output = check_plain(variable_get('anonymous', t('Anonymous')));
}

return $output;
@@ -1820,8 +1820,8 @@ function template_preprocess_page(&$variables) {
$variables['primary_links'] = theme_get_setting('toggle_primary_links') ? menu_primary_links() : array();
$variables['secondary_links'] = theme_get_setting('toggle_secondary_links') ? menu_secondary_links() : array();
$variables['search_box'] = (theme_get_setting('toggle_search') ? drupal_get_form('search_theme_form') : '');
$variables['site_name'] = (theme_get_setting('toggle_name') ? variable_get('site_name', 'Drupal') : '');
$variables['site_slogan'] = (theme_get_setting('toggle_slogan') ? variable_get('site_slogan', '') : '');
$variables['site_name'] = (theme_get_setting('toggle_name') ? filter_xss_admin(variable_get('site_name', 'Drupal')) : '');
$variables['site_slogan'] = (theme_get_setting('toggle_slogan') ? filter_xss_admin(variable_get('site_slogan', '')) : '');
$variables['css'] = drupal_add_css();
$variables['styles'] = drupal_get_css();
$variables['scripts'] = drupal_get_js();

+ 10
- 7
includes/theme.maintenance.inc View File

@@ -1,5 +1,5 @@
<?php
// $Id: theme.maintenance.inc,v 1.10 2008/01/24 09:42:50 goba Exp $
// $Id: theme.maintenance.inc,v 1.10.2.1 2009/08/10 11:11:59 goba Exp $

/**
* @file
@@ -36,12 +36,15 @@ function _drupal_maintenance_theme() {
$theme = 'minnelli';
}
else {
// Load module basics (needed for hook invokes).
$module_list['system']['filename'] = 'modules/system/system.module';
$module_list['filter']['filename'] = 'modules/filter/filter.module';
module_list(TRUE, FALSE, FALSE, $module_list);
drupal_load('module', 'system');
drupal_load('module', 'filter');
if (!db_is_active()) {
// Because we are operating in a crippled environment, we need to
// bootstrap just enough to allow hook invocations to work.
$module_list['system']['filename'] = 'modules/system/system.module';
$module_list['filter']['filename'] = 'modules/filter/filter.module';
module_list(TRUE, FALSE, FALSE, $module_list);
drupal_load('module', 'system');
drupal_load('module', 'filter');
}

$theme = variable_get('maintenance_theme', 'minnelli');
}

+ 4
- 3
misc/drupal.js View File

@@ -1,4 +1,4 @@
// $Id: drupal.js,v 1.41.2.3 2008/06/25 09:06:57 goba Exp $
// $Id: drupal.js,v 1.41.2.4 2009/07/21 08:59:10 goba Exp $

var Drupal = Drupal || { 'settings': {}, 'behaviors': {}, 'themes': {}, 'locale': {} };

@@ -218,8 +218,9 @@ Drupal.unfreezeHeight = function () {
};

/**
* Wrapper to address the mod_rewrite url encoding bug
* (equivalent of drupal_urlencode() in PHP).
* Wrapper around encodeURIComponent() which avoids Apache quirks (equivalent of
* drupal_urlencode() in PHP). This function should only be used on paths, not
* on query string arguments.
*/
Drupal.encodeURIComponent = function (item, uri) {
uri = uri || location.href;

+ 11
- 7
misc/tabledrag.js View File

@@ -1,4 +1,4 @@
// $Id: tabledrag.js,v 1.13.2.4 2008/09/17 07:59:39 goba Exp $
// $Id: tabledrag.js,v 1.13.2.5 2009/06/18 12:24:24 goba Exp $

/**
* Drag and drop table rows with field manipulation.
@@ -76,13 +76,15 @@ Drupal.tableDrag = function(table, tableSettings) {
// manually append 2 indentations in the first draggable row, measure
// the offset, then remove.
var indent = Drupal.theme('tableDragIndentation');
var testCell = $('tr.draggable:first td:first', table).prepend(indent).prepend(indent);
// Match immediate children of the parent element to allow nesting.
var testCell = $('> tbody > tr.draggable:first td:first, > tr.draggable:first td:first', table).prepend(indent).prepend(indent);
this.indentAmount = $('.indentation', testCell).get(1).offsetLeft - $('.indentation', testCell).get(0).offsetLeft;
$('.indentation', testCell).slice(0, 2).remove();
}

// Make each applicable row draggable.
$('tr.draggable', table).each(function() { self.makeDraggable(this); });
// Match immediate children of the parent element to allow nesting.
$('> tr.draggable, > tbody > tr.draggable', table).each(function() { self.makeDraggable(this); });

// Hide columns containing affected form elements.
this.hideColumns();
@@ -112,9 +114,10 @@ Drupal.tableDrag.prototype.hideColumns = function(){
// Hide the column containing this field.
if (hidden && cell[0] && cell.css('display') != 'none') {
// Add 1 to our indexes. The nth-child selector is 1 based, not 0 based.
var columnIndex = $('td', cell.parent()).index(cell.get(0)) + 1;
var headerIndex = $('td:not(:hidden)', cell.parent()).index(cell.get(0)) + 1;
$('tr', this.table).each(function(){
// Match immediate children of the parent element to allow nesting.
var columnIndex = $('> td', cell.parent()).index(cell.get(0)) + 1;
var headerIndex = $('> td:not(:hidden)', cell.parent()).index(cell.get(0)) + 1;
$('> thead > tr, > tbody > tr, > tr', this.table).each(function(){
var row = $(this);
var parentTag = row.parent().get(0).tagName.toLowerCase();
var index = (parentTag == 'thead') ? headerIndex : columnIndex;
@@ -775,7 +778,8 @@ Drupal.tableDrag.prototype.setScroll = function(scrollAmount) {
Drupal.tableDrag.prototype.restripeTable = function() {
// :even and :odd are reversed because jquery counts from 0 and
// we count from 1, so we're out of sync.
$('tr.draggable', this.table)
// Match immediate children of the parent element to allow nesting.
$('> tbody > tr.draggable, > tr.draggable', this.table)
.filter(':odd').filter('.odd')
.removeClass('odd').addClass('even')
.end().end()

+ 5
- 5
misc/teaser.js View File

@@ -1,4 +1,4 @@
// $Id: teaser.js,v 1.12 2008/01/09 12:10:04 goba Exp $
// $Id: teaser.js,v 1.12.2.1 2009/05/20 11:50:54 goba Exp $

/**
* Auto-attach for teaser behavior.
@@ -71,10 +71,10 @@ Drupal.behaviors.teaser = function(context) {
$(include).parent().parent().before(button);

// Extract the teaser from the body, if set. Otherwise, stay in joined mode.
var text = body.val().split('<!--break-->', 2);
if (text.length == 2) {
teaser[0].value = trim(text[0]);
body[0].value = trim(text[1]);
var text = body.val().split('<!--break-->');
if (text.length >= 2) {
teaser[0].value = trim(text.shift());
body[0].value = trim(text.join('<!--break-->'));
$(teaser).attr('disabled', '');
$('input', button).val(Drupal.t('Join summary')).toggle(join_teaser, split_teaser);
}

+ 3
- 3
modules/aggregator/aggregator.info View File

@@ -5,8 +5,8 @@ package = Core - optional
version = VERSION
core = 6.x

; Information added by drupal.org packaging script on 2009-05-13
version = "6.12"
; Information added by drupal.org packaging script on 2009-09-16
version = "6.14"
project = "drupal"
datestamp = "1242243950"
datestamp = "1253130027"


+ 3
- 3
modules/block/block.info View File

@@ -5,8 +5,8 @@ package = Core - required
version = VERSION
core = 6.x

; Information added by drupal.org packaging script on 2009-05-13
version = "6.12"
; Information added by drupal.org packaging script on 2009-09-16
version = "6.14"
project = "drupal"
datestamp = "1242243950"
datestamp = "1253130027"


+ 3
- 3
modules/blog/blog.info View File

@@ -5,8 +5,8 @@ package = Core - optional
version = VERSION
core = 6.x

; Information added by drupal.org packaging script on 2009-05-13
version = "6.12"
; Information added by drupal.org packaging script on 2009-09-16
version = "6.14"
project = "drupal"
datestamp = "1242243950"
datestamp = "1253130027"


+ 4
- 4
modules/blog/blog.pages.inc View File

@@ -1,5 +1,5 @@
<?php
// $Id: blog.pages.inc,v 1.6.2.1 2008/02/08 21:15:12 goba Exp $
// $Id: blog.pages.inc,v 1.6.2.3 2009/09/14 15:08:00 goba Exp $

/**
* @file
@@ -58,7 +58,7 @@ function blog_page_last() {
$output = '';
$items = array();

if (user_access('edit own blog')) {
if (user_access('create blog entries')) {
$items[] = l(t('Create new blog entry.'), "node/add/blog");
}

@@ -88,7 +88,7 @@ function blog_page_last() {
*/
function blog_feed_user($account) {
$result = db_query_range(db_rewrite_sql("SELECT n.nid, n.created FROM {node} n WHERE n.type = 'blog' AND n.uid = %d AND n.status = 1 ORDER BY n.created DESC"), $account->uid, 0, variable_get('feed_default_items', 10));
$channel['title'] = $account->name ."'s blog";
$channel['title'] = t("!name's blog", array('!name' => $account->name));
$channel['link'] = url('blog/'. $account->uid, array('absolute' => TRUE));

$items = array();
@@ -103,7 +103,7 @@ function blog_feed_user($account) {
*/
function blog_feed_last() {
$result = db_query_range(db_rewrite_sql("SELECT n.nid, n.created FROM {node} n WHERE n.type = 'blog' AND n.status = 1 ORDER BY n.created DESC"), 0, variable_get('feed_default_items', 10));
$channel['title'] = variable_get('site_name', 'Drupal') .' blogs';
$channel['title'] = t('!site_name blogs', array('!site_name' => variable_get('site_name', 'Drupal')));
$channel['link'] = url('blog', array('absolute' => TRUE));

$items = array();

+ 3
- 3
modules/blogapi/blogapi.info View File

@@ -5,8 +5,8 @@ package = Core - optional
version = VERSION
core = 6.x

; Information added by drupal.org packaging script on 2009-05-13
version = "6.12"
; Information added by drupal.org packaging script on 2009-09-16
version = "6.14"
project = "drupal"
datestamp = "1242243950"
datestamp = "1253130027"


+ 3
- 3
modules/book/book.info View File

@@ -5,8 +5,8 @@ package = Core - optional
version = VERSION
core = 6.x

; Information added by drupal.org packaging script on 2009-05-13
version = "6.12"
; Information added by drupal.org packaging script on 2009-09-16
version = "6.14"
project = "drupal"
datestamp = "1242243950"
datestamp = "1253130027"


+ 3
- 3
modules/color/color.info View File

@@ -5,8 +5,8 @@ package = Core - optional
version = VERSION
core = 6.x

; Information added by drupal.org packaging script on 2009-05-13
version = "6.12"
; Information added by drupal.org packaging script on 2009-09-16
version = "6.14"
project = "drupal"
datestamp = "1242243950"
datestamp = "1253130027"


+ 2
- 2
modules/color/color.module View File

@@ -1,5 +1,5 @@
<?php
// $Id: color.module,v 1.39.2.1 2009/02/25 11:47:37 goba Exp $
// $Id: color.module,v 1.39.2.2 2009/05/16 16:09:21 dries Exp $

/**
* Implementation of hook_help().
@@ -203,7 +203,7 @@ function color_scheme_form(&$form_state, $theme) {
/**
* Theme color form.
*
* @ingroup @themeable
* @ingroup themeable
*/
function theme_color_scheme_form($form) {
// Include stylesheet

+ 3
- 3
modules/comment/comment.info View File

@@ -5,8 +5,8 @@ package = Core - optional
version = VERSION
core = 6.x

; Information added by drupal.org packaging script on 2009-05-13
version = "6.12"
; Information added by drupal.org packaging script on 2009-09-16
version = "6.14"
project = "drupal"
datestamp = "1242243950"
datestamp = "1253130027"


+ 10
- 10
modules/comment/comment.module View File

@@ -1,5 +1,5 @@
<?php
// $Id: comment.module,v 1.617.2.7 2009/05/13 17:15:10 goba Exp $
// $Id: comment.module,v 1.617.2.10 2009/09/14 10:36:42 goba Exp $

/**
* @file
@@ -757,7 +757,7 @@ function comment_save($edit) {
$edit['timestamp'] = time();
}

if ($edit['uid'] === $user->uid) { // '===' because we want to modify anonymous users too
if ($edit['uid'] === $user->uid && isset($user->name)) { // '===' Need to modify anonymous users as well.
$edit['name'] = $user->name;
}

@@ -936,7 +936,7 @@ function comment_render($node, $cid = 0) {

if ($cid && is_numeric($cid)) {
// Single comment view.
$query = 'SELECT c.cid, c.pid, c.nid, c.subject, c.comment, c.format, c.timestamp, c.name, c.mail, c.homepage, u.uid, u.name AS registered_name, u.signature, u.picture, u.data, c.status FROM {comments} c INNER JOIN {users} u ON c.uid = u.uid WHERE c.cid = %d';
$query = 'SELECT c.cid, c.pid, c.nid, c.subject, c.comment, c.format, c.timestamp, c.name, c.mail, c.homepage, u.uid, u.name AS registered_name, u.signature, u.signature_format, u.picture, u.data, c.status FROM {comments} c INNER JOIN {users} u ON c.uid = u.uid WHERE c.cid = %d';
$query_args = array($cid);
if (!user_access('administer comments')) {
$query .= ' AND c.status = %d';
@@ -957,7 +957,7 @@ function comment_render($node, $cid = 0) {
else {
// Multiple comment view
$query_count = 'SELECT COUNT(*) FROM {comments} c WHERE c.nid = %d';
$query = 'SELECT c.cid as cid, c.pid, c.nid, c.subject, c.comment, c.format, c.timestamp, c.name, c.mail, c.homepage, u.uid, u.name AS registered_name, u.signature, u.picture, u.data, c.thread, c.status FROM {comments} c INNER JOIN {users} u ON c.uid = u.uid WHERE c.nid = %d';
$query = 'SELECT c.cid as cid, c.pid, c.nid, c.subject, c.comment, c.format, c.timestamp, c.name, c.mail, c.homepage, u.uid, u.name AS registered_name, u.signature, u.signature_format, u.picture, u.data, c.thread, c.status FROM {comments} c INNER JOIN {users} u ON c.uid = u.uid WHERE c.nid = %d';

$query_args = array($nid);
if (!user_access('administer comments')) {
@@ -1384,7 +1384,7 @@ function comment_form(&$form_state, $edit, $title = NULL) {
$form['cid'] = array('#type' => 'value', '#value' => !empty($edit['cid']) ? $edit['cid'] : NULL);
$form['pid'] = array('#type' => 'value', '#value' => !empty($edit['pid']) ? $edit['pid'] : NULL);
$form['nid'] = array('#type' => 'value', '#value' => $edit['nid']);
$form['uid'] = array('#type' => 'value', '#value' => !empty($edit['uid']) ? $edit['uid'] : NULL);
$form['uid'] = array('#type' => 'value', '#value' => !empty($edit['uid']) ? $edit['uid'] : 0);

// Only show save button if preview is optional or if we are in preview mode.
// We show the save button in preview mode even if there are form errors so that
@@ -1468,7 +1468,7 @@ function comment_form_add_preview($form, &$form_state) {
$output = '';

if ($edit['pid']) {
$comment = db_fetch_object(db_query('SELECT c.*, u.uid, u.name AS registered_name, u.signature, u.picture, u.data FROM {comments} c INNER JOIN {users} u ON c.uid = u.uid WHERE c.cid = %d AND c.status = %d', $edit['pid'], COMMENT_PUBLISHED));
$comment = db_fetch_object(db_query('SELECT c.*, u.uid, u.name AS registered_name, u.signature, u.signature_format, u.picture, u.data FROM {comments} c INNER JOIN {users} u ON c.uid = u.uid WHERE c.cid = %d AND c.status = %d', $edit['pid'], COMMENT_PUBLISHED));
$comment = drupal_unpack($comment);
$comment->name = $comment->uid ? $comment->registered_name : $comment->name;
$output .= theme('comment_view', $comment, $node);
@@ -1778,22 +1778,22 @@ function theme_comment_thread_expanded($comment, $node) {
function theme_comment_post_forbidden($node) {
global $user;
static $authenticated_post_comments;
if (!$user->uid) {
if (!isset($authenticated_post_comments)) {
// We only output any link if we are certain, that users get permission
// to post comments by logging in. We also locally cache this information.
$authenticated_post_comments = array_key_exists(DRUPAL_AUTHENTICATED_RID, user_roles(TRUE, 'post comments') + user_roles(TRUE, 'post comments without approval'));
}
if ($authenticated_post_comments) {
// We cannot use drupal_get_destination() because these links
// sometimes appear on /node and taxonomy listing pages.
if (variable_get('comment_form_location_'. $node->type, COMMENT_FORM_SEPARATE_PAGE) == COMMENT_FORM_SEPARATE_PAGE) {
$destination = 'destination='. drupal_urlencode("comment/reply/$node->nid#comment-form");
$destination = 'destination='. rawurlencode("comment/reply/$node->nid#comment-form");
}
else {
$destination = 'destination='. drupal_urlencode("node/$node->nid#comment-form");
$destination = 'destination='. rawurlencode("node/$node->nid#comment-form");
}

if (variable_get('user_register', 1)) {

+ 2
- 2
modules/comment/comment.pages.inc View File

@@ -1,5 +1,5 @@
<?php
// $Id: comment.pages.inc,v 1.2.2.1 2008/02/07 18:53:38 goba Exp $
// $Id: comment.pages.inc,v 1.2.2.2 2009/07/01 20:51:55 goba Exp $

/**
* @file
@@ -70,7 +70,7 @@ function comment_reply($node, $pid = NULL) {
// $pid indicates that this is a reply to a comment.
if ($pid) {
// load the comment whose cid = $pid
if ($comment = db_fetch_object(db_query('SELECT c.*, u.uid, u.name AS registered_name, u.signature, u.picture, u.data FROM {comments} c INNER JOIN {users} u ON c.uid = u.uid WHERE c.cid = %d AND c.status = %d', $pid, COMMENT_PUBLISHED))) {
if ($comment = db_fetch_object(db_query('SELECT c.*, u.uid, u.name AS registered_name, u.signature, u.signature_format, u.picture, u.data FROM {comments} c INNER JOIN {users} u ON c.uid = u.uid WHERE c.cid = %d AND c.status = %d', $pid, COMMENT_PUBLISHED))) {
// If that comment exists, make sure that the current comment and the parent comment both
// belong to the same parent node.
if ($comment->nid != $node->nid) {

+ 3
- 3
modules/contact/contact.info View File

@@ -5,8 +5,8 @@ package = Core - optional
version = VERSION
core = 6.x

; Information added by drupal.org packaging script on 2009-05-13
version = "6.12"
; Information added by drupal.org packaging script on 2009-09-16
version = "6.14"
project = "drupal"
datestamp = "1242243950"
datestamp = "1253130027"


+ 3
- 3
modules/dblog/dblog.info View File

@@ -5,8 +5,8 @@ package = Core - optional
version = VERSION
core = 6.x

; Information added by drupal.org packaging script on 2009-05-13
version = "6.12"
; Information added by drupal.org packaging script on 2009-09-16
version = "6.14"
project = "drupal"
datestamp = "1242243950"
datestamp = "1253130027"


+ 21
- 5
modules/dblog/dblog.install View File

@@ -1,5 +1,5 @@
<?php
// $Id: dblog.install,v 1.6.2.1 2009/01/06 15:46:36 goba Exp $
// $Id: dblog.install,v 1.6.2.3 2009/09/14 08:19:24 goba Exp $

/**
* Implementation of hook_install().
@@ -75,10 +75,8 @@ function dblog_schema() {
'description' => 'URL of the origin of the event.',
),
'referer' => array(
'type' => 'varchar',
'length' => 128,
'not null' => TRUE,
'default' => '',
'type' => 'text',
'not null' => FALSE,
'description' => 'URL of referring page.',
),
'hostname' => array(
@@ -102,3 +100,21 @@ function dblog_schema() {
return $schema;
}

/**
* @defgroup updates-6.x-extra Extra database logging updates for 6.x
* @{
*/

/**
* Allow longer referrers.
*/
function dblog_update_6000() {
$ret = array();
db_change_field($ret, 'watchdog', 'referer', 'referer', array('type' => 'text', 'not null' => FALSE));
return $ret;
}

/**
* @} End of "defgroup updates-6.x-extra"
* The next series of updates should start at 7000.
*/

+ 3
- 3
modules/filter/filter.info View File

@@ -5,8 +5,8 @@ package = Core - required
version = VERSION
core = 6.x

; Information added by drupal.org packaging script on 2009-05-13
version = "6.12"
; Information added by drupal.org packaging script on 2009-09-16
version = "6.14"
project = "drupal"
datestamp = "1242243950"
datestamp = "1253130027"


+ 3
- 3
modules/filter/filter.module View File

@@ -1,5 +1,5 @@
<?php
// $Id: filter.module,v 1.204.2.8 2008/12/10 22:30:14 goba Exp $
// $Id: filter.module,v 1.204.2.9 2009/08/10 11:04:37 goba Exp $

/**
* @file
@@ -977,12 +977,12 @@ function filter_xss($string, $allowed_tags = array('a', 'em', 'strong', 'cite',
// Defuse all HTML entities
$string = str_replace('&', '&amp;', $string);
// Change back only well-formed entities in our whitelist
// Named entities
$string = preg_replace('/&amp;([A-Za-z][A-Za-z0-9]*;)/', '&\1', $string);
// Decimal numeric entities
$string = preg_replace('/&amp;#([0-9]+;)/', '&#\1', $string);
// Hexadecimal numeric entities
$string = preg_replace('/&amp;#[Xx]0*((?:[0-9A-Fa-f]{2})+;)/', '&#x\1', $string);
// Named entities
$string = preg_replace('/&amp;([A-Za-z][A-Za-z0-9]*;)/', '&\1', $string);

return preg_replace_callback('%
(

+ 1
- 2
modules/forum/forum.admin.inc View File

@@ -1,5 +1,5 @@
<?php
// $Id: forum.admin.inc,v 1.8 2008/01/30 10:14:42 goba Exp $
// $Id: forum.admin.inc,v 1.8.2.1 2009/05/26 08:13:00 goba Exp $

/**
* @file
@@ -220,7 +220,6 @@ function forum_overview(&$form_state) {
$vid = variable_get('forum_nav_vocabulary', '');
$vocabulary = taxonomy_vocabulary_load($vid);
$form = taxonomy_overview_terms($form_state, $vocabulary);
drupal_set_title('Forums');

foreach (element_children($form) as $key) {
if (isset($form[$key]['#term'])) {

+ 3
- 3
modules/forum/forum.info View File

@@ -7,8 +7,8 @@ package = Core - optional
version = VERSION
core = 6.x

; Information added by drupal.org packaging script on 2009-05-13
version = "6.12"
; Information added by drupal.org packaging script on 2009-09-16
version = "6.14"
project = "drupal"
datestamp = "1242243950"
datestamp = "1253130027"


+ 3
- 3
modules/forum/forum.module View File

@@ -1,5 +1,5 @@
<?php
// $Id: forum.module,v 1.448.2.6 2009/03/30 11:09:51 goba Exp $
// $Id: forum.module,v 1.448.2.7 2009/06/03 18:27:48 goba Exp $

/**
* @file
@@ -679,11 +679,11 @@ function template_preprocess_forums(&$variables) {
if (empty($forum_types)) {
// The user is logged-in; but denied access to create any new forum content type.
if ($user->uid) {
$forum_types['disallowed'] = array('title' => t('You are not allowed to post new content in forum.'));
$forum_types['disallowed'] = array('title' => t('You are not allowed to post new content in the forum.'));
}
// The user is not logged-in; and denied access to create any new forum content type.
else {
$forum_types['login'] = array('title' => t('<a href="@login">Login</a> to post new content in forum.', array('@login' => url('user/login', array('query' => drupal_get_destination())))), 'html' => TRUE);
$forum_types['login'] = array('title' => t('<a href="@login">Login</a> to post new content in the forum.', array('@login' => url('user/login', array('query' => drupal_get_destination())))), 'html' => TRUE);
}
}
$variables['links'] = $forum_types;

+ 6
- 1
modules/forum/forum.pages.inc View File

@@ -1,5 +1,5 @@
<?php
// $Id: forum.pages.inc,v 1.2 2007/07/26 06:48:03 dries Exp $
// $Id: forum.pages.inc,v 1.2.2.1 2009/07/01 20:51:55 goba Exp $

/**
* @file
@@ -10,6 +10,11 @@
* Menu callback; prints a forum listing.
*/
function forum_page($tid = 0) {
if (!is_numeric($tid)) {
return MENU_NOT_FOUND;
}
$tid = (int)$tid;

$topics = '';
$forum_per_page = variable_get('forum_per_page', 25);
$sortby = variable_get('forum_order', 1);

+ 3
- 3
modules/help/help.info View File

@@ -5,8 +5,8 @@ package = Core - optional
version = VERSION
core = 6.x

; Information added by drupal.org packaging script on 2009-05-13
version = "6.12"
; Information added by drupal.org packaging script on 2009-09-16
version = "6.14"
project = "drupal"
datestamp = "1242243950"
datestamp = "1253130027"


+ 3
- 3
modules/locale/locale.info View File

@@ -5,8 +5,8 @@ package = Core - optional
version = VERSION
core = 6.x

; Information added by drupal.org packaging script on 2009-05-13
version = "6.12"
; Information added by drupal.org packaging script on 2009-09-16
version = "6.14"
project = "drupal"
datestamp = "1242243950"
datestamp = "1253130027"


+ 3
- 3
modules/menu/menu.info View File

@@ -5,8 +5,8 @@ package = Core - optional
version = VERSION
core = 6.x

; Information added by drupal.org packaging script on 2009-05-13
version = "6.12"
; Information added by drupal.org packaging script on 2009-09-16
version = "6.14"
project = "drupal"
datestamp = "1242243950"
datestamp = "1253130027"


+ 2
- 2
modules/node/content_types.inc View File

@@ -1,5 +1,5 @@
<?php
// $Id: content_types.inc,v 1.50.2.2 2009/04/27 14:28:57 goba Exp $
// $Id: content_types.inc,v 1.50.2.3 2009/09/14 11:51:23 goba Exp $

/**
* @file
@@ -214,7 +214,7 @@ function node_type_form(&$form_state, $type = NULL) {
}

/**
* Implementation of hook_form_validate().
* Validates the content type submission form generated by node_type_form().
*/
function node_type_form_validate($form, &$form_state) {
$type = new stdClass();

+ 14
- 19
modules/node/node.admin.inc View File

@@ -1,5 +1,5 @@
<?php
// $Id: node.admin.inc,v 1.19.2.2 2008/11/10 10:31:06 goba Exp $
// $Id: node.admin.inc,v 1.19.2.3 2009/06/08 16:45:34 goba Exp $

/**
* @file
@@ -10,24 +10,19 @@
* Menu callback; presents general node configuration options.
*/
function node_configure() {
// Only show rebuild button if there are either 0, or 2 or more, rows
// in the {node_access} table, or if there are modules that
// implement hook_node_grants().
if (db_result(db_query('SELECT COUNT(*) FROM {node_access}')) != 1 || count(module_implements('node_grants')) > 0) {
$status = '<p>'. t('If the site is experiencing problems with permissions to content, you may have to rebuild the permissions cache. Possible causes for permission problems are disabling modules or configuration changes to permissions. Rebuilding will remove all privileges to posts, and replace them with permissions based on the current modules and settings.') .'</p>';
$status .= '<p>'. t('Rebuilding may take some time if there is a lot of content or complex permission settings. After rebuilding has completed posts will automatically use the new permissions.') .'</p>';

$form['access'] = array(
'#type' => 'fieldset',
'#title' => t('Node access status'),
);
$form['access']['status'] = array('#value' => $status);
$form['access']['rebuild'] = array(
'#type' => 'submit',
'#value' => t('Rebuild permissions'),
'#submit' => array('node_configure_access_submit'),
);
}
$status = '<p>'. t('If the site is experiencing problems with permissions to content, you may have to rebuild the permissions cache. Possible causes for permission problems are disabling modules or configuration changes to permissions. Rebuilding will remove all privileges to posts, and replace them with permissions based on the current modules and settings.') .'</p>';
$status .= '<p>'. t('Rebuilding may take some time if there is a lot of content or complex permission settings. After rebuilding has completed posts will automatically use the new permissions.') .'</p>';

$form['access'] = array(
'#type' => 'fieldset',
'#title' => t('Node access status'),
);
$form['access']['status'] = array('#value' => $status);
$form['access']['rebuild'] = array(
'#type' => 'submit',
'#value' => t('Rebuild permissions'),
'#submit' => array('node_configure_access_submit'),
);

$form['default_nodes_main'] = array(
'#type' => 'select', '#title' => t('Number of posts on main page'), '#default_value' => variable_get('default_nodes_main', 10),

+ 3
- 3
modules/node/node.info View File

@@ -5,8 +5,8 @@ package = Core - required
version = VERSION
core = 6.x

; Information added by drupal.org packaging script on 2009-05-13
version = "6.12"
; Information added by drupal.org packaging script on 2009-09-16
version = "6.14"
project = "drupal"
datestamp = "1242243950"
datestamp = "1253130027"


+ 9
- 9
modules/node/node.module View File

@@ -1,5 +1,5 @@
<?php
// $Id: node.module,v 1.947.2.15 2009/02/16 14:39:40 goba Exp $
// $Id: node.module,v 1.947.2.18 2009/09/16 18:21:06 goba Exp $

/**
* @file
@@ -1988,7 +1988,7 @@ function node_search_validate($form, &$form_state) {
* Optional, a user object representing the user for whom the operation is to
* be performed. Determines access for a user other than the current user.
* @return
* TRUE if the operation may be performed.
* TRUE if the operation may be performed, or FALSE otherwise.
*/
function node_access($op, $node, $account = NULL) {
global $user;
@@ -2045,9 +2045,9 @@ function node_access($op, $node, $account = NULL) {
$grants_sql = 'AND ('. implode(' OR ', $grants) .')';
}

$sql = "SELECT COUNT(*) FROM {node_access} WHERE (nid = 0 OR nid = %d) $grants_sql AND grant_$op >= 1";
$result = db_query($sql, $node->nid);
return (db_result($result));
$sql = "SELECT 1 FROM {node_access} WHERE (nid = 0 OR nid = %d) $grants_sql AND grant_$op >= 1";
$result = db_query_range($sql, $node->nid, 0, 1);
return (bool) db_result($result);
}

// Let authors view their own nodes.
@@ -2318,9 +2318,9 @@ function node_access_rebuild($batch_mode = FALSE) {
batch_set($batch);
}
else {
// If not in 'safe mode', increase the maximum execution time.
if (!ini_get('safe_mode')) {
set_time_limit(240);
// Try to allocate enough time to rebuild node grants
if (function_exists('set_time_limit')) {
@set_time_limit($time_limit);
}
$result = db_query("SELECT nid FROM {node}");
while ($node = db_fetch_object($result)) {
@@ -2709,7 +2709,7 @@ function node_assign_owner_action_form($context) {
'#default_value' => $owner_name,
'#autocomplete_path' => 'user/autocomplete',
'#size' => '6',
'#maxlength' => '7',
'#maxlength' => '60',
'#description' => $description,
);
}

+ 2
- 2
modules/node/node.tpl.php View File

@@ -1,5 +1,5 @@
<?php
// $Id: node.tpl.php,v 1.4 2008/01/25 21:21:44 goba Exp $
// $Id: node.tpl.php,v 1.4.2.1 2009/08/10 10:48:33 goba Exp $

/**
* @file node.tpl.php
@@ -15,7 +15,7 @@
* format_date()).
* - $links: Themed links like "Read more", "Add new comment", etc. output
* from theme_links().
* - $name: Themed username of node author output from theme_user().
* - $name: Themed username of node author output from theme_username().
* - $node_url: Direct url of the current node.
* - $terms: the themed list of taxonomy term links output from theme_links().
* - $submitted: themed submission information output from

BIN
modules/openid/login-bg.png View File


+ 8
- 5
modules/openid/openid.inc View File

@@ -1,5 +1,5 @@
<?php
// $Id: openid.inc,v 1.8 2008/01/30 22:11:22 goba Exp $
// $Id: openid.inc,v 1.8.2.1 2009/09/16 17:58:24 goba Exp $

/**
* @file
@@ -74,11 +74,14 @@ function openid_redirect_form(&$form_state, $url, $message) {
* Determine if the given identifier is an XRI ID.
*/
function _openid_is_xri($identifier) {
$firstchar = substr($identifier, 0, 1);
if ($firstchar == "@" || $firstchar == "=")
return TRUE;
// Strip the xri:// scheme from the identifier if present.
if (stripos($identifier, 'xri://') !== FALSE) {
$identifier = substr($identifier, 6);
}

if (stristr($identifier, 'xri://') !== FALSE) {
// Test whether the identifier starts with an XRI global context symbol or (.
$firstchar = substr($identifier, 0, 1);
if (strpos("=@+$!(", $firstchar) !== FALSE) {
return TRUE;
}


+ 3
- 3
modules/openid/openid.info View File

@@ -5,8 +5,8 @@ version = VERSION
package = Core - optional
core = 6.x

; Information added by drupal.org packaging script on 2009-05-13
version = "6.12"
; Information added by drupal.org packaging script on 2009-09-16
version = "6.14"
project = "drupal"
datestamp = "1242243950"
datestamp = "1253130027"


+ 6
- 6
modules/openid/openid.module View File

@@ -1,5 +1,5 @@
<?php
// $Id: openid.module,v 1.19.2.5 2009/03/30 11:36:47 goba Exp $
// $Id: openid.module,v 1.19.2.8 2009/09/16 19:34:14 goba Exp $

/**
* @file
@@ -44,8 +44,8 @@ function openid_menu() {
function openid_help($path, $arg) {
switch ($path) {
case 'user/%/openid':
$output = '<p>'. t('This site supports <a href="@openid-net">OpenID</a>, a secure way to log into many websites using a single username and password. OpenID can reduce the necessity of managing many usernames and passwords for many websites.', array('@openid-net' => url('http://openid.net'))) .'</p>';
$output .= '<p>'. t('To use OpenID you must first establish an identity on a public or private OpenID server. If you do not have an OpenID and would like one, look into one of the <a href="@openid-providers">free public providers</a>. You can find out more about OpenID at <a href="@openid-net">this website</a>.', array('@openid-providers' => url('http://openid.net/wiki/index.php/OpenIDServers'), '@openid-net' => url('http://openid.net'))) .'</p>';
$output = '<p>'. t('This site supports <a href="@openid-net">OpenID</a>, a secure way to log into many websites using a single username and password. OpenID can reduce the necessity of managing many usernames and passwords for many websites.', array('@openid-net' => 'http://openid.net')) .'</p>';
$output .= '<p>'. t('To use OpenID you must first establish an identity on a public or private OpenID server. If you do not have an OpenID and would like one, look into one of the <a href="@openid-providers">free public providers</a>. You can find out more about OpenID at <a href="@openid-net">this website</a>.', array('@openid-providers' => 'http://openid.net/get/', '@openid-net' => 'http://openid.net')) .'</p>';
$output .= '<p>'. t('If you already have an OpenID, enter the URL to your OpenID server below (e.g. myusername.openidprovider.com). Next time you login, you will be able to use this URL instead of a regular username and password. You can have multiple OpenID servers if you like; just keep adding them here.') .'</p>';
return $output;

@@ -113,7 +113,7 @@ function openid_form_alter(&$form, $form_state, $form_id) {
);
$form['openid.return_to'] = array('#type' => 'hidden', '#value' => url('openid/authenticate', array('absolute' => TRUE, 'query' => drupal_get_destination())));
}
elseif ($form_id == 'user_register' && isset($_SESSION['openid'])) {
elseif ($form_id == 'user_register' && isset($_SESSION['openid']['values'])) {
// We were unable to auto-register a new user. Prefill the registration
// form with the values we have.
$form['name']['#default_value'] = $_SESSION['openid']['values']['name'];
@@ -192,8 +192,8 @@ function openid_begin($claimed_id, $return_to = '', $form_values = array()) {
}

if (isset($services[0]['types']) && is_array($services[0]['types']) && in_array(OPENID_NS_2_0 .'/server', $services[0]['types'])) {
$identity = 'http://specs.openid.net/auth/2.0/identifier_select';
}
$claimed_id = $identity = 'http://specs.openid.net/auth/2.0/identifier_select';
}
$authn_request = openid_authentication_request($claimed_id, $identity, $return_to, $assoc_handle, $services[0]['version']);

if ($services[0]['version'] == 2) {

+ 7
- 5
modules/openid/openid.pages.inc View File

@@ -1,5 +1,5 @@
<?php
// $Id: openid.pages.inc,v 1.5.2.1 2008/07/09 21:48:28 goba Exp $
// $Id: openid.pages.inc,v 1.5.2.2 2009/09/16 19:34:14 goba Exp $

/**
* @file
@@ -73,12 +73,14 @@ function openid_user_add_validate($form, &$form_state) {
if (db_result(db_query("SELECT authname FROM {authmap} WHERE authname='%s'", $claimed_id))) {
form_set_error('openid_identifier', t('That OpenID is already in use on this site.'));
}
else {
$return_to = url('user/'. arg(1) .'/openid', array('absolute' => TRUE));
openid_begin($form_state['values']['openid_identifier'], $return_to);
}
}

function openid_user_add_submit($form, &$form_state) {
$return_to = url('user/'. arg(1) .'/openid', array('absolute' => TRUE));
openid_begin($form_state['values']['openid_identifier'], $return_to);
}


/**
* Present a confirmation form to delete the specified OpenID identity from the system.
*

+ 3
- 3
modules/path/path.info View File

@@ -5,8 +5,8 @@ package = Core - optional
version = VERSION
core = 6.x

; Information added by drupal.org packaging script on 2009-05-13
version = "6.12"
; Information added by drupal.org packaging script on 2009-09-16
version = "6.14"
project = "drupal"
datestamp = "1242243950"
datestamp = "1253130027"


+ 3
- 3
modules/php/php.info View File

@@ -5,8 +5,8 @@ package = Core - optional
version = VERSION
core = 6.x

; Information added by drupal.org packaging script on 2009-05-13
version = "6.12"
; Information added by drupal.org packaging script on 2009-09-16
version = "6.14"
project = "drupal"
datestamp = "1242243950"
datestamp = "1253130027"


+ 3
- 3
modules/ping/ping.info View File

@@ -5,8 +5,8 @@ package = Core - optional
version = VERSION
core = 6.x

; Information added by drupal.org packaging script on 2009-05-13
version = "6.12"
; Information added by drupal.org packaging script on 2009-09-16
version = "6.14"
project = "drupal"
datestamp = "1242243950"
datestamp = "1253130027"


+ 3
- 3
modules/poll/poll.info View File

@@ -5,8 +5,8 @@ package = Core - optional
version = VERSION
core = 6.x

; Information added by drupal.org packaging script on 2009-05-13
version = "6.12"
; Information added by drupal.org packaging script on 2009-09-16
version = "6.14"
project = "drupal"
datestamp = "1242243950"
datestamp = "1253130027"


+ 2
- 2
modules/poll/poll.module View File

@@ -1,5 +1,5 @@
<?php
// $Id: poll.module,v 1.263.2.3 2008/12/18 15:46:20 dries Exp $
// $Id: poll.module,v 1.263.2.4 2009/09/14 10:16:54 goba Exp $

/**
* @file
@@ -355,7 +355,7 @@ function poll_choice_js() {
}

/**
* Implementation of hook_submit().
* Renumbers fields and creates a teaser when a poll node is submitted.
*/
function poll_node_form_submit(&$form, &$form_state) {
// Renumber fields

+ 3
- 3
modules/profile/profile.info View File

@@ -5,8 +5,8 @@ package = Core - optional
version = VERSION
core = 6.x

; Information added by drupal.org packaging script on 2009-05-13
version = "6.12"
; Information added by drupal.org packaging script on 2009-09-16
version = "6.14"
project = "drupal"
datestamp = "1242243950"
datestamp = "1253130027"


+ 3
- 3
modules/search/search.info View File

@@ -5,8 +5,8 @@ package = Core - optional
version = VERSION
core = 6.x

; Information added by drupal.org packaging script on 2009-05-13
version = "6.12"
; Information added by drupal.org packaging script on 2009-09-16
version = "6.14"
project = "drupal"
datestamp = "1242243950"
datestamp = "1253130027"


+ 12
- 1
modules/search/search.module View File

@@ -1,5 +1,5 @@
<?php
// $Id: search.module,v 1.250.2.6 2009/03/10 17:20:01 goba Exp $
// $Id: search.module,v 1.250.2.7 2009/09/14 14:55:09 goba Exp $

/**
* @file
@@ -1081,6 +1081,17 @@ function search_box(&$form_state, $form_id) {
* Process a block search form submission.
*/
function search_box_form_submit($form, &$form_state) {
// The search form relies on control of the redirect destination for its
// functionality, so we override any static destination set in the request,
// for example by drupal_access_denied() or drupal_not_found()
// (see http://drupal.org/node/292565).
if (isset($_REQUEST['destination'])) {
unset($_REQUEST['destination']);
}
if (isset($_REQUEST['edit']['destination'])) {
unset($_REQUEST['edit']['destination']);
}

$form_id = $form['form_id']['#value'];
$form_state['redirect'] = 'search/node/'. trim($form_state['values'][$form_id]);
}

+ 3
- 3
modules/statistics/statistics.info View File

@@ -5,8 +5,8 @@ package = Core - optional
version = VERSION
core = 6.x

; Information added by drupal.org packaging script on 2009-05-13
version = "6.12"
; Information added by drupal.org packaging script on 2009-09-16
version = "6.14"
project = "drupal"
datestamp = "1242243950"
datestamp = "1253130027"


+ 20
- 3
modules/statistics/statistics.install View File

@@ -1,5 +1,5 @@
<?php
// $Id: statistics.install,v 1.13.2.1 2009/01/06 15:46:37 goba Exp $
// $Id: statistics.install,v 1.13.2.3 2009/09/14 08:19:24 goba Exp $

/**
* Implementation of hook_install().
@@ -76,8 +76,7 @@ function statistics_schema() {
'description' => 'Internal path to page visited (relative to Drupal root.)',
),
'url' => array(
'type' => 'varchar',
'length' => 255,
'type' => 'text',
'not null' => FALSE,
'description' => 'Referrer URI.',
),
@@ -119,3 +118,21 @@ function statistics_schema() {
return $schema;
}

/**
* @defgroup updates-6.x-extra Extra statistics updates for 6.x
* @{
*/

/**
* Allow longer referrers.
*/
function statistics_update_6000() {
$ret = array();
db_change_field($ret, 'accesslog', 'url', 'url', array('type' => 'text', 'not null' => FALSE));
return $ret;
}

/**
* @} End of "defgroup updates-6.x-extra"
* The next series of updates should start at 7000.
*/

+ 3
- 3
modules/syslog/syslog.info View File

@@ -5,8 +5,8 @@ package = Core - optional
version = VERSION
core = 6.x

; Information added by drupal.org packaging script on 2009-05-13
version = "6.12"
; Information added by drupal.org packaging script on 2009-09-16
version = "6.14"
project = "drupal"
datestamp = "1242243950"
datestamp = "1253130027"


+ 20
- 13
modules/system/system.admin.inc View File

@@ -1,5 +1,5 @@
<?php
// $Id: system.admin.inc,v 1.63.2.7 2009/02/25 11:38:41 goba Exp $
// $Id: system.admin.inc,v 1.63.2.13 2009/09/16 18:02:32 goba Exp $

/**
* @file
@@ -187,7 +187,6 @@ function system_admin_theme_settings() {
*/
function system_themes_form() {

drupal_clear_css_cache();
$themes = system_theme_data();

uasort($themes, 'system_sort_modules_by_info_name');
@@ -198,13 +197,20 @@ function system_themes_form() {

foreach ($themes as $theme) {
$screenshot = NULL;
$theme_key = $theme->name;
while ($theme_key) {
if (file_exists($themes[$theme_key]->info['screenshot'])) {
// Create a list which includes the current theme and all its base themes.
if (isset($themes[$theme->name]->base_themes)) {
$theme_keys = array_keys($themes[$theme->name]->base_themes);
$theme_keys[] = $theme->name;
}
else {
$theme_keys = array($theme->name);
}
// Look for a screenshot in the current theme or in its closest ancestor.
foreach (array_reverse($theme_keys) as $theme_key) {
if (isset($themes[$theme_key]) && file_exists($themes[$theme_key]->info['screenshot'])) {
$screenshot = $themes[$theme_key]->info['screenshot'];
break;
}
$theme_key = isset($themes[$theme_key]->info['base theme']) ? $themes[$theme_key]->info['base theme'] : NULL;
}
$screenshot = $screenshot ? theme('image', $screenshot, t('Screenshot for %theme theme', array('%theme' => $theme->info['name'])), '', array('class' => 'screenshot'), FALSE) : t('no screenshot');

@@ -263,6 +269,7 @@ function system_themes_form() {
* Process system_themes_form form submissions.
*/
function system_themes_form_submit($form, &$form_state) {
drupal_clear_css_cache();