Commit ee701b33 authored by Dries's avatar Dries
Browse files

- Patch #155986 by Uwe: fixed typos.

parent 5e5a07f5
......@@ -183,7 +183,7 @@ function _batch_process() {
$total = $current_set['total'];
// If the batch set is completed, browse through the remaining sets
// until we find one that acually has operations.
// until we find one that actually has operations.
while (empty($current_set['operations']) && ($current_set['success'] = TRUE) && _batch_next_set()) {
$current_set =& _batch_current_set();
}
......@@ -292,7 +292,7 @@ function _batch_finished() {
}
/**
* Store tha batch data for next request, or clear the table if the batch is finished.
* Store the batch data for next request, or clear the table if the batch is finished.
*/
function _batch_shutdown() {
if ($batch = batch_get()) {
......
......@@ -935,7 +935,7 @@ function format_xml_elements($array) {
* @param $singular
* The string for the singular case. Please make sure it is clear this is
* singular, to ease translation (e.g. use "1 new comment" instead of "1 new").
* Do not use @count in the singluar string.
* Do not use @count in the singular string.
* @param $plural
* The string for the plural case. Please make sure it is clear this is plural,
* to ease translation. Use @count in place of the item count, as in "@count
......@@ -2266,7 +2266,7 @@ function _drupal_bootstrap_full() {
fix_gpc_magic();
// Load all enabled modules
module_load_all();
// Let all modules take action before menu system handles the reqest
// Let all modules take action before menu system handles the request
module_invoke_all('init');
}
......@@ -2494,7 +2494,7 @@ function drupal_render(&$elements) {
}
// Make any final changes to the element before it is rendered. This means
// that the $element or the chilren can be altered or corrected before the
// that the $element or the children can be altered or corrected before the
// element is rendered into the final text.
if (isset($elements['#pre_render'])) {
foreach ($elements['#pre_render'] as $function) {
......@@ -2555,7 +2555,7 @@ function drupal_render(&$elements) {
}
if (isset($content) && $content !== '') {
// Filter the outputed content and make any last changes before the
// Filter the outputted content and make any last changes before the
// content is sent to the browser. The changes are made on $content
// which allows the output'ed text to be filtered.
if (isset($elements['#post_render'])) {
......@@ -3047,14 +3047,14 @@ function drupal_redirect($goto) {
*/
/**
* Get the schema defintion of a table, or the whole database schema.
* Get the schema definition of a table, or the whole database schema.
* The returned schema will include any modifications made by any
* module that implements hook_schema_alter().
*
* @param $name
* The name of the table. If not given, the schema of all tables is returned.
* @param $rebuild
* If true, the schema will be rebuilt instead of retreived from the cache.
* If true, the schema will be rebuilt instead of retrieved from the cache.
*/
function drupal_get_schema($name = NULL, $rebuild = FALSE) {
static $schema = array();
......
......@@ -307,7 +307,7 @@ function db_escape_table($string) {
* more tables and their related keys and indexes. A schema is defined by
* hook_schema(), which usually lives in a modulename.schema file.
*
* By implenting hook_schema() and specifying the tables your module
* By implementing hook_schema() and specifying the tables your module
* declares, you can easily create and drop these tables on all
* supported database engines. You don't have to deal with the
* different SQL dialects for table creation and alteration of the
......@@ -357,7 +357,7 @@ function db_escape_table($string) {
* All parameters apart from 'type' are optional except that type
* 'numeric' columns must specify 'precision' and 'scale'.
*
* - 'primary key': An array of one or more key column specifers (see below)
* - 'primary key': An array of one or more key column specifiers (see below)
* that form the primary key.
* - 'unique key': An associative array of unique keys ('keyname' =>
* specification). Each specification is an array of one or more
......
......@@ -21,7 +21,7 @@
define('FILE_EXISTS_ERROR', 2);
/**
* A files status can be one of two values: temorary or permanent. The status
* A files status can be one of two values: temporary or permanent. The status
* for each file Drupal manages is stored in the {files} tables. If the status
* is temporary Drupal's file garbage collection will delete the file and
* remove it from the files table after a set period of time.
......@@ -262,7 +262,7 @@ function file_copy(&$source, $dest = 0, $replace = FILE_EXISTS_RENAME) {
// Give everyone read access so that FTP'd users or
// non-webserver users can see/read these files,
// and give group write permissions so group memebers
// and give group write permissions so group members
// can alter files uploaded by the webserver.
@chmod($dest, 0664);
}
......@@ -454,7 +454,7 @@ function file_space_used($uid = NULL) {
* Saves a file upload to a new location. The source file is validated as a
* proper upload and handled as such.
*
* The file will be added to the files table as a temporary file. Temorary files
* The file will be added to the files table as a temporary file. Temporary files
* are periodically cleaned. To make the file permanent file call
* file_set_status() to change it's status.
*
......
......@@ -268,7 +268,7 @@ function drupal_retrieve_form($form_id, &$form_state) {
* An associative array containing the structure of the form.
* @param $form_state
* A keyed array containing the current state of the form. This
* includes the current persistant storage data for the form, and
* includes the current persistent storage data for the form, and
* any data passed along by earlier steps when displaying a
* multi-step form. Additional information, like the sanitized $_POST
* data, is also accumulated here.
......@@ -759,7 +759,7 @@ function form_builder($form_id, $form, &$form_state) {
}
// Now that we've processed everything, we can go back to handle the funky
// Internet Explorer button-click scenerio.
// Internet Explorer button-click scenario.
_form_builder_ie_cleanup($form, $form_state);
return $form;
......@@ -902,7 +902,7 @@ function _form_builder_handle_input_element($form_id, &$form, &$form_state) {
/**
* Handle the special Internet Explorer one-button-form hit-enter-
* instead-of-clicking scenerio.
* instead-of-clicking scenario.
*/
function _form_builder_ie_cleanup($form, &$form_state) {
if (!empty($form['#type']) && $form['#type'] == 'form') {
......@@ -1761,7 +1761,7 @@ function form_clean_id($id = NULL) {
* // as well as 'return values' for the current operation (write)
* // The following keys are provided :
* // 'results' (read / write): The array of results gathered so far by
* // the batch processing, for the curent operation to append its own.
* // the batch processing, for the current operation to append its own.
* // 'message' (write): A text message displayed in the progress page.
* // The following keys allow for multi-step operations :
* // 'sandbox' (read / write): An array that can be freely used to
......@@ -1778,7 +1778,7 @@ function form_clean_id($id = NULL) {
* $context['message'] = $node->title;
* }
*
* // More advanced example: mutli-step operation - load all nodes, five by five
* // More advanced example: multi-step operation - load all nodes, five by five
* function my_function_2(&$context) {
* if (empty($context['sandbox'])) {
* $context['sandbox']['progress'] = 0;
......@@ -1810,7 +1810,7 @@ function form_clean_id($id = NULL) {
* $message = t('Finished with an error.');
* }
* drupal_set_message($message);
* // Provinding data for the redirected page is done through $_SESSION.
* // Providing data for the redirected page is done through $_SESSION.
* foreach ($results as $result) {
* $items[] = t('Loaded node %title.', array('%title' => $result));
* }
......@@ -1848,7 +1848,7 @@ function form_clean_id($id = NULL) {
* and possibly save data in $_SESSION for display after final page redirection.
*
* Operations are added as new batch sets. Batch sets are used to ensure
* clean code independency, ensuring that several batches submitted by
* clean code independence, ensuring that several batches submitted by
* different parts of the code (core / contrib modules) can be processed
* correctly while not interfering or having to cope with each other. Each
* batch set gets to specify his own UI messages, operates on it's own set
......@@ -1902,7 +1902,7 @@ function batch_set($batch_definition) {
/**
* Process the batch.
*
* Unless the batch has been markes with 'progressive' = FALSE, the function
* Unless the batch has been marked with 'progressive' = FALSE, the function
* isses a drupal_goto and thus ends page execution.
*
* This function is not needed in form submit handlers; Form API takes care
......@@ -1911,7 +1911,7 @@ function batch_set($batch_definition) {
* @param $redirect
* (optional) Path to redirect to when the batch has finished processing.
* @param $url
* (optional - should ony be used for separate scripts like update.php)
* (optional - should only be used for separate scripts like update.php)
* URL of the batch processing page.
*/
function batch_process($redirect = NULL, $url = NULL) {
......@@ -1957,7 +1957,7 @@ function batch_process($redirect = NULL, $url = NULL) {
}
/**
* Retrive the current batch.
* Retrieve the current batch.
*/
function &batch_get() {
static $batch = array();
......
......@@ -58,7 +58,7 @@ function language_initialize() {
}
/**
* Indetify language from the Accept-language HTTP header we got.
* Identify language from the Accept-language HTTP header we got.
*/
function language_from_browser() {
// Specified by the user via the browser's Accept Language setting
......
......@@ -62,7 +62,7 @@ function locale_languages_overview_form() {
}
/**
* Theme the langauge overview form.
* Theme the language overview form.
*/
function theme_locale_languages_overview_form($form) {
$default = language_default();
......@@ -892,7 +892,7 @@ function locale_translate_delete($lid) {
* @param $enabled
* Optionally TRUE to enable the language when created or FALSE to disable.
* @param $default
* Optionall set this language to be the default.
* Optionally set this language to be the default.
*/
function locale_add_language($langcode, $name = NULL, $native = NULL, $direction = LANGUAGE_LTR, $domain = '', $prefix = '', $enabled = TRUE, $default = FALSE) {
// Default prefix on language code.
......@@ -1266,7 +1266,7 @@ function _locale_import_one_string_db(&$report, $langcode, $source, $translation
$report[0]++;
}
else if ($mode == LOCALE_IMPORT_OVERWRITE) {
// Translation exists, only overvwrite if instructed.
// Translation exists, only overwrite if instructed.
db_query("UPDATE {locales_target} SET translation = '%s', plid = %d, plural = %d WHERE language = '%s' AND lid = %d", $translation, $plid, $plural, $langcode, $lid);
$report[1]++;
}
......@@ -2130,7 +2130,7 @@ function _locale_rebuild_js($langcode = NULL) {
}
}
else {
watchdog('locale', 'An error occured during creation of the JavaScript translation file for the language %language.', array('%language' => t($language->name)));
watchdog('locale', 'An error occurred during creation of the JavaScript translation file for the language %language.', array('%language' => t($language->name)));
}
}
}
......
......@@ -38,7 +38,7 @@
* drupal_mail('example', 'notify', $account->mail, user_preferred_language($account), $params);
* }
* }
*
*
* function example_mail($key, &$message, $params) {
* $language = $message['language'];
* $variables = user_mail_tokens($params['account'], $language);
......@@ -80,11 +80,11 @@
*/
function drupal_mail($module, $key, $to, $language, $params = array(), $from = NULL, $send = TRUE) {
$default_from = variable_get('site_mail', ini_get('sendmail_from'));
// Bundle up the variables into a structured array for altering.
$message = array(
'id' => $module .'_'. $key,
'to' => $to,
'to' => $to,
'from' => isset($from) ? $from : $default_from,
'language' => $language,
'params' => $params,
......@@ -109,14 +109,14 @@ function drupal_mail($module, $key, $to, $language, $params = array(), $from = N
$headers['From'] = $headers['Reply-To'] = $from;
}
$message['headers'] = $headers;
// Build the e-mail (get subject and body, allow additional headers) by
// invoking hook_mail() on this module. We cannot use module_invoke() as
// we need to have $message by reference in hook_mail().
if (function_exists($function = $module .'_mail')) {
$function($key, $message, $params);
}
// Invoke hook_mail_alter() to allow all modules to alter the resulting e-mail.
drupal_alter('mail', $message);
......
......@@ -67,7 +67,7 @@
*
* Everything described so far is stored in the menu_router table. The
* menu_links table holds the visible menu links. By default these are
* derived from the same hook_menu definitons, however you are free to
* derived from the same hook_menu definitions, however you are free to
* add more with menu_link_save().
*/
......@@ -522,7 +522,7 @@ function _menu_link_translate(&$item) {
// TODO: menu_tree_data may set this ahead of time for links to nodes
if (!isset($item['access'])) {
if (!_menu_load_objects($item, $map)) {
// An error occured loading an object
// An error occurred loading an object
$item['access'] = FALSE;
return FALSE;
}
......@@ -651,7 +651,7 @@ function menu_tree_all_data($menu_name = 'navigation', $item = NULL, $show_hidde
/**
* Get the data structure representing a named menu tree, based on the current
* page. The tree order is maintained by storing each parent in an invidual
* page. The tree order is maintained by storing each parent in an individual
* field, see http://drupal.org/node/141866 for more.
*
* @param $menu_name
......
......@@ -797,7 +797,7 @@ function theme_placeholder($text) {
/**
* Generate a themed maintenance page.
*
* Note: this function is not themable.
* Note: this function is not themeable.
*
* @param $content
* The page content to show.
......@@ -838,7 +838,7 @@ function theme_maintenance_page($content, $show_messages = TRUE) {
/**
* Generate a themed installation page.
*
* Note: this function is not themable.
* Note: this function is not themeable.
*
* @param $content
* The page content to show.
......@@ -885,7 +885,7 @@ function theme_install_page($content) {
/**
* Return a themed list of maintenance tasks to perform.
*
* Note: this function is not themable.
* Note: this function is not themeable.
*/
function theme_task_list($items, $active = NULL) {
$done = isset($items[$active]) || $active == NULL;
......
......@@ -9,7 +9,7 @@ function actions_install() {
drupal_install_schema('actions');
variable_set('actions_next_id', 0);
// Do initial sychronization of actions in code and the database.
// Do initial synchronization of actions in code and the database.
// For that we need to run code from actions.module.
drupal_load('module', 'actions');
actions_synchronize(actions_list());
......
......@@ -720,7 +720,7 @@ function actions_forms() {
* HTML form.
*/
function actions_assign($type = NULL) {
// If no type is specificied we default to node actions, since they
// If no type is specified we default to node actions, since they
// are the most common.
if (!isset($type)) {
drupal_goto('admin/build/actions/assign/node');
......
......@@ -299,7 +299,7 @@ function comment_block($op = 'list', $delta = 0) {
*
* @param $number (optional) The maximum number of comments to find.
* @return $comments An array of comment objects each containing a nid,
* subject, cid, and timstamp, or an empty array if there are no recent
* subject, cid, and timestamp, or an empty array if there are no recent
* comments visible to the current user.
*/
function comment_get_recent($number = 10) {
......@@ -1912,7 +1912,7 @@ function theme_comment_post_forbidden($nid) {
}
/**
* Allow themable wrapping of all comments.
* Allow themeable wrapping of all comments.
*/
function theme_comment_wrapper($content) {
return '<div id="comments">'. $content .'</div>';
......
......@@ -384,7 +384,7 @@ function contact_mail_user_submit($form, &$form_state) {
flood_register_event('contact');
watchdog('mail', '%name-from sent %name-to an e-mail.', array('%name-from' => $user->name, '%name-to' => $account->name));
drupal_set_message(t('The message has been sent.'));
// Back to the requested users profile page.
$form_state['redirect'] = "user/$account->uid";
}
......@@ -494,7 +494,7 @@ function contact_mail_page_validate($form, &$form_state) {
*/
function contact_mail_page_submit($form, &$form_state) {
global $language;
$values = $form_state['values'];
// E-mail address of the sender: as the form field is a text field,
......@@ -504,9 +504,9 @@ function contact_mail_page_submit($form, &$form_state) {
// Load category properties and save form values for email composition.
$contact = db_fetch_object(db_query("SELECT * FROM {contact} WHERE cid = %d", $values['cid']));
$values['contact'] = $contact;
// Send the e-mail to the recipients using the site default language.
drupal_mail('contact', 'page_mail', $contact->recipients, language_default(), $values, $from);
drupal_mail('contact', 'page_mail', $contact->recipients, language_default(), $values, $from);
// If the user requests it, send a copy using the current language.
if ($values['copy']) {
......@@ -541,7 +541,7 @@ function contact_mail($key, &$message, $params) {
$message['body'][] = $params['message'];
break;
case 'page_autoreply':
$contact = $params['contact'];
$contact = $params['contact'];
$message['subject'] .= t('[!category] !subject', array('!category' => $contact->category, '!subject' => $params['subject']), $language->language);
$message['body'][] = $contact->reply;
break;
......
......@@ -47,7 +47,7 @@ function help_main() {
<dt>Node</dt><dd>The basic unit of content in Drupal, often referred to as a "post". All content that can be created using the "create content" menu is a node. Keep in mind that comments, blocks, and users are <em>not</em> nodes.</dd>
<dt>Published</dt><dd>A post that is viewable by every visitor of the site, regardless of whether he is logged in (see also "Unpublished").</dd>
<dt>Role</dt><dd>A classification users are placed into for the purpose of setting users\' permissions. A user receives the combined permissions of all roles to which he or she is subscribed.</dd>
<dt>Taxonomy</dt><dd>A categorization system that allows the building of complex hierarchial or relational structures and tagging of content (see <a href="@taxonomy">taxonomy help</a>).</dd>
<dt>Taxonomy</dt><dd>A categorization system that allows the building of complex hierarchical or relational structures and tagging of content (see <a href="@taxonomy">taxonomy help</a>).</dd>
<dt>Unpublished</dt><dd>A post that is only viewable by administrators and moderators.</dd>
<dt>User</dt><dd>A person who has an account at your Drupal site, and is currently logged in with that account.</dd>
<dt>Visitor</dt><dd>A person who does not have an account at your Drupal site or a person who has an account at your Drupal site but is <em>not</em> currently logged in with that account. A visitor is also called an "anonymous user".</dd>
......
......@@ -210,7 +210,7 @@ function locale_user($type, $edit, &$user, $category = NULL) {
'#title' => t('Language settings'),
'#weight' => 1,
);
$form['locale']['language'] = array(
'#type' => 'radios',
'#title' => t('Language'),
......
......@@ -32,7 +32,7 @@ function locale_schema() {
$schema['locales_source'] = array(
'fields' => array(
// Unique indentifier of this string.
// Unique identifier of this string.
'lid' => array('type' => 'serial', 'not null' => TRUE),
// Drupal path in case of online discovered translations or file path in case of imported strings.
'location' => array('type' => 'varchar', 'length' => 255, 'not null' => TRUE, 'default' => ''),
......
......@@ -403,7 +403,7 @@ function menu_edit_menu(&$form_state, $type, $menu_name = '') {
$form['menu_name'] = array(
'#type' => 'textfield',
'#title' => t('Menu name'),
'#description' => t('The machine-readable name of this menu. This text will be used for constructing the URL of the <em>menu overwrite</em> page for this menu. This name may consist of only of lowercase letters, numbers and hypens and must be unique.'),
'#description' => t('The machine-readable name of this menu. This text will be used for constructing the URL of the <em>menu overwrite</em> page for this menu. This name may consist of only of lowercase letters, numbers and hyphens and must be unique.'),
'#required' => TRUE,
);
$form['#insert'] = TRUE;
......@@ -431,7 +431,7 @@ function menu_edit_menu(&$form_state, $type, $menu_name = '') {
function menu_edit_menu_validate($form, &$form_state) {
$item = $form_state['values'];
if (preg_match('/[^a-z0-9-]/', $item['menu_name'])) {
form_set_error('menu_name', t('Menu name may consist of only of lowercase letters, numbers and hypens.'));
form_set_error('menu_name', t('Menu name may consist of only of lowercase letters, numbers and hyphens.'));
}
if ($form['#insert'] &&
(db_result(db_query("SELECT menu_name FROM {menu_custom} WHERE menu_name = '%s'", $item['menu_name'])) ||
......
......@@ -214,7 +214,7 @@ function node_teaser_js(&$form, &$form_state) {
* The format of the content. If the content contains PHP code, we do not
* split it up to prevent parse errors.
* @param $size
* The desired character length of the teaser. If omitted, the default
* The desired character length of the teaser. If omitted, the default
* value will be used.
* @return
* The generated teaser.
......@@ -1899,7 +1899,7 @@ function node_revision_delete($nid, $revision) {
}
/**
* Post revision deletion opertations.
* Post revision deletion operations.
*/
function node_revision_delete_post($node, $revision) {
......
......@@ -86,7 +86,7 @@ function _openid_is_xri($identifier) {
}
/**
* Normalize the given identifer as per spec.
* Normalize the given identifier as per spec.
*/
function _openid_normalize($identifier) {
if (_openid_is_xri($identifier)) {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment