View | Details | Raw Unified | Return to bug 30287
Collapse All | Expand All

(-)a/Koha/Notice/Message.pm (+29 lines)
Lines 32-37 Koha::Notice::Message - Koha notice message Object class, related to the message Link Here
32
32
33
=cut
33
=cut
34
34
35
=head3 html_content
36
37
=cut
38
39
sub html_content {
40
    my ($self) = @_;
41
42
    my $title = $self->subject;
43
    my $content = $self->content;
44
    my $css = C4::Context->preference("NoticeCSS") || '';
45
    $css = qq{<link rel="stylesheet" type="text/css" href="$css">} if $css;
46
47
    return <<EOS;
48
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
49
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
50
<html lang="en" xml:lang="en" xmlns="http://www.w3.org/1999/xhtml">
51
<head>
52
<title>$title</title>
53
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
54
$css
55
</head>
56
<body>
57
$content
58
</body>
59
</html>
60
EOS
61
62
}
63
35
=head3 type
64
=head3 type
36
65
37
=cut
66
=cut
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/members/notices.tt (-2 / +1 lines)
Lines 67-73 Link Here
67
                                            <td>
67
                                            <td>
68
                                                <a class="notice-title" data-noticeid="[% QUEUED_MESSAGE.message_id | html %]" href="/cgi-bin/koha/members/notices.pl?borrowernumber=[% borrowernumber | uri %]&amp;noticeid=[% QUEUED_MESSAGE.message_id | uri %]">[% QUEUED_MESSAGE.subject | html %]</a>
68
                                                <a class="notice-title" data-noticeid="[% QUEUED_MESSAGE.message_id | html %]" href="/cgi-bin/koha/members/notices.pl?borrowernumber=[% borrowernumber | uri %]&amp;noticeid=[% QUEUED_MESSAGE.message_id | uri %]">[% QUEUED_MESSAGE.subject | html %]</a>
69
                                                [% IF QUEUED_MESSAGE.content_type.search('html') %]
69
                                                [% IF QUEUED_MESSAGE.content_type.search('html') %]
70
                                                <iframe class="notice" id="notice[% QUEUED_MESSAGE.message_id | html %]" srcdoc="[% QUEUED_MESSAGE.content | html %]"></iframe>
70
                                                <iframe class="notice" id="notice[% QUEUED_MESSAGE.message_id | html %]" srcdoc="[% QUEUED_MESSAGE.html_content | html %]"></iframe>
71
                                                [% ELSE %]
71
                                                [% ELSE %]
72
                                                <iframe class="notice" id="notice[% QUEUED_MESSAGE.message_id | html %]" srcdoc="[% QUEUED_MESSAGE.content | html | html_line_break %]"></iframe>
72
                                                <iframe class="notice" id="notice[% QUEUED_MESSAGE.message_id | html %]" srcdoc="[% QUEUED_MESSAGE.content | html | html_line_break %]"></iframe>
73
                                                [% END %]
73
                                                [% END %]
74
- 

Return to bug 30287