variable size longtext config fields
This commit is contained in:
parent
84fae296e5
commit
94eb1fab88
@ -79,8 +79,8 @@ class SetupBlock extends Block {
|
|||||||
if(!is_null($label)) {
|
if(!is_null($label)) {
|
||||||
$this->body .= "<label for='$name'>$label</label>";
|
$this->body .= "<label for='$name'>$label</label>";
|
||||||
}
|
}
|
||||||
$this->body .= "<textarea rows='5' id='$name' name='_config_$name'>$val</textarea>\n";
|
$rows = max(3, min(10, count(explode("\n", $val))));
|
||||||
$this->body .= "<!--<br><br><br><br>-->\n"; // setup page auto-layout counts <br> tags
|
$this->body .= "<textarea rows='$rows' id='$name' name='_config_$name'>$val</textarea>\n";
|
||||||
$this->body .= "<input type='hidden' name='_type_$name' value='string'>\n";
|
$this->body .= "<input type='hidden' name='_type_$name' value='string'>\n";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user