1 {% extends
"../base.html" %}
4 {% if mode ==
"paste" %}
6 {% elif mode ==
"upload" %}
12 <div class=
"row justify-content-center">
13 <div class=
"col-12 col-md-8">
14 {% if mode ==
"paste" %}
15 <h1>{{ _(
"New Paste") }}
</h2>
16 {% elif mode ==
"upload" %}
17 <h1>{{ _(
"Upload File") }}
</h3>
20 <form class=
"form-horizontal" action=
"" method=
"POST" enctype=
"multipart/form-data">
21 {% raw xsrf_form_html() %}
23 <input type=
"hidden" name=
"mode" value=
"{{ mode }}">
25 {% if mode ==
"paste" %}
26 <div class=
"form-group">
27 <label>{{ _(
"Subject") }}
</label>
28 <input type=
"text" class=
"form-control" name=
"subject"
29 placeholder=
"{{ _("Subject
") }} ({{ _("optional
") }})">
33 <div class=
"form-group">
34 {% if mode ==
"paste" %}
35 <textarea class=
"form-control" rows=
"12" name=
"content"
36 placeholder=
"{{ _("Please paste your content here...
") }}"></textarea>
37 {% elif mode ==
"upload" %}
38 <label>{{ _(
"File") }}
</label>
39 <input type=
"file" name=
"file" class=
"form-control-file">
42 <small class=
"form-text text-muted">
43 {{ _(
"You may upload up to %s") % format_size(max_size) }}
49 <div class=
"form-group">
50 <label>{{ _(
"Expires") }}
</label>
52 <select class=
"form-control" name=
"expires">
53 <option value=
"0">{{ _(
"never") }}
</option>
54 <option value=
"600">{{ _(
"after ten minutes") }}
</option>
55 <option value=
"3600">{{ _(
"after one hour") }}
</option>
56 <option value=
"{{ 24 * 3600 }}">{{ _(
"after one day") }}
</option>
57 <option value=
"{{ 7 * 24 * 3600 }}">{{ _(
"after one week") }}
</option>
58 <option value=
"{{ 30 * 24 * 3600 }}" selected
>{{ _(
"after one month") }}
</option>
62 <button type=
"submit" class=
"btn btn-primary btn-block">{{ _(
"Submit") }}
</button>