Revision c9eb66f6
Added by VinÃcius Coque over 13 years ago
usr/local/www/guiconfig.inc | ||
---|---|---|
294 | 294 |
return 1; |
295 | 295 |
} |
296 | 296 |
|
297 |
function print_info_box_np($msg, $name="apply",$value="Apply changes") {
|
|
297 |
function print_info_box_np($msg, $name="apply",$value="", $showapply=false) {
|
|
298 | 298 |
global $g, $nifty_redbox, $nifty_blackbox, $nifty_background; |
299 | 299 |
|
300 |
if(empty($value)) { |
|
301 |
$value = gettext("Apply changes"); |
|
302 |
} |
|
303 |
|
|
300 | 304 |
// Set the Nifty background color if one is not set already (defaults to white) |
301 | 305 |
if($nifty_background == "") |
302 | 306 |
$nifty_background = "#FFF"; |
303 | 307 |
|
304 |
if(stristr($msg, gettext("apply")) != false || stristr($msg, gettext("save")) != false || stristr($msg, gettext("create")) != false) { |
|
308 |
if(stristr($msg, gettext("apply")) != false || stristr($msg, gettext("save")) != false || stristr($msg, gettext("create")) != false || $showapply) {
|
|
305 | 309 |
$savebutton = "<td class='infoboxsave'>"; |
306 | 310 |
$savebutton .= "<input name=\"{$name}\" type=\"submit\" class=\"formbtn\" id=\"${name}\" value=\"{$value}\">"; |
307 | 311 |
if($_POST['if']) |
Also available in: Unified diff
Fix a logical bug on gettext
The parameter showapply determines when the apply button should be displayed
Ticket #1686