aboutsummaryrefslogtreecommitdiff
path: root/views
diff options
context:
space:
mode:
authormarcus <marcus@36083f99-b078-4883-b0ff-0f9b5a30f544>2008-11-14 18:37:03 +0000
committermarcus <marcus@36083f99-b078-4883-b0ff-0f9b5a30f544>2008-11-14 18:37:03 +0000
commit03aafca5ad78df33d1b9608a27ee4e2b5a7acbe3 (patch)
treeed663ec3f3b7526cf359cebb274eb60a1dfb721e /views
parent1a6f493bffd75c9b779bc76cacbf63973d45c752 (diff)
downloadelgg-03aafca5ad78df33d1b9608a27ee4e2b5a7acbe3.tar.gz
elgg-03aafca5ad78df33d1b9608a27ee4e2b5a7acbe3.tar.bz2
Removed some "Undefined" messages
git-svn-id: https://code.elgg.org/elgg/trunk@2455 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'views')
-rw-r--r--views/default/input/access.php6
-rw-r--r--views/default/input/button.php6
-rw-r--r--views/default/input/submit.php2
3 files changed, 7 insertions, 7 deletions
diff --git a/views/default/input/access.php b/views/default/input/access.php
index dfd23df1d..693a8da4a 100644
--- a/views/default/input/access.php
+++ b/views/default/input/access.php
@@ -17,10 +17,10 @@
*
*/
- $class = $vars['class'];
+ if (isset($vars['class'])) $class = $vars['class'];
if (!$class) $class = "input-access";
- if (!is_array($vars['options']))
+ if ((!isset($vars['options'])) || (!is_array($vars['options'])))
{
$vars['options'] = array();
$vars['options'] = get_write_access_array();
@@ -30,7 +30,7 @@
?>
-<select name="<?php echo $vars['internalname']; ?>" <?php if (isset($vars['js'])) echo $vars['js']; ?> <?php if ($vars['disabled']) echo ' disabled="yes" '; ?> class="<?php echo $class; ?>">
+<select name="<?php echo $vars['internalname']; ?>" <?php if (isset($vars['js'])) echo $vars['js']; ?> <?php if ((isset($vars['disabled'])) && ($vars['disabled'])) echo ' disabled="yes" '; ?> class="<?php echo $class; ?>">
<?php
foreach($vars['options'] as $key => $option) {
diff --git a/views/default/input/button.php b/views/default/input/button.php
index 9a72f38b0..dab488719 100644
--- a/views/default/input/button.php
+++ b/views/default/input/button.php
@@ -21,7 +21,7 @@
global $CONFIG;
- $class = $vars['class'];
+ if (isset($vars['class'])) $class = $vars['class'];
if (!$class) $class = "submit_button";
if (isset($vars['type'])) { $type = strtolower($vars['type']); } else { $type = 'submit'; }
@@ -34,8 +34,8 @@
}
$value = htmlentities($vars['value'], null, 'UTF-8');
- $name = $vars['internalname'];
- $src = $vars['src'];
+ if (isset($vars['internalname'])) $name = $vars['internalname'];
+ if (isset($vars['src'])) $src = $vars['src'];
if (strpos($src,$CONFIG->wwwroot)===false) $src = ""; // blank src if trying to access an offsite image.
?>
<input type="<?php echo $type; ?>" class="<?php echo $type; ?>_button" <?php echo $vars['js']; ?> value="<?php echo $value; ?>" src="<?php echo $src; ?>" class="<?php echo $class; ?>" /> \ No newline at end of file
diff --git a/views/default/input/submit.php b/views/default/input/submit.php
index 591a43998..28a0bc5fd 100644
--- a/views/default/input/submit.php
+++ b/views/default/input/submit.php
@@ -19,7 +19,7 @@
*/
$vars['type'] = 'submit';
- $class = $vars['class'];
+ if (isset($vars['class'])) $class = $vars['class'];
if (!$class) $class = "submit_button";
$vars['class'] = $class;