summaryrefslogtreecommitdiff
path: root/modules/path/path.module
diff options
context:
space:
mode:
authorDries Buytaert <dries@buytaert.net>2003-10-07 18:16:41 +0000
committerDries Buytaert <dries@buytaert.net>2003-10-07 18:16:41 +0000
commit22c889e7c05b1c2dd98ad5e6b3547234a3f6596f (patch)
tree8b63c79053762af3284384a7e8c54a2d3e9b0d45 /modules/path/path.module
parentfbc674f14301fd92f97f2506a72c22b7d51c1c43 (diff)
downloadbrdo-22c889e7c05b1c2dd98ad5e6b3547234a3f6596f.tar.gz
brdo-22c889e7c05b1c2dd98ad5e6b3547234a3f6596f.tar.bz2
- Help system improvements: eliminated the _system hook. Patch by Michael.
- Bloggerapi module fixes. Patch by Kjartan. - Coding style fixes. Patch by Michael.
Diffstat (limited to 'modules/path/path.module')
-rw-r--r--modules/path/path.module28
1 files changed, 12 insertions, 16 deletions
diff --git a/modules/path/path.module b/modules/path/path.module
index 1e4d428f7..7fed2cf71 100644
--- a/modules/path/path.module
+++ b/modules/path/path.module
@@ -1,13 +1,6 @@
<?php
/* $Id$ */
-function path_system($field) {
- $system["description"] = path_help("admin/system/modules");
- $system["admin_help"] = path_help("admin/system/modules/path");
-
- return $system[$field];
-}
-
function path_admin() {
$op = strtolower($_POST["op"]);
$edit = $_POST["edit"];
@@ -111,27 +104,30 @@ function path_form($edit = "", $error = "") {
}
function path_help($section = "admin/path/help") {
+ $output = "";
+
switch ($section) {
- case "admin/system/modules":
- $output = "Enables users to create custom URLs.";
+ case "admin/system/modules#description":
+ $output = t("Enables users to create custom URLs.");
break;
-
case "admin/path":
- $output = "Drupal provides users complete control over URLs through aliasing. While the original Drupal URLs are always created and accessible, advanced users have the option to override these normal paths.";
+ $output = t("Drupal provides users complete control over URLs through aliasing. While the original Drupal URLs are always created and accessible, advanced users have the option to override these normal paths.");
break;
-
case "admin/path/add":
- $output = "Enter the path you wish to create the alias for, followed by the name of the new alias. Each path can be associated with only one alias.";
+ $output = t("Enter the path you wish to create the alias for, followed by the name of the new alias. Each path can be associated with only one alias.");
break;
-
case "admin/path/help":
$output .= "<h3>Background</h3><p>URL aliasing gives users the ability to have control over all Drupal paths. This functionality will integrate seamlessly into node forms and also provide the administrator an interface to view all aliases that have been created.</p><p>Aliases have a 1 to 1 relationship with their original Drupal URLs. In otherwards you cannot have an alias map to more than one path. Likewise, a Drupal URL can't be mapped to more than one alias.</p>";
$output .= "<h3>Permissions</h3><p>Two new permissions are introduced for aliasing URLs: <i>create url aliases</i> and <i>administer url aliases</i>.</p>";
- $output .= "<ol><li><b>create url aliases</b> - Allows users to create aliases for nodes. Enabling this permission will display a new path field to the user in any node form, allowing them to enter an alias for that node. They will be able to edit/delete the alias after it is created using the same form.</li><li><b>administer url aliases</b> - Allows users to access the alias administration interface. They must also have the <i>access administration pages</i> permission set as well. This interface displays all aliases and provides a way to create and modify them as well. This is also the location to build aliases for things other than nodes. For example, you can create an alias for a taxonomy URL or even re-map the admin path (although the original admin path will still be accessible since aliases do not cancel out original paths).</li></ol>";
+ $output .= "<ol>";
+ $output .= "<li><b>create url aliases</b> - Allows users to create aliases for nodes. Enabling this permission will display a new path field to the user in any node form, allowing them to enter an alias for that node. They will be able to edit/delete the alias after it is created using the same form.</li>";
+ $output .= "<li><b>administer url aliases</b> - Allows users to access the alias administration interface. They must also have the <i>access administration pages</i> permission set as well. This interface displays all aliases and provides a way to create and modify them as well. This is also the location to build aliases for things other than nodes. For example, you can create an alias for a taxonomy URL or even re-map the admin path (although the original admin path will still be accessible since aliases do not cancel out original paths).</li>";
+ $output .= "</ol>";
+ $output = t($output);
break;
}
- return t($output);
+ return $output;
}
function path_link($type, $node = NULL) {