diff --git a/includes/actions.inc b/includes/actions.inc index 511776126f4511b178b6414b504879e85b13f81e..008410fb49a1af9716d5157d7d73ee10df82dd3f 100644 --- a/includes/actions.inc +++ b/includes/actions.inc @@ -2,9 +2,9 @@ // $Id$ /** -* @file -* This is the actions engine for executing stored actions. -*/ + * @file + * This is the actions engine for executing stored actions. + */ /** * Perform a given list of actions by executing their callback functions. diff --git a/includes/batch.inc b/includes/batch.inc index 9f57162fa531d96fbe3134e52c1c2993ec2f20f2..cced0b4267f6f871d4b0bf549ce505d871888bed 100644 --- a/includes/batch.inc +++ b/includes/batch.inc @@ -291,7 +291,7 @@ function _batch_finished() { $batch =& batch_get(); // Execute the 'finished' callbacks for each batch set. - foreach($batch['sets'] as $key => $batch_set) { + foreach ($batch['sets'] as $key => $batch_set) { if (isset($batch_set['finished'])) { // Check if the set requires an additional file for functions definitions. if (isset($batch_set['file']) && is_file($batch_set['file'])) { diff --git a/includes/bootstrap.inc b/includes/bootstrap.inc index 5345d59260a8edaa84820eb32f939632d38eddd9..772eb56217836b0c0a41fb000e3142f4e7855798 100644 --- a/includes/bootstrap.inc +++ b/includes/bootstrap.inc @@ -521,7 +521,7 @@ function bootstrap_invoke_all($hook) { foreach (module_list(TRUE, TRUE) as $module) { drupal_load('module', $module); module_invoke($module, $hook); - } + } } /** @@ -786,7 +786,7 @@ function drupal_get_messages($type = NULL, $clear_queue = TRUE) { if ($messages = drupal_set_message()) { if ($type) { if ($clear_queue) { - unset($_SESSION['messages'][$type]); + unset($_SESSION['messages'][$type]); } if (isset($messages[$type])) { return array($type => $messages[$type]); @@ -794,7 +794,7 @@ function drupal_get_messages($type = NULL, $clear_queue = TRUE) { } else { if ($clear_queue) { - unset($_SESSION['messages']); + unset($_SESSION['messages']); } return $messages; } diff --git a/includes/common.inc b/includes/common.inc index 1da58971ea5300218cd7c5efc8d8c7f4aa7c2efe..9eb381a6a676cd403793a31de0c6521b2828fc43 100644 --- a/includes/common.inc +++ b/includes/common.inc @@ -1319,7 +1319,7 @@ function url($path = NULL, $options = array()) { // Will be empty if there is no language prefix. $path = trim($options['prefix'], '/'); } - + if ($clean_url) { // With Clean URLs. if ($options['query']) { @@ -1337,7 +1337,7 @@ function url($path = NULL, $options = array()) { } if (!empty($options['query'])) { $variables[] = $options['query']; - } + } if ($query = join('&', $variables)) { return $base . $script .'?'. $query . $options['fragment']; } @@ -1757,7 +1757,7 @@ function drupal_build_css_cache($types, $filename) { /** * Helper function for drupal_build_css_cache(). - * + * * This function will prefix all paths within a CSS file. */ function _drupal_build_css_path($matches, $base = NULL) { @@ -1835,7 +1835,7 @@ function drupal_load_stylesheet($file, $optimize = NULL) { /** * Loads stylesheets recursively and returns contents with corrected paths. - * + * * This function is used for recursive loading of stylesheets and * returns the stylesheet content with all url() paths corrected. */ @@ -1914,7 +1914,7 @@ function drupal_add_js($data = NULL, $type = 'module', $scope = 'header', $defer static $javascript = array(); if (isset($data)) { - + // Add jquery.js and drupal.js the first time a Javascript file is added. if (empty($javascript)) { $javascript['header'] = array( @@ -1925,7 +1925,7 @@ function drupal_add_js($data = NULL, $type = 'module', $scope = 'header', $defer 'module' => array(), 'theme' => array(), 'setting' => array(), 'inline' => array(), ); } - + if (isset($scope) && !isset($javascript[$scope])) { $javascript[$scope] = array('core' => array(), 'module' => array(), 'theme' => array(), 'setting' => array(), 'inline' => array()); } @@ -1933,7 +1933,7 @@ function drupal_add_js($data = NULL, $type = 'module', $scope = 'header', $defer if (isset($type) && isset($scope) && !isset($javascript[$scope][$type])) { $javascript[$scope][$type] = array(); } - + switch ($type) { case 'setting': $javascript[$scope][$type][] = $data; @@ -1948,7 +1948,7 @@ function drupal_add_js($data = NULL, $type = 'module', $scope = 'header', $defer } if (isset($scope)) { - + if (isset($javascript[$scope])) { return $javascript[$scope]; } diff --git a/includes/database.mysql-common.inc b/includes/database.mysql-common.inc index 7632f4a12b8efc69a2cd4af60e6f42dc57d43385..0f2c82b43d7f2544260256137a0678378f75b570 100644 --- a/includes/database.mysql-common.inc +++ b/includes/database.mysql-common.inc @@ -514,7 +514,7 @@ function db_change_field(&$ret, $table, $field, $field_new, $spec, $keys_new = a $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)); + $sql .= ', ADD '. implode(', ADD ', _db_create_keys_sql($keys_new)); } $ret[] = update_sql($sql); } diff --git a/includes/database.mysql.inc b/includes/database.mysql.inc index eb63b0b9b14666e7e8063ad79402065b8f40007a..854f737d5d7a23bac5d9737d7327f5a2614903dc 100644 --- a/includes/database.mysql.inc +++ b/includes/database.mysql.inc @@ -74,7 +74,7 @@ function db_connect($url) { // Allow for non-standard MySQL port. if (isset($url['port'])) { - $url['host'] = $url['host'] .':'. $url['port']; + $url['host'] = $url['host'] .':'. $url['port']; } // - TRUE makes mysql_connect() always open a new link, even if diff --git a/includes/database.mysqli.inc b/includes/database.mysqli.inc index ecd30248be4b65e4460f92c776f9dff26cb0a338..9c00b3e9dcee0741f2fa4084ec656e1187dc2f62 100644 --- a/includes/database.mysqli.inc +++ b/includes/database.mysqli.inc @@ -203,16 +203,16 @@ function db_fetch_array($result) { } /** -* Return an individual result field from the previous query. -* -* Only use this function if exactly one field is being selected; otherwise, -* use db_fetch_object() or db_fetch_array(). -* -* @param $result -* A database query result resource, as returned from db_query(). -* @return -* The resulting field or FALSE. -*/ + * Return an individual result field from the previous query. + * + * Only use this function if exactly one field is being selected; otherwise, + * use db_fetch_object() or db_fetch_array(). + * + * @param $result + * A database query result resource, as returned from db_query(). + * @return + * The resulting field or FALSE. + */ function db_result($result) { if ($result && mysqli_num_rows($result) > 0) { // The mysqli_fetch_row function has an optional second parameter $row diff --git a/includes/form.inc b/includes/form.inc index d7a41e4827b07d3b5669e08f279a3e62514d8719..088893b747527277896869b057dff0f29f1881c9 100644 --- a/includes/form.inc +++ b/includes/form.inc @@ -415,7 +415,7 @@ function drupal_process_form($form_id, &$form, &$form_state) { // however, we'll skip this and let the calling function examine // the resulting $form_state bundle itself. if (!$form['#programmed'] && empty($form_state['rebuild']) && empty($form_state['storage'])) { - drupal_redirect_form($form, $form_state['redirect']); + drupal_redirect_form($form, $form_state['redirect']); } } } @@ -1432,7 +1432,7 @@ function theme_fieldset($element) { $element['#attributes']['class'] .= ' collapsible'; if ($element['#collapsed']) { - $element['#attributes']['class'] .= ' collapsed'; + $element['#attributes']['class'] .= ' collapsed'; } } diff --git a/includes/install.mysql.inc b/includes/install.mysql.inc index a6ebca079543b7eaad8509e5b349d44984c0022f..fa3b6d857dca84d5427bb43460bf185bb87b1e22 100644 --- a/includes/install.mysql.inc +++ b/includes/install.mysql.inc @@ -35,7 +35,7 @@ function drupal_test_mysql($url, &$success) { // Allow for non-standard MySQL port. if (isset($url['port'])) { - $url['host'] = $url['host'] .':'. $url['port']; + $url['host'] = $url['host'] .':'. $url['port']; } // Test connecting to the database. diff --git a/includes/language.inc b/includes/language.inc index c36ba7c014f55464f8e5e20b1733fd08025be765..15bb5a3d4e85e86bfe7b8d76b97088e28490b4e6 100644 --- a/includes/language.inc +++ b/includes/language.inc @@ -106,7 +106,7 @@ function language_url_rewrite(&$path, &$options) { if (!isset($options['language'])) { $options['language'] = $language; } - + switch (variable_get('language_negotiation', LANGUAGE_NEGOTIATION_NONE)) { case LANGUAGE_NEGOTIATION_NONE: // No language dependent path allowed in this mode. diff --git a/includes/menu.inc b/includes/menu.inc index 7c19b1d8e6e1ab6e4a7871aece061454d685f28b..f1b375f52a6f355110ed5beb9e1c54af2c0edd6d 100644 --- a/includes/menu.inc +++ b/includes/menu.inc @@ -1792,8 +1792,8 @@ function menu_link_save(&$item) { } /** -* Helper function to clear the page and block caches at most twice per page load. -*/ + * Helper function to clear the page and block caches at most twice per page load. + */ function _menu_clear_page_cache() { static $cache_cleared = 0; @@ -1814,8 +1814,8 @@ function _menu_clear_page_cache() { } /** -* Helper function to update a list of menus with expanded items -*/ + * Helper function to update a list of menus with expanded items + */ function _menu_set_expanded_menus() { $names = array(); $result = db_query("SELECT menu_name FROM {menu_links} WHERE expanded != 0 GROUP BY menu_name"); diff --git a/includes/theme.inc b/includes/theme.inc index 43a33b3dfb831c601d76c8a4eedf14914594f56e..02697358598b07860e59ba47f3852aef54b03eab 100644 --- a/includes/theme.inc +++ b/includes/theme.inc @@ -1627,7 +1627,7 @@ function template_preprocess(&$variables, $hook) { // Tell all templates where they are located. $variables['directory'] = path_to_theme(); - + // Set default variables that depend on the database. $variables['is_admin'] = FALSE; $variables['is_front'] = FALSE; diff --git a/includes/theme.maintenance.inc b/includes/theme.maintenance.inc index 3570ede693252defa073b3d02ce1e1b484035c45..d56a7c89dc638f2bfd71ded393bf78e7c4946147 100644 --- a/includes/theme.maintenance.inc +++ b/includes/theme.maintenance.inc @@ -78,7 +78,7 @@ function _theme_load_offline_registry($theme, $base_theme = NULL, $theme_engine /** * Return a themed list of maintenance tasks to perform. - * + * * @ingroup themeable */ function theme_task_list($items, $active = NULL) { diff --git a/includes/xmlrpc.inc b/includes/xmlrpc.inc index 80d29fc0dcaf9727c0138b114404ac9c70e40da3..2bf8b18177cd70f68b96488757ccedadb47011b8 100644 --- a/includes/xmlrpc.inc +++ b/includes/xmlrpc.inc @@ -7,7 +7,7 @@ Site: http://scripts.incutio.com/xmlrpc/ Manual: http://scripts.incutio.com/xmlrpc/manual.php This version is made available under the GNU GPL License -*/ + */ /** * Recursively turn a data structure into objects with 'data' and 'type' attributes. diff --git a/includes/xmlrpcs.inc b/includes/xmlrpcs.inc index 7874091a21daea3d16fd9f9ba3812aff5e2fafc9..9b455c6397cd9f071f01ed1545bf7603e5ccca1a 100644 --- a/includes/xmlrpcs.inc +++ b/includes/xmlrpcs.inc @@ -55,7 +55,7 @@ function xmlrpc_server($callbacks) { $data = file_get_contents('php://input'); if (!$data) { - die('XML-RPC server accepts POST requests only.'); + die('XML-RPC server accepts POST requests only.'); } $xmlrpc_server->message = xmlrpc_message($data); if (!xmlrpc_message_parse($xmlrpc_server->message)) { diff --git a/modules/aggregator/aggregator.install b/modules/aggregator/aggregator.install index 5dbc4ddc9c1f297b1ca1656ec9ce4c818c3159c5..b49a4c96b6cd8073185b790df28fe49545bc2c14 100644 --- a/modules/aggregator/aggregator.install +++ b/modules/aggregator/aggregator.install @@ -73,7 +73,7 @@ function aggregator_schema() { 'not null' => TRUE, 'default' => 0, 'description' => t('The {aggregator_category}.cid to which the feed is being assigned.'), - ) + ) ), 'primary key' => array('fid', 'cid'), ); diff --git a/modules/aggregator/aggregator.module b/modules/aggregator/aggregator.module index b848b0eb5b0a9cdf4693f325502caf7debaccb26..ba330cd85c807c1aacbdc2e70dd86936787a67d5 100644 --- a/modules/aggregator/aggregator.module +++ b/modules/aggregator/aggregator.module @@ -577,7 +577,7 @@ function aggregator_refresh($feed) { case 302: case 307: // Filter the input data: - if (aggregator_parse_feed($result->data, $feed)) { + if (aggregator_parse_feed($result->data, $feed)) { $modified = empty($result->headers['Last-Modified']) ? 0 : strtotime($result->headers['Last-Modified']); diff --git a/modules/block/block.module b/modules/block/block.module index 002a890a4fe9397043847a160f6c4c97e6bd79b7..354d4528e80c7f3055f89fdc812866c6c8bf24a9 100644 --- a/modules/block/block.module +++ b/modules/block/block.module @@ -39,21 +39,21 @@ define('BLOCK_NO_CACHE', -1); /** -* The block can change depending on the roles the user viewing the page belongs to. -* This is the default setting, used when the block does not specify anything. -*/ + * The block can change depending on the roles the user viewing the page belongs to. + * This is the default setting, used when the block does not specify anything. + */ define('BLOCK_CACHE_PER_ROLE', 0x0001); /** -* The block can change depending on the user viewing the page. -* This setting can be resource-consuming for sites with large number of users, -* and thus should only be used when BLOCK_CACHE_PER_ROLE is not sufficient. -*/ + * The block can change depending on the user viewing the page. + * This setting can be resource-consuming for sites with large number of users, + * and thus should only be used when BLOCK_CACHE_PER_ROLE is not sufficient. + */ define('BLOCK_CACHE_PER_USER', 0x0002); /** -* The block can change depending on the page being viewed. -*/ + * The block can change depending on the page being viewed. + */ define('BLOCK_CACHE_PER_PAGE', 0x0004); /** diff --git a/modules/book/book.admin.inc b/modules/book/book.admin.inc index 22180e4d30be783a5288fbef5f1bb8aa9c13ff50..1fddfec4e6bee36da208016eecacab7c886cd60d 100644 --- a/modules/book/book.admin.inc +++ b/modules/book/book.admin.inc @@ -231,7 +231,7 @@ function theme_book_admin_table($form) { */ function _book_admin_sort_tree(&$tree) { uasort($tree, '_book_admin_compare'); - foreach($tree as $key => $subtree) { + foreach ($tree as $key => $subtree) { if (!empty($tree[$key]['below'])) { _book_admin_sort_tree($tree[$key]['below']); } diff --git a/modules/comment/comment.install b/modules/comment/comment.install index 0549195303ac8b9c5df57b8a433e3bcd279354a3..4cbc31fe5687785033ef34b779c506c3c47cf4ac 100644 --- a/modules/comment/comment.install +++ b/modules/comment/comment.install @@ -159,44 +159,44 @@ function comment_schema() { 'primary key' => array('cid'), ); - $schema['node_comment_statistics'] = array( - 'description' => t('Maintains statistics of node and comments posts to show "new" and "updated" flags.'), - 'fields' => array( - 'nid' => array( - 'type' => 'int', - 'unsigned' => TRUE, - 'not null' => TRUE, - 'default' => 0, - 'description' => t('The {node}.nid for which the statistics are compiled.'), - ), - 'last_comment_timestamp' => array( - 'type' => 'int', - 'not null' => TRUE, - 'default' => 0, - 'description' => t('The Unix timestamp of the last comment that was posted within this node, from {comments}.timestamp.'), - ), - 'last_comment_name' => array( - 'type' => 'varchar', - 'length' => 60, - 'not null' => FALSE, - 'description' => t('The name of the latest author to post a comment on this node, from {comments}.name.'), - ), - 'last_comment_uid' => array( - 'type' => 'int', - 'not null' => TRUE, - 'default' => 0, - 'description' => t('The user ID of the latest author to post a comment on this node, from {comments}.uid.'), - ), - 'comment_count' => array( - 'type' => 'int', - 'unsigned' => TRUE, - 'not null' => TRUE, - 'default' => 0, - 'description' => t('The total number of comments on this node.'), - ), - ), - 'indexes' => array('node_comment_timestamp' => array('last_comment_timestamp')), - 'primary key' => array('nid'), + $schema['node_comment_statistics'] = array( + 'description' => t('Maintains statistics of node and comments posts to show "new" and "updated" flags.'), + 'fields' => array( + 'nid' => array( + 'type' => 'int', + 'unsigned' => TRUE, + 'not null' => TRUE, + 'default' => 0, + 'description' => t('The {node}.nid for which the statistics are compiled.'), + ), + 'last_comment_timestamp' => array( + 'type' => 'int', + 'not null' => TRUE, + 'default' => 0, + 'description' => t('The Unix timestamp of the last comment that was posted within this node, from {comments}.timestamp.'), + ), + 'last_comment_name' => array( + 'type' => 'varchar', + 'length' => 60, + 'not null' => FALSE, + 'description' => t('The name of the latest author to post a comment on this node, from {comments}.name.'), + ), + 'last_comment_uid' => array( + 'type' => 'int', + 'not null' => TRUE, + 'default' => 0, + 'description' => t('The user ID of the latest author to post a comment on this node, from {comments}.uid.'), + ), + 'comment_count' => array( + 'type' => 'int', + 'unsigned' => TRUE, + 'not null' => TRUE, + 'default' => 0, + 'description' => t('The total number of comments on this node.'), + ), + ), + 'indexes' => array('node_comment_timestamp' => array('last_comment_timestamp')), + 'primary key' => array('nid'), ); return $schema; diff --git a/modules/comment/comment.module b/modules/comment/comment.module index 4876fe638aa9d023f8811ee79edc1caa44f1a5e9..08cdfd8ea443c41c2681db9d27db1847c34d0b3c 100644 --- a/modules/comment/comment.module +++ b/modules/comment/comment.module @@ -1050,8 +1050,8 @@ function comment_operations($action = NULL) { } /** -*** misc functions: helpers, privates, history -**/ + * Misc functions: helpers, privates, history + */ /** * Load the entire comment by cid. @@ -1318,7 +1318,7 @@ function comment_form(&$form_state, $edit, $title = NULL) { if (!form_get_errors() && ((variable_get('comment_preview_'. $node->type, COMMENT_PREVIEW_REQUIRED) == COMMENT_PREVIEW_OPTIONAL) || ($op == t('Preview')) || ($op == t('Save')))) { $form['submit'] = array('#type' => 'submit', '#value' => t('Save'), '#weight' => 19); } - + $form['preview'] = array('#type' => 'button', '#value' => t('Preview'), '#weight' => 20); $form['#token'] = 'comment'. $edit['nid'] . (isset($edit['pid']) ? $edit['pid'] : ''); diff --git a/modules/filter/filter.module b/modules/filter/filter.module index 4f4ed8240f7c689582d0008e3a6a4b204d5410b7..d87f715d2fb4bb5084ee6a096076d48d2648c788 100644 --- a/modules/filter/filter.module +++ b/modules/filter/filter.module @@ -274,7 +274,7 @@ function filter_filter_tips($delta, $format, $long = FALSE) { } break; case 2: - return t('Web page addresses and e-mail addresses turn into links automatically.'); + return t('Web page addresses and e-mail addresses turn into links automatically.'); } } diff --git a/modules/forum/forum.module b/modules/forum/forum.module index 46f0a9615902afe449ed89f4f9e7373cc29a1b1d..c7f0e55cd46059ef2bc609433636a3f5bf7ed41a 100644 --- a/modules/forum/forum.module +++ b/modules/forum/forum.module @@ -190,7 +190,7 @@ function forum_nodeapi(&$node, $op, $teaser, $page) { if ($parents = taxonomy_get_parents_all($node->tid)) { $parents = array_reverse($parents); foreach ($parents as $p) { - $breadcrumb[] = l($p->name, 'forum/'.$p->tid); + $breadcrumb[] = l($p->name, 'forum/'. $p->tid); } } drupal_set_breadcrumb($breadcrumb); diff --git a/modules/node/node.admin.inc b/modules/node/node.admin.inc index e441e3e3d04763ea53fab57d27ce5cb321d112ff..db9cebe9b6e113f96dd5d78c90ea591836663e77 100644 --- a/modules/node/node.admin.inc +++ b/modules/node/node.admin.inc @@ -384,7 +384,7 @@ function node_admin_nodes() { '#submit' => array('node_admin_nodes_submit'), ); - $languages = language_list(); + $languages = language_list(); $destination = drupal_get_destination(); $nodes = array(); while ($node = db_fetch_object($result)) { diff --git a/modules/node/node.module b/modules/node/node.module index e2a800bf85c6a725df76c4723c5eb934a170aafb..197cb12d612cd2ba60278d0a4d5f06f3c8912258 100644 --- a/modules/node/node.module +++ b/modules/node/node.module @@ -253,7 +253,7 @@ function node_teaser_js(&$form, &$form_state) { * @param $size * The desired character length of the teaser. If omitted, the default * value will be used. Ignored if the special delimiter is present - * in $body. + * in $body. * @return * The generated teaser. */ @@ -514,7 +514,7 @@ function _node_types_build() { // Types defined by the node module in the database (rather than by a separate // module using hook_node_info) have a module value of 'node'. if ($type_object->module != 'node' && empty($info_array[$type_object->type])) { - $type_object->disabled = TRUE; + $type_object->disabled = TRUE; } if (!isset($_node_types[$type_object->type]) || $type_object->modified) { $_node_types[$type_object->type] = $type_object; diff --git a/modules/node/node.pages.inc b/modules/node/node.pages.inc index 975f3d8f61f7af302630c938a2df3b8154db47bd..71c458cb0b2f5e2205e536970093f244da811c92 100644 --- a/modules/node/node.pages.inc +++ b/modules/node/node.pages.inc @@ -384,10 +384,10 @@ function node_preview($node) { // 'teaser' form item). if (!isset($node->teaser)) { $node->teaser = empty($node->body) ? '' : node_teaser($node->body, $node->format); - // Chop off the teaser from the body if needed. - if (!$node->teaser_include && $node->teaser == substr($node->body, 0, strlen($node->teaser))) { - $node->body = substr($node->body, strlen($node->teaser)); - } + // Chop off the teaser from the body if needed. + if (!$node->teaser_include && $node->teaser == substr($node->body, 0, strlen($node->teaser))) { + $node->body = substr($node->body, strlen($node->teaser)); + } } // Display a preview of the node: diff --git a/modules/openid/openid.module b/modules/openid/openid.module index 98b7951891eed64e4c9fbdc356fe5c371405f883..30718d9c892ea344f5dfc816b6e76bfb74be4613 100644 --- a/modules/openid/openid.module +++ b/modules/openid/openid.module @@ -44,7 +44,7 @@ function openid_help($path, $arg) { 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('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('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; diff --git a/modules/path/path.module b/modules/path/path.module index cbd30f4f0004cd1c0402989f061106b140da8db1..154e6065edf6d062aef6949c029cca37c0293944 100644 --- a/modules/path/path.module +++ b/modules/path/path.module @@ -117,7 +117,7 @@ function path_set_alias($path = NULL, $alias = NULL, $pid = NULL, $language = '' } else { db_query("DELETE FROM {url_alias} WHERE src = '%s'", $path); - } + } } drupal_clear_path_cache(); } diff --git a/modules/poll/poll.module b/modules/poll/poll.module index 586610553cad61e4543673646d4c03ed374bee16..920c1b3cc1878ea94e80eb8582ed77b50c436324 100644 --- a/modules/poll/poll.module +++ b/modules/poll/poll.module @@ -304,7 +304,7 @@ function _poll_choice_form($delta, $value = '', $votes = 0) { '#type' => 'textfield', '#title' => t('Choice @n', array('@n' => ($delta + 1))), '#default_value' => $value, - '#parents' => array('choice', $delta,'chtext'), + '#parents' => array('choice', $delta, 'chtext'), ); if ($admin) { diff --git a/modules/profile/profile.admin.inc b/modules/profile/profile.admin.inc index 4268c01a6a8c8e9ec8ccee7546c823864e140007..488666ed7eb79de35a9fe2904b423d877e576022 100644 --- a/modules/profile/profile.admin.inc +++ b/modules/profile/profile.admin.inc @@ -8,13 +8,13 @@ /** * Form builder to display a listing of all editable profile fields. - * + * * @ingroup forms * @see profile_admin_overview_submit(). */ function profile_admin_overview(&$form_state = NULL) { $result = db_query('SELECT title, name, type, category, fid, weight FROM {profile_fields} ORDER BY category, weight'); - + $form = array(); $categories = array(); while ($field = db_fetch_object($result)) { @@ -30,15 +30,15 @@ function profile_admin_overview(&$form_state = NULL) { $form[$field->fid]['edit'] = array('#value' => l(t('edit'), "admin/user/profile/edit/$field->fid")); $form[$field->fid]['delete'] = array('#value' => l(t('delete'), "admin/user/profile/delete/$field->fid")); } - + // Add the cateogory combo boxes $categories = array_unique($categories); - foreach($form as $fid => $field) { - foreach($categories as $cat => $category) { + foreach ($form as $fid => $field) { + foreach ($categories as $cat => $category) { $form[$fid]['category']['#options'][$category] = $category; } } - + // Display the submit button only when there's more than one field if (count($form) > 1) { $form['submit'] = array('#type' => 'submit', '#value' => t('Save configuration')); @@ -51,7 +51,7 @@ function profile_admin_overview(&$form_state = NULL) { } } $form['#tree'] = TRUE; - + $addnewfields = '<h2>'. t('Add new field') .'</h2>'; $addnewfields .= '<ul>'; foreach (_profile_field_types() as $key => $value) { @@ -65,7 +65,7 @@ function profile_admin_overview(&$form_state = NULL) { /** * Submit hanlder to update changed profile field weights and categories. - * + * * @see profile_admin_overview(). */ function profile_admin_overview_submit($form, &$form_state) { @@ -113,7 +113,7 @@ function theme_profile_admin_overview($form) { $category_field['#attributes']['class'] = 'profile-category profile-category-'. $category_number; $rows[] = array(array('data' => $category, 'colspan' => 7, 'class' => 'category')); $rows[] = array('data' => array(array('data' => '<em>'. t('No fields in this category. If this category remains empty when saved, it will be removed.') .'</em>', 'colspan' => 7)), 'class' => 'category-'. $category_number .'-message category-message category-populated'); - + // Make it dragable only if there is more than one field if (isset($form['submit'])) { drupal_add_tabledrag('profile-fields', 'order', 'sibling', 'profile-weight', 'profile-weight-'. $category_number); @@ -125,7 +125,7 @@ function theme_profile_admin_overview($form) { // Add special drag and drop classes that group fields together. $field['weight']['#attributes']['class'] = 'profile-weight profile-weight-'. $categories[$category]; $field['category']['#attributes']['class'] = 'profile-category profile-category-'. $categories[$category]; - + // Add the row $row = array(); $row[] = drupal_render($field['title']); @@ -143,7 +143,7 @@ function theme_profile_admin_overview($form) { if (empty($rows)) { $rows[] = array(array('data' => t('No fields available.'), 'colspan' => 7)); } - + $header = array(t('Title'), t('Name'), t('Type')); if (isset($form['submit'])) { $header[] = t('Category'); @@ -153,7 +153,7 @@ function theme_profile_admin_overview($form) { $output = theme('table', $header, $rows, array('id' => 'profile-fields')); $output .= drupal_render($form); - + return $output; } diff --git a/modules/profile/profile.js b/modules/profile/profile.js index dadc60a01e29253a495af5d5fbe22ff6c170156b..2d84d27e057a0226186704a88902dd4504880979 100644 --- a/modules/profile/profile.js +++ b/modules/profile/profile.js @@ -46,7 +46,7 @@ Drupal.behaviors.profileDrag = function(context) { if (!categoryField.is('.profile-category-'+ categoryNum)) { categoryField.removeClass('profile-category-' + oldcategoryNum).addClass('profile-category-' + categoryNum); weightField.removeClass('profile-weight-' + oldcategoryNum).addClass('profile-weight-' + categoryNum); - + categoryField.val(categoryField[0].options[categoryNum].value); } } diff --git a/modules/profile/profile.module b/modules/profile/profile.module index 6e6ce260a9c1923ccc1e57add22e45ff6a601db5..290a371aba595832dc33ffd341afb6e87c1edadf 100644 --- a/modules/profile/profile.module +++ b/modules/profile/profile.module @@ -136,9 +136,9 @@ function profile_menu() { function profile_block($op = 'list', $delta = 0, $edit = array()) { if ($op == 'list') { - $blocks[0]['info'] = t('Author information'); - $blocks[0]['cache'] = BLOCK_CACHE_PER_PAGE | BLOCK_CACHE_PER_ROLE; - return $blocks; + $blocks[0]['info'] = t('Author information'); + $blocks[0]['cache'] = BLOCK_CACHE_PER_PAGE | BLOCK_CACHE_PER_ROLE; + return $blocks; } else if ($op == 'configure' && $delta == 0) { // Compile a list of fields to show @@ -189,9 +189,9 @@ function profile_block($op = 'list', $delta = 0, $edit = array()) { } if ($output) { - $block['subject'] = t('About %name', array('%name' => $account->name)); - $block['content'] = $output; - return $block; + $block['subject'] = t('About %name', array('%name' => $account->name)); + $block['content'] = $output; + return $block; } } } @@ -236,7 +236,7 @@ function profile_save_profile(&$edit, &$user, $category, $register = FALSE) { $result = _profile_get_fields($category, $register); while ($field = db_fetch_object($result)) { if (_profile_field_serialize($field->type)) { - $edit[$field->name] = serialize($edit[$field->name]); + $edit[$field->name] = serialize($edit[$field->name]); } db_query("DELETE FROM {profile_values} WHERE fid = %d AND uid = %d", $field->fid, $user->uid); db_query("INSERT INTO {profile_values} (fid, uid, value) VALUES (%d, %d, '%s')", $field->fid, $user->uid, $edit[$field->name]); diff --git a/modules/profile/profile.pages.inc b/modules/profile/profile.pages.inc index cb60b52537c20cd1cef8cafa7803903a7fd6bb3d..ef139234365159f7f248925292c27aeff9906856 100644 --- a/modules/profile/profile.pages.inc +++ b/modules/profile/profile.pages.inc @@ -23,8 +23,8 @@ function profile_browse() { } // Do not allow browsing of private and hidden fields by non-admins. if (!user_access('administer users') && ($field->visibility == PROFILE_PRIVATE || $field->visibility == PROFILE_HIDDEN)) { - drupal_access_denied(); - return; + drupal_access_denied(); + return; } // Compile a list of fields to show. diff --git a/modules/search/search.module b/modules/search/search.module index fafb6b4f1ec94eacf637c847e7e0884ef14a7666..39daf5cfca679f6c20aeaa4b004dabfcb2cd5757 100644 --- a/modules/search/search.module +++ b/modules/search/search.module @@ -1087,7 +1087,7 @@ function template_preprocess_search_theme_form(&$variables) { if ($type == 'hidden' || $type == 'token') { $hidden[] = drupal_render($variables['form'][$key]); } - else { + else { $variables['search'][$key] = drupal_render($variables['form'][$key]); } } diff --git a/modules/system/page.tpl.php b/modules/system/page.tpl.php index 8a110e18a91a2e63228ac4c550d2cc2ac07c6096..4b1cf7228ac151e3b3a6109a6af7facda461ea8e 100644 --- a/modules/system/page.tpl.php +++ b/modules/system/page.tpl.php @@ -32,7 +32,7 @@ * path, whether the user is logged in, and so on. * * Site identity: - * - $front_page: The URL of the front page. Use this instead of $base_path, + * - $front_page: The URL of the front page. Use this instead of $base_path, * when linking to the front page. This includes the language domain or prefix. * - $logo: The path to the logo image, as defined in theme configuration. * - $site_name: The name of the site, empty when display has been disabled diff --git a/modules/system/system.admin.inc b/modules/system/system.admin.inc index 76788004091b4eaf7dac7bb1ad5dff7bf0cab1f8..368056a2b9c3119b2b5627cfe4b64f5c21ca1f10 100644 --- a/modules/system/system.admin.inc +++ b/modules/system/system.admin.inc @@ -1655,7 +1655,7 @@ function system_sql() { $result = db_query("SHOW STATUS"); while ($entry = db_fetch_object($result)) { - $data[$entry->Variable_name] = $entry->Value; + $data[$entry->variable_name] = $entry->value; } $output = '<h2>'. t('Command counters') .'</h2>'; diff --git a/modules/system/system.module b/modules/system/system.module index 4849b74896143915596a67144cda20151d9980f1..0e857043776502b28ea492a8749812c994a163c5 100644 --- a/modules/system/system.module +++ b/modules/system/system.module @@ -136,7 +136,7 @@ function system_elements() { // Inputs $type['submit'] = array('#input' => TRUE, '#name' => 'op', '#button_type' => 'submit', '#executes_submit_callback' => TRUE, '#process' => array('form_expand_ahah')); $type['button'] = array('#input' => TRUE, '#name' => 'op', '#button_type' => 'submit', '#executes_submit_callback' => FALSE, '#process' => array('form_expand_ahah')); - $type['image_button'] = array('#input' => TRUE, '#button_type' => 'submit','#executes_submit_callback' => TRUE, '#process' => array('form_expand_ahah'), '#return_value' => TRUE, '#has_garbage_value' => TRUE, '#src' => NULL); + $type['image_button'] = array('#input' => TRUE, '#button_type' => 'submit', '#executes_submit_callback' => TRUE, '#process' => array('form_expand_ahah'), '#return_value' => TRUE, '#has_garbage_value' => TRUE, '#src' => NULL); $type['textfield'] = array('#input' => TRUE, '#size' => 60, '#maxlength' => 128, '#autocomplete_path' => FALSE, '#process' => array('form_expand_ahah')); $type['password'] = array('#input' => TRUE, '#size' => 60, '#maxlength' => 128, '#process' => array('form_expand_ahah')); $type['password_confirm'] = array('#input' => TRUE, '#process' => array('expand_password_confirm')); @@ -507,7 +507,7 @@ function system_user($type, $edit, &$user, $category = NULL) { * Generate a block with a promotional link to Drupal.org. */ function system_block($op = 'list', $delta = 0, $edit = NULL) { - switch($op) { + switch ($op) { case 'list': $blocks[0] = array( 'info' => t('Powered by Drupal'), @@ -741,7 +741,7 @@ function system_theme_data() { */ function _system_theme_data() { static $themes_info = array(); - + if (empty($theme_info)) { // Find themes $themes = drupal_system_listing('\.info$', 'themes'); @@ -819,7 +819,7 @@ function _system_theme_data() { } } } - + $themes_info = $themes; } @@ -1477,7 +1477,7 @@ function system_send_email_action_validate($form, $form_state) { if (!valid_email_address($form_values['recipient']) && $form_values['recipient'] != '%author') { // We want the literal %author placeholder to be emphasized in the error message. form_set_error('recipient', t('Please enter a valid email address or %author.', array('%author' => '%author'))); - } + } } function system_send_email_action_submit($form, $form_state) { diff --git a/modules/taxonomy/taxonomy.admin.inc b/modules/taxonomy/taxonomy.admin.inc index f893147faf7a559fe42a42ae4291b43fe273f3ee..4da4b1dd9127a4ac25f9433052bde6ef377286a5 100644 --- a/modules/taxonomy/taxonomy.admin.inc +++ b/modules/taxonomy/taxonomy.admin.inc @@ -151,7 +151,7 @@ function taxonomy_form_vocabulary(&$form_state, $edit = array()) { '#type' => 'fieldset', '#title' => t('Settings'), '#collapsible' => TRUE, - ); + ); $form['settings']['tags'] = array('#type' => 'checkbox', '#title' => t('Tags'), '#default_value' => $edit['tags'], diff --git a/modules/taxonomy/taxonomy.install b/modules/taxonomy/taxonomy.install index 1ce9dbf534090a715eeb34185cec9c834d0d8e26..d1e2c249f9b095a345498ff16d39ff7bcbd6fea0 100644 --- a/modules/taxonomy/taxonomy.install +++ b/modules/taxonomy/taxonomy.install @@ -263,7 +263,8 @@ function taxonomy_schema() { ), 'type' => array( 'type' => 'varchar', - 'length' => 32,'not null' => TRUE, + 'length' => 32, + 'not null' => TRUE, 'default' => '', 'description' => t('The {node}.type of the node type for which the vocabulary may be used.'), ), diff --git a/modules/taxonomy/taxonomy.module b/modules/taxonomy/taxonomy.module index 4ff0697268a4e717a5441d1df0a910d9c9fa9897..48187f971798d46734fcfecd0ce076130fd3e1ac 100644 --- a/modules/taxonomy/taxonomy.module +++ b/modules/taxonomy/taxonomy.module @@ -69,7 +69,7 @@ function taxonomy_link($type, $node = NULL) { else { foreach ($term as $free_typed) { $typed_terms = drupal_explode_tags($free_typed); - foreach($typed_terms as $typed_term) { + foreach ($typed_terms as $typed_term) { $links['taxonomy_preview_term_'. $typed_term] = array( 'title' => $typed_term, ); @@ -1110,7 +1110,7 @@ function taxonomy_select_nodes($tids = array(), $operator = 'or', $depth = 0, $p /** * Accepts the result of a pager_query() call, such as that performed by * taxonomy_select_nodes(), and formats each node along with a pager. -*/ + */ function taxonomy_render_nodes($result) { $output = ''; $has_rows = FALSE; @@ -1133,8 +1133,8 @@ function taxonomy_render_nodes($result) { function taxonomy_nodeapi($node, $op, $arg = 0) { switch ($op) { case 'load': - $output['taxonomy'] = taxonomy_node_get_terms($node); - return $output; + $output['taxonomy'] = taxonomy_node_get_terms($node); + return $output; case 'insert': if (!empty($node->taxonomy)) { diff --git a/modules/upload/upload.module b/modules/upload/upload.module index c35776426ea3a35c10a7aa541e23a573cf6a6d20..44380062a95bae60289c56d07a0d9f376111ccb3 100644 --- a/modules/upload/upload.module +++ b/modules/upload/upload.module @@ -579,7 +579,7 @@ function upload_js() { upload_node_form_submit(array(), $form_state); $node->files = upload_load($node); if (!empty($form_state['values']['files'])) { - foreach($form_state['values']['files'] as $fid => $file) { + foreach ($form_state['values']['files'] as $fid => $file) { $node->files[$fid] = $file; } } diff --git a/modules/user/user.module b/modules/user/user.module index 8154c02c07dcdc6c294d7ae960da3ace71c51834..8f65d082b81f3374e95aedb9b60fc7444944065d 100644 --- a/modules/user/user.module +++ b/modules/user/user.module @@ -652,21 +652,21 @@ function user_block($op = 'list', $delta = 0, $edit = array()) { global $user; if ($op == 'list') { - $blocks[0]['info'] = t('User login'); - // Not worth caching. - $blocks[0]['cache'] = BLOCK_NO_CACHE; + $blocks[0]['info'] = t('User login'); + // Not worth caching. + $blocks[0]['cache'] = BLOCK_NO_CACHE; - $blocks[1]['info'] = t('Navigation'); - // Menu blocks can't be cached because each menu item can have - // a custom access callback. menu.inc manages its own caching. - $blocks[1]['cache'] = BLOCK_NO_CACHE; + $blocks[1]['info'] = t('Navigation'); + // Menu blocks can't be cached because each menu item can have + // a custom access callback. menu.inc manages its own caching. + $blocks[1]['cache'] = BLOCK_NO_CACHE; - $blocks[2]['info'] = t('Who\'s new'); + $blocks[2]['info'] = t('Who\'s new'); - // Too dynamic to cache. - $blocks[3]['info'] = t('Who\'s online'); - $blocks[3]['cache'] = BLOCK_NO_CACHE; - return $blocks; + // Too dynamic to cache. + $blocks[3]['info'] = t('Who\'s online'); + $blocks[3]['cache'] = BLOCK_NO_CACHE; + return $blocks; } else if ($op == 'configure' && $delta == 2) { $form['user_block_whois_new_count'] = array( @@ -706,8 +706,8 @@ function user_block($op = 'list', $delta = 0, $edit = array()) { case 1: if ($menu = menu_tree()) { - $block['subject'] = $user->uid ? check_plain($user->name) : t('Navigation'); - $block['content'] = $menu; + $block['subject'] = $user->uid ? check_plain($user->name) : t('Navigation'); + $block['content'] = $menu; } return $block; diff --git a/themes/garland/maintenance-page.tpl.php b/themes/garland/maintenance-page.tpl.php index 6087b354c8b7c2ed9a940c48412b0c53d2fd005e..3621dbeade6f8d3047c1ebcfa899c7f28ef6b6b7 100644 --- a/themes/garland/maintenance-page.tpl.php +++ b/themes/garland/maintenance-page.tpl.php @@ -7,7 +7,7 @@ * This is an override of the default maintenance page. Used for Garland and * Minnelli, this file should not be moved or modified since the installation * and update pages depend on this file. - * + * * This mirrors closely page.tpl.php for Garland in order to share the same * styles. */ diff --git a/update.php b/update.php index 38738dee96e7eab3ae9c0a0fc0be9e9584bd2a95..46ce7d87dd16b40cbcde7b37953332083f568b75 100644 --- a/update.php +++ b/update.php @@ -624,7 +624,7 @@ function update_create_cache_tables() { created int NOT NULL default '0', headers text, PRIMARY KEY (cid), - INDEX expire (expire) + INDEX expire (expire), ) /*!40100 DEFAULT CHARACTER SET UTF8 */ "); $ret[] = update_sql("CREATE TABLE {cache_menu} ( cid varchar(255) NOT NULL default '', @@ -633,7 +633,7 @@ function update_create_cache_tables() { created int NOT NULL default '0', headers text, PRIMARY KEY (cid), - INDEX expire (expire) + INDEX expire (expire), ) /*!40100 DEFAULT CHARACTER SET UTF8 */ "); $ret[] = update_sql("CREATE TABLE {cache_page} ( cid varchar(255) BINARY NOT NULL default '', @@ -642,7 +642,7 @@ function update_create_cache_tables() { created int NOT NULL default '0', headers text, PRIMARY KEY (cid), - INDEX expire (expire) + INDEX expire (expire), ) /*!40100 DEFAULT CHARACTER SET UTF8 */ "); break; case 'pgsql': @@ -652,28 +652,28 @@ function update_create_cache_tables() { expire int NOT NULL default '0', created int NOT NULL default '0', headers text, - PRIMARY KEY (cid) - )"); - $ret[] = update_sql("CREATE TABLE {cache_menu} ( - cid varchar(255) NOT NULL default '', - data bytea, - expire int NOT NULL default '0', - created int NOT NULL default '0', - headers text, - PRIMARY KEY (cid) - )"); - $ret[] = update_sql("CREATE TABLE {cache_page} ( - cid varchar(255) NOT NULL default '', - data bytea, - expire int NOT NULL default '0', - created int NOT NULL default '0', - headers text, - PRIMARY KEY (cid) - )"); - $ret[] = update_sql("CREATE INDEX {cache_filter}_expire_idx ON {cache_filter} (expire)"); - $ret[] = update_sql("CREATE INDEX {cache_menu}_expire_idx ON {cache_menu} (expire)"); - $ret[] = update_sql("CREATE INDEX {cache_page}_expire_idx ON {cache_page} (expire)"); - break; + PRIMARY KEY (cid), + )"); + $ret[] = update_sql("CREATE TABLE {cache_menu} ( + cid varchar(255) NOT NULL default '', + data bytea, + expire int NOT NULL default '0', + created int NOT NULL default '0', + headers text, + PRIMARY KEY (cid), + )"); + $ret[] = update_sql("CREATE TABLE {cache_page} ( + cid varchar(255) NOT NULL default '', + data bytea, + expire int NOT NULL default '0', + created int NOT NULL default '0', + headers text, + PRIMARY KEY (cid), + )"); + $ret[] = update_sql("CREATE INDEX {cache_filter}_expire_idx ON {cache_filter} (expire)"); + $ret[] = update_sql("CREATE INDEX {cache_menu}_expire_idx ON {cache_menu} (expire)"); + $ret[] = update_sql("CREATE INDEX {cache_page}_expire_idx ON {cache_page} (expire)"); + break; } return $ret; }