summaryrefslogtreecommitdiffstats
path: root/templates/textfileform.html
blob: c2f7c117738483c409d22e02e0e781aece722d58 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
{% extends "base.html" %}

{% block title %}Online text file editor{% endblock %}

{% block content %}

<h2>Editing text file</h2>
   <style>
    input, textarea, pre {font-family: monospace; font-weight: bold; text-align:left; font-size: 100%; padding: 0.5em;  }
    textarea {text-align:left }
    pre {text-align:left; font-size: 110%  }
    </style>  
<div style = "max-width:95%; margin-left:4%; font-family: monospace; font-weight: bold; font-size: 110%; text-align: left; " >
File: {{path}} <br>
Full path on server: {{filepath}}
{% if message %}
<p style="color:red">{{message}}</p>
{% endif %}
    
    <form method ='post' >
        {% csrf_token %}              
    <br />
           <textarea {% if not user.username %} disabled{% endif %} 
           rows="{% if textrows%}{{textrows}}{% else %}20{% endif %}" cols="100"
           label = "" name = "text" 
           required />{% if text %}{{text}}{% else %}Placeholder text{% endif %}
           </textarea>
           <br>
           [Edit the text by just typing in the box.]    

<br /><br />
<div>
<label for="id_identified_login">Identified login:</label>
{{form.identified_login}}<br />
<label for="id_who_are_you">Who are you:</label><br />

{{form.who_are_you}}
</div><br />
       
       <button  class="fancybutton2"  style="padding: 0.5em 25px; margin-left: 110px"  name="Save" type = "submit"  
title="Saves the file in UTF-8 characterset" value = "Save" >
          Save the file
       </button>
       <button  class="fancybutton2"  style="padding: 0.5em 25px; margin-left: 110px"  name="Cancel" type = "submit"  
title="Aborts the editing" value = "Cancel" >
          Cancel 
       </button>
    </form>
    <br />

 
</div>

<br />
<hr />





{% endblock %}