summaryrefslogtreecommitdiff
path: root/lib/util.php
diff options
context:
space:
mode:
authorEvan Prodromou <evan@controlyourself.ca>2008-10-24 22:28:49 -0400
committerEvan Prodromou <evan@controlyourself.ca>2008-10-24 22:28:49 -0400
commit22057e01bd6fdf366340e6fdbdf6bb1252bceb8c (patch)
treef3480cdbfb956eaa90a3e80de66d21e7080f4a89 /lib/util.php
parentb26477d787481060e274f3a7007eaea2a6042062 (diff)
add SUP link to User RSS
darcs-hash:20081025022849-5ed1f-edd99a830ff285f4d0468e0e9ce3ceba4a885352.gz
Diffstat (limited to 'lib/util.php')
-rw-r--r--lib/util.php16
1 files changed, 11 insertions, 5 deletions
diff --git a/lib/util.php b/lib/util.php
index 924625e02..1bc5b95b0 100644
--- a/lib/util.php
+++ b/lib/util.php
@@ -809,13 +809,17 @@ function common_default_avatar($size) {
return theme_path('default-avatar-'.$sizenames[$size].'.png');
}
-function common_local_url($action, $args=NULL) {
- global $config;
- if ($config['site']['fancy']) {
- return common_fancy_url($action, $args);
+function common_local_url($action, $args=NULL, $fragment=NULL) {
+ $url = NULL;
+ if (common_config('site','fancy')) {
+ $url = common_fancy_url($action, $args);
} else {
- return common_simple_url($action, $args);
+ $url = common_simple_url($action, $args);
+ }
+ if (!is_null($fragment)) {
+ $url .= '#'.$fragment;
}
+ return $url;
}
function common_fancy_url($action, $args=NULL) {
@@ -971,6 +975,8 @@ function common_fancy_url($action, $args=NULL) {
}
default: return common_simple_url($action, $args);
}
+ case 'sup':
+ return common_path('main/sup');
default:
return common_simple_url($action, $args);
}