From d575e1bcb35dc228f3851fbf1f9d4a1de0bdecc4 Mon Sep 17 00:00:00 2001 From: Florian Pritz Date: Fri, 10 May 2013 23:26:13 +0200 Subject: Hide function not supported by auth driver Signed-off-by: Florian Pritz --- application/helpers/filebin_helper.php | 15 +++++++++++++++ application/views/file/upload_form.php | 8 ++++++-- application/views/header.php | 8 ++++++-- 3 files changed, 27 insertions(+), 4 deletions(-) (limited to 'application') diff --git a/application/helpers/filebin_helper.php b/application/helpers/filebin_helper.php index 0951527fe..0063b6526 100644 --- a/application/helpers/filebin_helper.php +++ b/application/helpers/filebin_helper.php @@ -284,4 +284,19 @@ function getNormalizedFILES() return $ret; } +// Allow simple checking inside views +function auth_driver_function_implemented($function) +{ + static $result = array(); + if (isset($result[$function])) { + return $result[$function]; + } + + $CI =& get_instance(); + $CI->load->driver("duser"); + $result[$function] = $CI->duser->is_implemented($function);; + + return $result[$function]; +} + # vim: set noet: diff --git a/application/views/file/upload_form.php b/application/views/file/upload_form.php index 0596fcbaf..be449ee6e 100644 --- a/application/views/file/upload_form.php +++ b/application/views/file/upload_form.php @@ -41,7 +41,9 @@ -

+ +

+
@@ -65,7 +67,9 @@

This website's primary goal is aiding developers, power users, students and alike in solving problems, debugging software, sharing their configuration, etc. It is not intended to distribute confidential or harmful information, scripts or software.

-

If you believe you deserve an account, ask someone who is already using this service to ">invite you.

+ +

If you believe you deserve an account, ask someone who is already using this service to ">invite you.

+

If you experience any problems feel free to contact me.

diff --git a/application/views/header.php b/application/views/header.php index be0cffdab..40bb6e6a3 100644 --- a/application/views/header.php +++ b/application/views/header.php @@ -41,7 +41,9 @@ if (is_cli_client() && !isset($force_full_html)) {
  • "> New
  • "> History
  • -
  • "> Invite
  • + +
  • "> Invite
  • +
    -- cgit v1.2.3-24-g4f1b