[go: up one dir, main page]

Menu

[r3]: / crialinhadotexto.php  Maximize  Restore  History

Download this file

130 lines (117 with data), 5.5 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
<!--
########################################################################################
# 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;
}
>
</style>
<?php
include "config.php";
include "funcoes.php";
?>
</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">Cria Novo Jogo Na Linha do Texto</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></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="9" id="dateformat" height="20">&nbsp;&nbsp;
<script language="JavaScript" type="text/javascript">
document.write(TODAY); </script></td>
<td colspan="1" id="voltar" height="20"><span class="subHeader"><a href="index.php" title="Voltar"> Volta para a Linha do Texto </span></a> </td></tr>
</table>
<h1>Preencha o formulário para criar um novo jogo</h1>
<?
formulario();
?>
<h3>Para editar o jogo já existente, <a href="editalinhadotexto.php">clique aqui!</a>"</h3>
<?php
$apertou = $_POST["apertou"];
if ((!empty($apertou)) and ($apertou!="")){
include "config.php";
$senhanovatabela = $_POST["senhanovatabela"];
$jogo = $_POST["jogo"];
$email = $_POST["email"];
if (($senhanovatabela==$senhacriatabela) and (!empty($senhanovatabela)) and ($senhanovatabela!="")){
if (((!empty($email)) and ($email!="")) and ((!empty($jogo)) and ($jogo!=""))){
mysql_abrir_sessao();
$sql = mysql_query("INSERT INTO `jogo` (`jogo`, `email`) VALUES ('$jogo', '$email');");
$id_jogo = mysql_insert_id();
$a = (($id_jogo*9)-1);
if (!empty($sql) and ($sql != "")){
for (($i=1);($i<10);($i++))
{
$tabelaTexto = mysql_query("INSERT INTO `texto` (`id_jogo`, `titulo`, `texto`) VALUES ('$id_jogo', '', '');");
$tabelavoto = mysql_query("INSERT INTO `voto` (`id_jogo`, `id_texto`, `voto`) VALUES ('$id_jogo', '$a', '5');");
$a++;
}
for (($i=1);($i<5);($i++))
{
$tabelaParametro = mysql_query("INSERT INTO `parametro` (`id_jogo`, `parametroa`, `parametrob`) VALUES ('$id_jogo', '', '');");
}
echo "<h2>Cadastro bem sucedido!</h2>Para inserir textos no novo jogo, <b><a href=\"editalinhadotexto.php\">clique aqui!</b></a>";
}
else{ $erro = mysql_error();
echo "Estamos com problemas técnicos! Por favor, tente mais tarde!";
mail("a9fm@yahoo.com","Problemas Cadastro Experimento","Problemas com o usuario: $email. dados:email=$email jogo=$jogo senhanovatabela=$senhanovatabela erro = $erro");
}
}
}else{echo "A senha está incorreta.";}
}
?>
</body>
</html>