Projekt

Allgemein

Profil

« Zurück | Weiter » 

Revision 86937e15

Von Moritz Bunkus vor fast 12 Jahren hinzugefügt

  • ID 86937e158181c9683401c23cf55bf015d55b784a
  • Vorgänger 576c2a14
  • Nachfolger 009d4b89

Form::info() auf Templates umgestellt und Auto-Redirect-Target angepasst

Unterschiede anzeigen:

SL/Form.pm
my ($self, $msg) = @_;
if ($ENV{HTTP_USER_AGENT}) {
$msg =~ s/\n/<br>/g;
if (!$self->{header}) {
$self->header;
print qq|<body>|;
}
print qq|
<p class="message_ok"><b>$msg</b></p>
<script type="text/javascript">
<!--
// If JavaScript is enabled, the whole thing will be reloaded.
// The reason is: When one changes his menu setup (HTML / CSS ...)
// it now loads the correct code into the browser instead of do nothing.
setTimeout("top.frames.location.href='login.pl'",500);
//-->
</script>
</body>
|;
$self->header;
print $self->parse_html_template('generic/form_info', { message => $msg });
} elsif ($self->{info_function}) {
&{ $self->{info_function} }($msg);
} else {
if ($self->{info_function}) {
&{ $self->{info_function} }($msg);
} else {
print "$msg\n";
}
print "$msg\n";
}
$main::lxdebug->leave_sub();
templates/webpages/generic/form_info.html
[%- USE P -%]
<div class="message_ok">
<b>[% P.simple_format(message) %]</b>
</div>
<script type="text/javascript">
<!--
// If JavaScript is enabled, the whole thing will be reloaded.
// The reason is: When one changes his menu setup (HTML / CSS ...)
// it now loads the correct code into the browser instead of do nothing.
setTimeout("top.frames.location.href='login.pl?action=company_logo'",500);
-->
</script>

Auch abrufbar als: Unified diff