projects
/
misc
/
kostenrechnung
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
b0b3f03
)
Pull linebreak out of if construct
author
Joey Schulze
<joey@infodrom.org>
Sun, 28 Feb 2010 12:45:54 +0000
(13:45 +0100)
committer
Joey Schulze
<joey@infodrom.org>
Sun, 28 Feb 2010 12:45:54 +0000
(13:45 +0100)
lib/mask.php
patch
|
blob
|
history
diff --git
a/lib/mask.php
b/lib/mask.php
index
588b2a9
..
72d3b67
100644
(file)
--- a/
lib/mask.php
+++ b/
lib/mask.php
@@
-33,10
+33,10
@@
function build_form($name, $fields)
$v[] = 'size="'.(empty($info['size'])?'10':$info['size']).'"';
$v[] = 'type="'.($info['type']=='passwd'?'password':'text').'"';
$ret[] = sprintf('<label for="edit_%s">%s</label><br>', $id, $info['name']);
$v[] = 'size="'.(empty($info['size'])?'10':$info['size']).'"';
$v[] = 'type="'.($info['type']=='passwd'?'password':'text').'"';
$ret[] = sprintf('<label for="edit_%s">%s</label><br>', $id, $info['name']);
- $ret[] = sprintf('<input %s>
<br>
', implode(' ', $v));
+ $ret[] = sprintf('<input %s>', implode(' ', $v));
} elseif ($info['type'] == 'boolean') {
$ret[] = sprintf('<label for="edit_%s">%s</label><br>', $id, $info['name']);
} elseif ($info['type'] == 'boolean') {
$ret[] = sprintf('<label for="edit_%s">%s</label><br>', $id, $info['name']);
- $ret[] = sprintf('<input type="checkbox" id="edit_%s" name="%s">
<br>
', $id, $id);
+ $ret[] = sprintf('<input type="checkbox" id="edit_%s" name="%s">', $id, $id);
} elseif ($info['type'] == 'select') {
$ret[] = sprintf('<label for="edit_%s">%s</label><br>', $id, $info['name']);
$ret[] = sprintf('<select id="edit_%s" name="%s">', $id, $id);
} elseif ($info['type'] == 'select') {
$ret[] = sprintf('<label for="edit_%s">%s</label><br>', $id, $info['name']);
$ret[] = sprintf('<select id="edit_%s" name="%s">', $id, $id);
@@
-44,10
+44,11
@@
function build_form($name, $fields)
else $options = query_db($info['options']);
foreach ($options as $row)
$ret[] = sprintf('<option value="%s">%s</option>', $row['id'], $row['text']);
else $options = query_db($info['options']);
foreach ($options as $row)
$ret[] = sprintf('<option value="%s">%s</option>', $row['id'], $row['text']);
- $ret[] = '</select>
<br>
';
+ $ret[] = '</select>';
} elseif ($info['type'] == 'date') {
error_log('type = date');
}
} elseif ($info['type'] == 'date') {
error_log('type = date');
}
+ $ret[] = '<br>';
}
$ret[] = '<span id="form_status"></span>';
}
$ret[] = '<span id="form_status"></span>';