aboutsummaryrefslogtreecommitdiff
path: root/cgi/templates/txt_board.html
blob: 2e87819b9cd7bb5dc9cb2e00413ee0579ee46ab5 (plain) (blame)
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
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
<?py include('templates/txt_base_top.html') ?>
<body class="mainpage" data-brd="#{board}">
<div id="main_nav"><a href="/home.html">Bienvenido a Internet</a> | <?py include('templates/navbar.html') ?></div>
<?py if banner_url: ?>
  <img id="banner" src="#{banner_url}" width="#{banner_width}" height="#{banner_height}" />
<?py #endif ?>
<div id="titlebox" class="outerbox">
  <div class="innerbox">
    <div class="threadnav"><a href="#menu" title="Ir a lista de hilos">&#9632;</a><a href="#1" title="Ir a primer hilo">&#9660;</a></div>
    <h1>#{board_long}</h1>
    <?py if postarea_desc: ?>
    <div id="rules">#{postarea_desc}</div>
    <?py #endif ?>
    <form method="get" action="/tools/search.py" id="search"><input type="text" name="q" value="" /><input type="hidden" name="board" value="#{board}" /><input type="submit" value="Buscar en mensajes activos" /><input type="submit" value="Buscar en archivo" formaction="/tools/search_kako.py" /></form>
  </div>
  <div class="innerbox" id="bailinks"><b>¿Eres nuevo?</b> <a href="/guia.html"><b>C&oacute;mo postear</b></a> | <a href="/faq.html"><b>Preguntas frecuentes</b></a> | <a href="/bai/"><b>Contacto</b></a> | <a href="/userconf.html"><b>Configurar</b></a></div>
</div>
<?py if postarea_extra: ?>
<div class="outerbox"><div class="innerbox">#{postarea_extra}</div></div>
<?py #endif ?>
<a name="menu"></a>
<?py if threads: ?>
<div id="threadbox" class="outerbox"><div class="innerbox">
  <div id="threadlinks">
    <a href="#{cgi_url}threadlist/#{board}"><b>Ver lista de hilos</b></a>
    <a href="kako/"><b>Hilos archivados</b></a>
    <a href="#newthread"><b>Crear nuevo hilo</b></a>
  </div>
  <div id="threadlist">
  <?py iter = 1 ?>
  <?py for thread in threads: ?>
    <a href="##{iter}">#{iter}: <b>#{thread["subject"]}</b> (#{thread['length']})</a>
    <?py iter += 1 ?>
  <?py #endfor ?>
  <?py for thread in more_threads: ?>
    <a href="#{boards_url}#{board}/read/#{thread['timestamp']}/#{'l50' if thread['length'] > 50 else ''}">#{iter}: <b>#{thread["subject"]}</b> (#{thread["length"]})</a>
    <?py iter += 1 ?>
  <?py #endfor ?>
  </div>
</div></div>
<?py titer = 1 ?>
<?py for thread in threads: ?>
<a name="#{titer}"></a>
<div class="thread">
<div class="innerbox">
<div class="threadnav"><a href="#menu" title="Lista de hilos">&#9632;</a><a href="##{(titer-1) if titer>1 else len(threads)}" title="Hilo anterior">&#9650;</a><a href="##{(titer+1) if titer<len(threads) else '1'}" title="Hilo siguiente">&#9660;</a></div>
<h2><span>[#{titer}:#{thread['length']}]</span><a href="#{boards_url}#{board}/read/#{thread['timestamp']}/#{'l50' if thread['length'] > 50 else ''}">#{thread['posts'][0]['subject']}</a></h2>
<div class="replies">
<?py for post in thread['posts']: ?>
<?py if post['IS_DELETED'] == 1: ?>
  <div class="reply deleted" id="p#{post['id']}" data-n="#{post['num']}"><h4>#{post['num']} : Mensaje eliminado por usuario.</h4></div>
<?py elif post['IS_DELETED'] == 2: ?>
  <div class="reply deleted" id="p#{post['id']}" data-n="#{post['num']}"><h4>#{post['num']} : Mensaje eliminado por staff.</h4></div>
<?py else: ?>
  <div class="reply#{' first' if post['num'] == 1 else ''}" id="p#{post['id']}" data-n="#{post['num']}">
  <h4>#{post['num']} :
    <?py if post['email']: ?>
      <?py if post['tripcode']: ?>
        <a class="email" href="mailto:#{post['email']}"><span class="name">#{post['name']}</span> <span class="trip">#{post['tripcode']}</span></a>
      <?py else: ?>
        <a class="email" href="mailto:#{post['email']}"><span class="name">#{post['name']}</span></a>
      <?py #endif ?>
    <?py else: ?>
      <?py if post['tripcode']: ?>
        <span class="name">#{post['name']}</span> <span class="trip">#{post['tripcode']}</span>
      <?py else: ?>
        <span class="name">#{post['name']}</span>
      <?py #endif ?>
    <?py #endif ?>
    : <span class="date" data-unix="#{post['timestamp']}">#{post['timestamp_formatted']}</span>
    <?py if post['posterid']: ?>
      <span class="hash">ID:#{post['posterid']}</span>
    <?py #endif ?>
  </h4>
  <?py if post['file']: ?>
    <a href="/#{board}/src/#{post['file']}" target="_blank" class="thumb">
      <img src="#{'/static/' if post['thumb'].startswith('mime') else  ('/'+board+'/thumb/')}#{post['thumb']}" width="#{post['thumb_width']}" height="#{post['thumb_height']}" title="${post['file']}-(${post['file_size']} B)" />
    </a>
  <?py #endif ?>
  <div class="msg">#{post['message']}
    <?py if post['shortened']: ?>
      <div class="abbrev">(Post muy largo... Presiona <a href="#{boards_url}#{board}/read/#{thread['timestamp']}/#{post['num']}">aquí</a> para verlo completo.)</div>
    <?py #endif ?>
  </div>
</div>
<?py #endif ?>
<?py #endfor ?>
</div>
<?py if thread['locked'] != 1: ?>
<form id="postform#{thread['id']}" class="postform" action="#{cgi_url}post" method="post" enctype="multipart/form-data">
  <input type="hidden" name="board" value="#{board}" /><input type="hidden" name="parent" value="#{thread['id']}" /><input type="hidden" name="password" value="" />
  <div style="display:none">No tocar: <input type="text" name="name" /><input type="text" name="email" /></div>
  <input type="submit" value="Responder" /> <input type="button" name="preview" value="Previsualizar" /> <span><span>Nombre:&nbsp;</span><input type="text" name="fielda" size="13" /><span>&nbsp;E-mail:&nbsp;</span><input type="text" name="fieldb" size="13" /></span>
  <div class="formpad">
    <div id="preview#{thread['id']}" class="msg" style="display:none"></div>
    <textarea name="message" cols="70" rows="6"></textarea>
    <?py if allow_image_replies: ?><input type="file" name="file" /><?py #endif ?>
<?py else: ?>
<form class="postform"><div class="locked"><b>El hilo ha sido cerrado. Ya no se puede postear en él.</b></div><div class="formpad">
<?py #endif ?>
  <div class="threadlinks">
    <a href="#{boards_url}#{board}/read/#{thread['timestamp']}/"><b>Hilo completo</b></a>
    <?py if thread['length'] > 51: ?>
      <a href="#{boards_url}#{board}/read/#{thread['timestamp']}/l50"><b>&Uacute;ltimos 50</b></a>
    <?py #endif ?>
    <?py if thread['length'] > 101: ?>
      <a href="#{boards_url}#{board}/read/#{thread['timestamp']}/-100"><b>Primeros 100</b></a>
    <?py #endif ?>
    <a href="#menu"><b>Lista de hilos</b></a>
    <a href="#newthread"><b>Nuevo hilo</b></a>
  </div>
</div>
</form>
</div>
</div>
<?py titer += 1 ?>
<?py #endfor ?>
<?py #endif ?>
<a name="newthread"></a>
<div id="createbox" class="outerbox">
  <div class="extrabox"></div>
  <div class="innerbox">
    <div class="threadnav"><a href="#menu" title="Lista de hilos">&#9632;</a></div>
    <h5>Formulario de nuevo hilo</h5>
    <form id="postform0" action="#{cgi_url}post" method="post" enctype="multipart/form-data">
      <input type="hidden" name="board" value="#{board}" /><input type="hidden" name="password" value="" />
      <table style="max-width:700px">
        <tr>
          <td class="pblock">Asunto:</td>
          <td colspan="3" style="width:100%"><input type="text" name="subject" size="50" maxlength="100" /></td>
          <td><input type="submit" value="Crear nuevo hilo" accesskey="z" /></td>
        </tr>
        <tr>
          <td class="pblock">Nombre:</td>
          <td><input type="text" name="fielda" accesskey="n" /></td>
          <td class="pblock">E-mail:</td>
          <td><input type="text" name="fieldb" accesskey="e" /></td>
          <td><input type="button" name="preview" value="Previsualizar" accesskey="p" /></td>
        </tr>
        <tr id="tr_preview" style="display:none">
          <td></td>
          <td colspan="4"><div id="preview0" class="msg"></div></td>
        </tr>
        <tr>
          <td class="pblock">Mensaje:</td>
          <td colspan="4"><textarea name="message" cols="90" rows="12" accesskey="m"></textarea></td>
        </tr>
        <?py if allow_images: ?>
        <tr>
          <td class="pblock">Archivo:</td>
          <td colspan="4"><input type="file" name="file" accesskey="i" /></td>
        </tr>
        <?py #endif ?>
      </table>
      <div style="display:none">No tocar: <input type="text" name="name" /><input type="text" name="email" /></div>
    </form>
  </div>
</div>
<center id="footer">
  <a href="/" target="_top">Bienvenido a Internet BBS/IB</a> weabot.py3 <?py include('templates/revision.html') ?> + bjoern + tenjin
  <br />
  No se ponga sensible, baisano...
</center>
</body>
</html>