openrat-cms

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs

commit 42e9869330a750c3389d25a9302c6af798c887aa
parent 6affa0ef05cf25cfb8d24fefe6e1f2c4fe8ed816
Author: dankert <devnull@localhost>
Date:   Thu, 19 Mar 2009 01:33:21 +0100

Edit-Mode nicht aus Request-Variable bestimmen.

Diffstat:
themes/default/include/html/checkbox.inc.php | 2+-
themes/default/include/html/form.inc.php | 4++--
themes/default/include/html/input.inc.php | 2+-
themes/default/include/html/inputarea.inc.php | 2+-
themes/default/include/html/radio.inc.php | 2+-
themes/default/include/html/selectbox.inc.php | 2+-
6 files changed, 7 insertions(+), 7 deletions(-)

diff --git a/themes/default/include/html/checkbox.inc.php b/themes/default/include/html/checkbox.inc.php @@ -1,5 +1,5 @@ <?php - if ($this->isEditable() && $this->getRequestVar('mode')!='edit') $attr_readonly=true; + if ($this->isEditable() && !$this->isEditMode()) $attr_readonly=true; if ( isset($$attr_name) ) $checked = $$attr_name; diff --git a/themes/default/include/html/form.inc.php b/themes/default/include/html/form.inc.php @@ -6,7 +6,7 @@ if (empty($attr_id)) $attr_id = $this->getRequestId(); - if ($this->isEditable() && $this->getRequestVar('mode')!='edit') + if ($this->isEditable() && !$this->isEditMode()) $attr_subaction = $subActionName; ?><form name="<?php echo $attr_name ?>" @@ -15,7 +15,7 @@ method="<?php echo $attr_method ?>" enctype="<?php echo $attr_enctype ?>" style="margin:0px;padding:0px;"> -<?php if ($this->isEditable() && $this->getRequestVar('mode')!='edit') { ?> +<?php if ($this->isEditable() && !$this->isEditMode()) { ?> <input type="hidden" name="mode" value="edit" /> <?php } ?> diff --git a/themes/default/include/html/input.inc.php b/themes/default/include/html/input.inc.php @@ -1,4 +1,4 @@ -<?php if ($this->isEditable() && $this->getRequestVar('mode')!='edit') $attr_readonly=true; +<?php if ($this->isEditable() && !$this->isEditMode()) $attr_readonly=true; if ($attr_readonly && empty($$attr_name)) $$attr_name = '- '.lang('EMPTY').' -'; if(!isset($attr_default)) $attr_default=''; diff --git a/themes/default/include/html/inputarea.inc.php b/themes/default/include/html/inputarea.inc.php @@ -1,4 +1,4 @@ -<?php if ($this->isEditable() && $this->getRequestVar('mode')!='edit') $attr_readonly=true; +<?php if ($this->isEditable() && !$this->isEditMode()) $attr_readonly=true; if ( !$attr_readonly) { ?><textarea <?php if ($attr_readonly) echo ' disabled="true"' ?> class="<?php echo $attr_class ?>" name="<?php echo $attr_name ?>" rows="<?php echo $attr_rows ?>" cols="<?php echo $attr_cols ?>"><?php echo htmlentities(isset($$attr_name)?$$attr_name:$attr_default) ?></textarea><?php } else { diff --git a/themes/default/include/html/radio.inc.php b/themes/default/include/html/radio.inc.php @@ -1,5 +1,5 @@ <?php - if ($this->isEditable() && $this->getRequestVar('mode')!='edit') $attr_readonly=true; + if ($this->isEditable() && !$this->isEditMode()) $attr_readonly=true; if ( isset($$attr_name) ) $attr_tmp_default = $$attr_name; diff --git a/themes/default/include/html/selectbox.inc.php b/themes/default/include/html/selectbox.inc.php @@ -1,6 +1,6 @@ <?php $attr_tmp_list = $$attr_list; -if ($this->isEditable() && $this->getRequestVar('mode')!='edit') +if ($this->isEditable() && !$this->isEditMode()) { echo empty($$attr_name)?'- '.lang('EMPTY').' -':$attr_tmp_list[$$attr_name]; }