[go: up one dir, main page]

Menu

[r3]: / index.php  Maximize  Restore  History

Download this file

251 lines (240 with data), 10.4 kB

  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
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
<!--
########################################################################################
# Linha do Texto is a web application for exploring meaning inside textual categories. #
# Copyright (C) 2010 Ana Cristina Fricke Matte #
# #
# This program is free software; you can redistribute it and/or #
# modify it under the terms of the GNU General Public License #
# as published by the Free Software Foundation; either version 2 #
# of the License, or (at your option) any later version. #
# #
# This program is distributed in the hope that it will be useful, #
# but WITHOUT ANY WARRANTY; without even the implied warranty of #
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the #
# GNU General Public License for more details. #
# #
# You should have received a copy of the GNU General Public License #
# along with this program; if not, write to the Free Software #
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. #
########################################################################################
-->
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<!-- <meta http-equiv="refresh" content="10;url="http://www.semiofon.org"> -->
<!-- DW6 -->
<head>
<title>Linha do Texto from Texto Livre.org</title>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<link rel="stylesheet" href="mm_health_nutr.css" type="text/css" />
<script language="JavaScript" src="data.js" type="text/javascript"></script>
<style type="text/css">
<!
.style3 {
color: #FFFFFF;
font-weight: bold;
}
.style4 {font-size: 12px}
.style5 {font-size: 11px}
.style6 {color: #5C743D}
.styleBorderRed {
border-width: medium;
border-style: solid;
border-color: #e70000;
}
.styleBorderBlue {
border-width: medium;
border-style: solid;
border-color: #006ce7;
}
.style10 {
color: #e70000;
font-weight: bold;
}
.style11 {
color: #e76502;
font-weight: bold;
}
.style12 {
color: #e5b402;
font-weight: bold;
}
.style13 {
color: #cce704;
font-weight: bold;
}
.style14 {
color: #88e702;
font-weight: bold;
}
.style15 {
color: #02e743;
font-weight: bold;
}
.style16 {
color: #00e7a2;
font-weight: bold;
}
.style17 {
color: #00d0e7;
font-weight: bold;
}
.style18 {
color: #006ce7;
font-weight: bold;
}
>
<?php
include "funcoes.php";
include "config.php";
include "value.php";
?>
</style>
</head>
<body bgcolor="#F4FFE4">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr bgcolor="#D5EDB3">
<td colspan="4" rowspan="2" bgcolor="#BBDD99"><div align="center"><img src="textolivre.png" alt="Texto Livre.org" width="200" /></div></td>
<td colspan="5" height="50" align="center" valign="bottom" nowrap="nowrap" bgcolor="#E8F5D6" id="logo"><form method="post" action= "index.php">Id do jogo: <input type="text" name="id_jogo" size="10" value="2"><input type="submit" name="escolhe" value=" Escolhe "></form><br />
</td>
</tr>
<tr bgcolor="#D5EDB3">
<td colspan="5" height="26" align="center" valign="top" bgcolor="#D5EDB3" id="tagline"><a href=http://sourceforge.net/projects/linhadotexto>LINHA DO TEXTO</a> Atualize a página para ver o resultado do seu voto!</td>
</tr>
<tr>
<td colspan="9" bgcolor="#5C743D"><img src="mm_spacer.gif" alt="" width="1" height="2" border="0" /></td>
</tr>
<tr>
<td colspan="9" bgcolor="#99CC66" ><img src="mm_dashed_line.gif" alt="line decor" width="4" height="3" border="0" /></td>
</tr>
<tr bgcolor="#99CC66">
<td colspan="4" id="dateformat" height="20">&nbsp;&nbsp;
<script language="JavaScript" type="text/javascript">
document.write(TODAY); </script></td>
<td colspan="1" id="orientacao" height="20"><span class="subHeader"><a href="orientacoes.php" title="Orientações"> Orientações &nbsp;&nbsp;</span></a> </td>
<td colspan="1" id="criar" height="20"><span class="subHeader"><a href="crialinhadotexto.php" title="Criar"> Criar </span></a> </td>
<td colspan="1" id="editar" height="20"><span class="subHeader"><a href="editalinhadotexto.php" title="Editar"> Editar </span></a> </td>
<td colspan="1" id="ListaJogos" height="20"><span class="subHeader"><a href="listajogos.php" title="ListaJogosIds"> Listar Jogos e IDs </span></a> </td>
</tr>
<tr>
<td colspan="9" bgcolor="#99CC66" ><img src="mm_dashed_line.gif" alt="line decor" width="4" height="3" border="0" /></td>
</tr>
<tr>
<td colspan="9" bgcolor="#5C743D"><img src="mm_spacer.gif" alt="" width="1" height="2" border="0" /></td>
</tr>
</table>
<table align="center" widht="100%" border="0" cellspacing="0" cellpadding="15" >
<tr bgcolor="#D5EDB3" >
<?
$escolhe = $_POST["escolhe"];
if ((!empty($escolhe))and($escolhe!=""))
{
$id_jogo = $_POST["id_jogo"];
mysql_abrir_sessao();
$sql = mysql_query("SELECT `jogo` FROM `jogo` WHERE `id_jogo` = '$id_jogo'");
$resultado = mysql_result($sql,0,0);
if ($resultado)
{
// $jogo = mysql_fetch_object ($sql);
// $jogar = "{$jogo->jogo}";
echo "<h2><center>Jogo: $resultado ($id_jogo)</center></h2>";
mysql_abrir_sessao();
$a = (($id_jogo-1) * 4) +1;
$b = $a + 4;
$i = 0;
echo "<td colspan=\"5\" class=\"styleBorderRed\">";
echo "Parâmetros A:";
for (($a=$a);($a<$b);($a++))
{
$sql = "SELECT `parametroa` FROM `parametro` WHERE `id_parametro` = '$a'";
$resultado = mysql_query($sql);
if ($resultado) {
$dado = mysql_fetch_object($resultado);
echo "{$dado->parametroa} <br />";
}
}
echo "</td>";
echo "<td colspan=\"1\" class=\"style10\"><center>WWWWW</center></td><td colspan=\"1\" class=\"style11\"><center>WWWW</center></td><td colspan=\"1\" class=\"style12\"><center>WWW</center></td> <td colspan=\"1\" class=\"style13\"><center>WW</center></td><td colspan=\"1\" class=\"style14\"><center>W</center></td> <td colspan=\"1\" class=\"style15\"><center>WW</center></td><td colspan=\"1\" class=\"style16\"><center>WWW</center></td><td colspan=\"1\" class=\"style17\"><center>WWWW</center></td><td colspan=\"1\" class=\"style18\"><center>WWWWW</center></td><td colspan=\"5\" class=\"styleBorderBlue\">Parâmetros B:<br />";
// mysql_abrir_sessao();
$a = (($id_jogo-1) * 4) +1;
$b = $a + 4;
$i = 0;
for (($a=$a);($a<$b);($a++))
{
$sql = "SELECT `parametrob` FROM `parametro` WHERE `id_parametro` = '$a'";
$resultado = mysql_query($sql);
if ($resultado) {
$dado = mysql_fetch_object($resultado);
echo "{$dado->parametrob} <br />";
} else {
echo "<p>Erro na SQL: {$sql}</p>";
}
}
echo "</td> </tr>";
$a = (($id_jogo-1) * 9) +1;
$b = $a + 9;
$i = 1;
for (($a=$a);($a<$b);($a++))
{
$sql = "SELECT `titulo` FROM `texto` WHERE `id_texto` = '$a'";
$resulta = mysql_query($sql);
$consulta = mysql_result($resulta,0,0);
if ($consulta){
$mediaVoto = "SELECT AVG (voto) FROM `voto` WHERE `id_texto` = $a";
$resultaVoto = mysql_query($mediaVoto);
$votos = mysql_result($resultaVoto,0,0);
$coeficiente = ($votos*550);
$posicao = ($coeficiente/9);
$posicao = $posicao."px";
echo "<tr><td colspan=\"19\" height=\"30\"><div id=\"$consulta\" style=\"position:relative;left:$posicao\">";
echo "<form title=\"Votar\" method=\"get\" action=\"voto.php\" target=\"_blank\"><input type=\"hidden\" name=\"idjogo\" value=\"$id_jogo\"><input type=\"hidden\" name=\"idtexto\" value=\"$a\"><input type=\"hidden\" name=\"nometexto\" value=\"$consulta\"></input><input type=\"submit\" name=\"submit\" value=\"$consulta\"></span></form>";
echo "</div></td></tr>";
}
}
echo "<tr bgcolor=\"#D5EDB3\"><td colspan=\"5\" class=\"styleBorderRed\"> Parâmetro A<br />";
// mysql_abrir_sessao();
$a = (($id_jogo-1) * 4) +1;
$b = $a + 4;
$i = 0;
for (($a=$a);($a<$b);($a++))
{
$sql = "SELECT `parametroa` FROM `parametro` WHERE `id_parametro` = '$a'";
$resultado = mysql_query($sql);
if ($resultado) {
$dado = mysql_fetch_object($resultado);
echo "{$dado->parametroa} <br />";
} else {
echo "<p>Erro na SQL: {$sql}</p>";
}
}
// mysql_close()
echo "</td><td colspan=\"1\" bgcolor=\"#e70000\"><center>WWWWW</center></td><td colspan=\"1\" bgcolor=\"#e76502\"><center>WWWW</center></td><td colspan=\"1\" bgcolor=\"#e5b402\"><center>WWW</center></td> <td colspan=\"1\" bgcolor=\"#cce704\"><center>WW</center></td><td colspan=\"1\" bgcolor=\"#88e702\"><center>W</center></td><td colspan=\"1\" bgcolor=\"#02e743\"><center>WW</center></td> <td colspan=\"1\" bgcolor=\"#00e7a2\"><center>WWW</center></td><td colspan=\"1\" bgcolor=\"#00d0e7\"><center>WWWW</center></td><td colspan=\"1\" bgcolor=\"#006ce7\"><center>WWWWW</center></td> <td colspan=\"5\" class=\"styleBorderBlue\"> Parâmetros B <br />";
//mysql_abrir_sessao();
$a = (($id_jogo-1) * 4) +1;
$b = $a + 4;
$i = 0;
for (($a=$a);($a<$b);($a++))
{
$sql = "SELECT `parametrob` FROM `parametro` WHERE `id_parametro` = '$a'";
$resultado = mysql_query($sql);
if ($resultado) {
$dado = mysql_fetch_object($resultado);
echo "{$dado->parametrob} <br />";
} else {
echo "<p>Erro na SQL: {$sql}</p>";
}
}
echo "</td> </tr>";
}
}
else{
listajogos();
}
?>
<tr bgcolor="#D5EDB3">
<td bgcolor="#D5EDB3" colspan="19"><span class="style5"><div align="center">|| Texto Livre .org || GNU 2007 ||</div><div align="right"><a href="creditos.html" title="Créditos" target="_blank">Créditos</a></div></span></td>
</tr>
</table>
Linha do Texto v1, Copyright (C) 2010 Ana Cristina Fricke Matte
Linha do Texto comes with ABSOLUTELY NO WARRANTY. This is free software, and you are welcome to redistribute it under certain conditions; see GNUv.2 license for details (LICENSE.TXT or LICENCE_PT_BR.TXT).
</body>
</html>