From ee43823179ee627ac16ea9da8168e5f1bf9619c0 Mon Sep 17 00:00:00 2001 From: "Jannis M. Hoffmann" Date: Thu, 29 Oct 2020 12:13:04 +0100 Subject: Initial commit; Stable version --- templates/webmail/about.html.ep | 71 ++++++++++++++++++++++++++++++++ templates/webmail/displayheaders.html.ep | 46 +++++++++++++++++++++ templates/webmail/noaction.html.ep | 60 +++++++++++++++++++++++++++ templates/webmail/readmail.html.ep | 52 +++++++++++++++++++++++ templates/webmail/writemail.html.ep | 50 ++++++++++++++++++++++ 5 files changed, 279 insertions(+) create mode 100644 templates/webmail/about.html.ep create mode 100644 templates/webmail/displayheaders.html.ep create mode 100644 templates/webmail/noaction.html.ep create mode 100644 templates/webmail/readmail.html.ep create mode 100644 templates/webmail/writemail.html.ep (limited to 'templates/webmail') diff --git a/templates/webmail/about.html.ep b/templates/webmail/about.html.ep new file mode 100644 index 0000000..c6d1247 --- /dev/null +++ b/templates/webmail/about.html.ep @@ -0,0 +1,71 @@ +%# about template + +% layout 'mainlayout'; + + + + + + + + + + + + + + +
+ About JWebmail <%= $version %> +
+
    +
  • + JWebmail <%= $version %> is a Webmail solution meant to be used with + s/qmail +
  • + +
  • Features: +
      + +
    • multiple language support
    • +
    • session management
    • +
    • search for mails
    • +
    • CGI support but also psgi/plack and fcgi
    • +
    +
  • + +
  • + This is a + GPL + licensed project, created by Oliver 'omnis' Müller + and currently maintained by + Jannis M. Hoffmann +
  • + + +
  • Supported languages: +

    +% foreach (@$languages) { + <%= $_ %> +% } +

    +
  • + +
  • + JWebmail is programmed in Perl, and is + a complete rewrite of oMail-webmail. +
  • + +
+
+ +
diff --git a/templates/webmail/displayheaders.html.ep b/templates/webmail/displayheaders.html.ep new file mode 100644 index 0000000..d823d9e --- /dev/null +++ b/templates/webmail/displayheaders.html.ep @@ -0,0 +1,46 @@ +% layout 'mainlayout'; + + + + + + + + +% if (my $loginmessage = stash 'loginmessage') { + + + +% } + + + + + + + + + + + + + + + + + + +
+ %= include 'headers/_displayfolders'; +
<%= $loginmessage %>
+% if (@$msgs) { + %= include 'headers/_display_headers'; +% } +% else { +

<%= l 'empty_folder' %>

+% } +
\ No newline at end of file diff --git a/templates/webmail/noaction.html.ep b/templates/webmail/noaction.html.ep new file mode 100644 index 0000000..54a8106 --- /dev/null +++ b/templates/webmail/noaction.html.ep @@ -0,0 +1,60 @@ +% layout 'mainlayout'; + + + + + + + + + +% if (my $msg = flash('message') || stash('warning')) { + + +% } + + + + + + +
JWebmail – <%= ucfirst l 'login' %>
+ %= $msg + +
+ +%= javascript begin + if (!document.login1.userid.value) { + document.login1.userid.focus(); + } else { + document.login1.password.focus(); + } +% end diff --git a/templates/webmail/readmail.html.ep b/templates/webmail/readmail.html.ep new file mode 100644 index 0000000..f537d96 --- /dev/null +++ b/templates/webmail/readmail.html.ep @@ -0,0 +1,52 @@ +% layout 'mainlayout'; + +% my $mail_fmt = begin + % my ($category, $value) = @_; +
<%= ucfirst l $category %>
+
<%= ref $value ? join(' ' . l('and') . ' ', map {"$_->{name} <$_->{address}>"} @$value) : $value %>
+% end + +
+ +

Read Mail

+ +
+
<%= uc l 'subject' %>
+
<%= $msg->{subject} %>
+%= $mail_fmt->('from', $msg->{from}); +%= $mail_fmt->('to', $msg->{to}); +%= $mail_fmt->('cc', $msg->{cc}) if !ref $msg->{cc} || @{ $msg->{cc} }; +%= $mail_fmt->('bcc', $msg->{bcc}) if !ref $msg->{bcc} || @{ $msg->{cc} }; +
<%= uc l 'date' %>
+
<%= $msg->{date} %>
+
<%= uc l 'size' %>
+
<%= print_sizes10 $msg->{size} %>
+
<%= uc l 'content-type' %>
+
<%= $msg->{content_type} %>
+
+ +% my $body = $msg->{body}; + +% if ($msg->{content_type} eq 'multipart/alternative') { +% for (reverse @$body) { +
+% my $x = mime_render($_->{type}, $_->{val}); +%== $x; +% last if $x; +
+% } +% } +% elsif (ref $body eq 'HASH') { +% for (%$body) { +
+%== mime_render($_->{type}, $_->{val}); +
+% } +% } +% else { +
+%== mime_render($msg->{content_type}, $body); +
+% } + +
\ No newline at end of file diff --git a/templates/webmail/writemail.html.ep b/templates/webmail/writemail.html.ep new file mode 100644 index 0000000..171542e --- /dev/null +++ b/templates/webmail/writemail.html.ep @@ -0,0 +1,50 @@ +% layout 'mainlayout'; + +
+ +

Write Message

+ +% if (my $msg = stash('warning')) { +

<%= $msg %>

+% } + +
+ + + %= email_field 'to', id => 'mail', multiple => '', required => '' +
+ + + %= text_field 'subject', 'required' => '' +
+ + + %= email_field 'cc', 'multiple' => '' +
+ + + %= email_field 'bcc', 'multiple' => '' +
+ + + %= email_field 'back_to' +
+ + + %= text_area 'body', cols => 80, rows => 24, id => 'txt' +
+ + %= file_field 'attach' +
+ + + + %= csrf_field + +
+ + + +
\ No newline at end of file -- cgit v1.2.3