From 3893e5f4b3a30f39c43ab17179611004b6184689 Mon Sep 17 00:00:00 2001 From: cash Date: Sat, 12 Feb 2011 15:50:11 +0000 Subject: fixed another bug from last night git-svn-id: http://code.elgg.org/elgg/trunk@8159 36083f99-b078-4883-b0ff-0f9b5a30f544 --- views/default/input/access.php | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/views/default/input/access.php b/views/default/input/access.php index ea4654be6..523c0aaf4 100644 --- a/views/default/input/access.php +++ b/views/default/input/access.php @@ -5,24 +5,25 @@ * * @package Elgg * @subpackage Core - - * * @uses $vars['value'] The current value, if any - * @uses $vars['js'] Any Javascript to enter into the input tag + * @uses $vars['options_values'] * @uses $vars['internalname'] The name of the input field - * */ $defaults = array( 'class' => 'elgg-input-access', 'disabled' => FALSE, 'value' => get_default_access(), - 'options' => get_write_access_array(), + 'options_values' => get_write_access_array(), ); $vars = array_merge($defaults, $vars); -if (is_array($vars['options']) && sizeof($vars['options']) > 0) { +if ($vars['value'] == ACCESS_DEFAULT) { + $vars['value'] = get_default_access(); +} + +if (is_array($vars['options_values']) && sizeof($vars['options_values']) > 0) { echo elgg_view('input/dropdown', $vars); } \ No newline at end of file -- cgit v1.2.3