Commit aa34849a authored by Seblu's avatar Seblu

adding news global perm variable

div main_body is now manager by section.php
fix regession with number of news displayed on first page
fix fucking bug on home page with no border at menu level
remove useless images
fixing css issue
replacing section get param by html
fixing some trailing and indent
parent 3fcb4429
This diff is collapsed.
......@@ -23,18 +23,18 @@ $str = '
<font class="titre_rubrique">
&nbsp;e d i t o&nbsp;
</font>
</b>
</b>
</td>
</tr>
<tr>
<td>
<FORM name="new_edito" method="post" action="index.php?section=AdminHome&section_admin=AdminAddEdito">
<FORM name="new_edito" method="post" action="index.php?html=AdminHome&section_admin=AdminAddEdito">
<INPUT class="button" TYPE="submit" NAME="action" VALUE=" NOUVEL EDITO "><BR> </TD>
</FORM>
</td>
</tr>
<tr>
<td bgcolor="#303030">
<table cellpadding="2" cellspacing="2" width="100%">
......@@ -58,7 +58,7 @@ $str = '
par: '
.$member["user_pseudo"].
'</td></tr>
<tr><td>
<font class="texte_normal">
<b>'
......@@ -72,25 +72,25 @@ $str = '
.$edito["edito_comment"].
'</small>
</td>
<TD width=10% align=right>
<FORM name="update_edito" method="post" action="index.php?section=AdminHome&section_admin=AdminModifEdito&edito_id='.$edito_id.'">
<INPUT class="button" TYPE="submit" NAME="action" VALUE=" MODIFIER ">
<FORM name="update_edito" method="post" action="index.php?html=AdminHome&section_admin=AdminModifEdito&edito_id='.$edito_id.'">
<INPUT class="button" TYPE="submit" NAME="action" VALUE=" MODIFIER ">
</FORM>
<FORM name="supp_edito" method="post" action="index.php?section=AdminHome&section_admin=AdminDelEdito&edito_id='.$edito_id.'">
<FORM name="supp_edito" method="post" action="index.php?html=AdminHome&section_admin=AdminDelEdito&edito_id='.$edito_id.'">
<INPUT class="button" TYPE="submit" NAME="action" VALUE=" SUPPRIMER ">
</FORM>
</FORM>
</TD>
</tr>
';
$str .= '
<tr>
<TD> <hr width="90%"> </TD>
</tr>
';
';
}
......@@ -117,7 +117,7 @@ function dispAdminAddEdito () {
$date = get_date();
$str = '
$str = '
<table width="80%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td bgcolor="#000000">
......@@ -128,20 +128,20 @@ function dispAdminAddEdito () {
<font color="#ffffff">
&nbsp a d d &nbsp e d i t o &nbsp t o &nbsp d a t a b a s e
</font>
</b>
</b>
</td>
</tr>
</tr>
<tr>
<td bgcolor="#303030">
<table cellpadding="0" cellspacing="0" width="100%">
<tr>
<form name="saisie" method="post" action="index.php?section=AdminHome&section_admin=AddEdito&edito_id='.$edito_id.'">
<tr>
<form name="saisie" method="post" action="index.php?html=AdminHome&section_admin=AddEdito&edito_id='.$edito_id.'">
<TABLE CELLSPACING="0" CELLPADDING="10" BORDER="0">
<TR><TD> Titre: </TD>
<TD> <INPUT TYPE="text" NAME="edito_get_title" VALUE="" SIZE="50" MAXLENGTH="52"> </TD>
</TR>
<TR><TD> Date: </TD>
<TD> <INPUT TYPE="text" NAME="edito_get_date" VALUE="'.$date.'" SIZE="8" MAXLENGTH="10"> </TD>
</TR>
......@@ -151,7 +151,7 @@ function dispAdminAddEdito () {
<TEXTAREA rows="12" cols="38" name="edito_get_comment" ONFOCUS=""></textarea>
</TD>
</TR>
<TR>
<TD> </TD>
<TD> <INPUT class="button" TYPE="submit" NAME="action" VALUE=" UPLOADER "> </TD>
......@@ -181,7 +181,7 @@ function dispAdminModifEdito () {
$result = getOneEdito($edito_id);
$str = '
$str = '
<table width="80%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td bgcolor="#000000">
......@@ -192,27 +192,27 @@ $str = '
<font color="#ffffff">
&nbsp m o d i f y &nbsp e d i t o
</font>
</b>
</b>
</td>
</tr>
</tr>
<tr>
<td bgcolor="#303030">
<table cellpadding="0" cellspacing="0" width="100%">
<tr>
<tr>
';
if (mysql_num_rows($result)){
$edito = mysql_fetch_array($result);
$edito = mysql_fetch_array($result);
}
$str .= '
<form name="saisie" method="post" action="index.php?section=AdminHome&section_admin=ModifEdito&edito_id='.$edito_id.'">
<form name="saisie" method="post" action="index.php?html=AdminHome&section_admin=ModifEdito&edito_id='.$edito_id.'">
<TABLE CELLSPACING="0" CELLPADDING="10" BORDER="0">
<TR>
<TD> Titre: </TD>
<TD> <INPUT TYPE="text" NAME="edito_get_uptitle" VALUE="'.$edito["edito_title"].'" SIZE="50" MAXLENGTH="52"> </TD>
</TR>
<TR>
<TD> Date: </TD>
<TD> <INPUT TYPE="text" NAME="edito_get_update" VALUE="'.$edito["edito_date"].'" SIZE="8" MAXLENGTH="10"> </TD>
......@@ -230,7 +230,7 @@ $str = '
$id_user = getOneUserById($edito["edito_id_user"]);
if (mysql_num_rows($id_user)){
$id_user = mysql_fetch_array($id_user);
$id_user = mysql_fetch_array($id_user);
}
$str .= $id_user["user_pseudo"].'</TD></TR>';
......@@ -268,7 +268,7 @@ function dispAdminDelEdito () {
$result = getOneEdito($edito_id);
$str = '
$str = '
<table width="80%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td bgcolor="#000000">
......@@ -279,27 +279,27 @@ $str = '
<font color="#ffffff">
&nbsp d e l e t e &nbsp e d i t o
</font>
</b>
</b>
</td>
</tr>
</tr>
<tr>
<td bgcolor="#303030">
<table cellpadding="0" cellspacing="0" width="100%">
<tr>
<tr>
';
if (mysql_num_rows($result)){
$edito = mysql_fetch_array($result);
$edito = mysql_fetch_array($result);
}
$str .= '
<form name="saisie" method="post" action="index.php?section=AdminHome&section_admin=DelEdito&edito_id='.$edito_id.'">
<form name="saisie" method="post" action="index.php?html=AdminHome&section_admin=DelEdito&edito_id='.$edito_id.'">
<TABLE CELLSPACING="0" CELLPADDING="10" BORDER="0">
<TR><TD> Titre: </TD>
<TD>'.$edito["edito_title"].'</TD>
</TR>
<TR><TD> Date: </TD>
<TD> '.$edito["edito_date"].'</TD>
</TR>
......@@ -309,8 +309,8 @@ $str = '
'.$edito["edito_comment"].'
</TD>
</TR>';
$str .= '
$str .= '
<TR><TD>Poste par: </TD>
<TD>
';
......@@ -318,7 +318,7 @@ $str = '
$id_user = getOneUserById($edito["edito_id_user"]);
if (mysql_num_rows($id_user)){
$id_user = mysql_fetch_array($id_user);
$id_user = mysql_fetch_array($id_user);
}
$str .= $id_user["user_pseudo"].'</TD></TR>';
......@@ -327,7 +327,7 @@ $str = '
<TR>
<TD> </TD>
<TD> <INPUT class="button" TYPE="submit" NAME="action" VALUE=" SUPPRIMER "> </TD>
</TR>
</TR>
</TABLE>
</FORM>
</TR>
......
......@@ -15,7 +15,7 @@ include_once "admin/admin_blacklist.php";
if ($_SESSION["user_right"] >= $GLOBALS["REPORTER"] )
{
$str = '<div id="main_body">';
$str = '<div id="all_side">';
$str .= '<table width="100%">
<tr>
<td height="589" valign="top">
......@@ -133,7 +133,6 @@ $str .= '
$str .= '
<table width="80%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td bgcolor="#000000">
......@@ -347,12 +346,11 @@ $str .= '
</table>
</div>
';
}
else
{
$str = '
......
......@@ -9,7 +9,7 @@ if ($_SESSION["user_right"] < $GLOBALS["EPTV"] )
}
$str = '
<table width="80%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td bgcolor="#000000">
......@@ -21,16 +21,16 @@ $str = '
<font color="#ffffff">
&nbsp a l l &nbsp l i n k s
</font>
</b>
</b>
</td>
</tr>
<FORM name="new_news" method="post" action="index.php?section=AdminHome&section_admin=AdminAddLink">
<FORM name="new_news" method="post" action="index.php?html=AdminHome&section_admin=AdminAddLink">
<TR>
<TD><INPUT class="button" TYPE="submit" NAME="action" VALUE=" NOUVEAU LIEN "><BR> </TD>
</TR>
</FORM>
<tr>
<td bgcolor="#303030">
<table cellpadding="0" cellspacing="0" width="100%">
......@@ -40,15 +40,15 @@ $str = '
';
$result = getAllLinks();
$result = getAllLinks();
if (mysql_num_rows($result)){
for ($cpt = 0; $cpt < mysql_numrows($result); $cpt++) {
$link = mysql_fetch_array($result);
$element_id = $link["link_id"];
$str .= '
<TR>
<TD>
......@@ -62,17 +62,17 @@ $str = '
<font class="texte_normal">
<small>
'.$link["link_comment"].'
</font>
</small>
</font>
</small>
</TD></TR>
<TD width="20%" align="right">
<FORM name="update_news" method="post" action="index.php?section=AdminHome&section_admin=AdminModifLink&element_id='.$element_id.'">
<INPUT class="button" TYPE="submit" NAME="action" VALUE=" MODIFIER ">
<TD width="20%" align="right">
<FORM name="update_news" method="post" action="index.php?html=AdminHome&section_admin=AdminModifLink&element_id='.$element_id.'">
<INPUT class="button" TYPE="submit" NAME="action" VALUE=" MODIFIER ">
</FORM>
<FORM name="supp_news" method="post" action="index.php?section=AdminHome&section_admin=AdminDelLink&element_id='.$element_id.'">
<FORM name="supp_news" method="post" action="index.php?html=AdminHome&section_admin=AdminDelLink&element_id='.$element_id.'">
<INPUT class="button" TYPE="submit" NAME="action" VALUE=" SUPPRIMER ">
</FORM>
</TD>
......@@ -101,7 +101,7 @@ $str .= '
</td>
</tr>
</table>
';
return $str;
......@@ -113,7 +113,7 @@ function dispAdminAddLink() {
$date = get_date();
$str = '
$str = '
<table width="80%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td bgcolor="#000000">
......@@ -124,20 +124,20 @@ function dispAdminAddLink() {
<font color="#ffffff">
&nbsp a d d &nbsp l i n k &nbsp t o &nbsp d a t a b a s e
</font>
</b>
</b>
</td>
</tr>
</tr>
<tr>
<td bgcolor="#303030">
<table cellpadding="0" cellspacing="0" width="100%">
<tr>
<form name="saisie" method="post" action="index.php?section=AdminHome&section_admin=AddLink&element_id='.$element_id.'">
<tr>
<form name="saisie" method="post" action="index.php?html=AdminHome&section_admin=AddLink&element_id='.$element_id.'">
<TABLE CELLSPACING="0" CELLPADDING="10" BORDER="0">
<TR><TD> Lien: </TD>
<TD> <INPUT TYPE="text" NAME="input_get_link" VALUE="" SIZE="50" MAXLENGTH="52"> </TD>
</TR>
<TR><TD>Commentaire: </TD>
<TD>
<TEXTAREA rows="3" cols="38" name="input_get_comment" ONFOCUS=""></textarea>
......@@ -166,13 +166,13 @@ return ($str);
function dispAdminModifLink() {
$element_id =$_GET['element_id'];
$result = getOneLinkById($element_id);
$str = '
$str = '
<table width="80%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td bgcolor="#000000">
......@@ -183,27 +183,27 @@ $str = '
<font color="#ffffff">
&nbsp m o d i f y &nbsp l i n k
</font>
</b>
</b>
</td>
</tr>
</tr>
<tr>
<td bgcolor="#303030">
<table cellpadding="0" cellspacing="0" width="100%">
<tr>
<tr>
';
if (mysql_num_rows($result)){
$link = mysql_fetch_array($result);
$link = mysql_fetch_array($result);
}
$str .= '
<form name="saisie" method="post" action="index.php?section=AdminHome&section_admin=ModifLink&element_id='.$element_id.'">
<form name="saisie" method="post" action="index.php?html=AdminHome&section_admin=ModifLink&element_id='.$element_id.'">
<TABLE CELLSPACING="0" CELLPADDING="10" BORDER="0">
<TR><TD> Lien: </TD>
<TD> <INPUT TYPE="text" NAME="input_get_link" VALUE="'.$link["link_link"].'" SIZE="30" MAXLENGTH="30"> </TD>
</TR>
<TR><TD>Commentaire: </TD>
<TD>
<TEXTAREA rows="5" cols="38" name="input_get_comment" ONFOCUS="">'.$link["link_comment"].'</textarea>
......@@ -220,7 +220,7 @@ $str = '
<TD> </TD>
<TD> <INPUT class="button" TYPE="reset" NAME="action" VALUE=" RESET "> </TD>
</TR>
</TABLE>
</FORM>
</TR>
......@@ -228,7 +228,7 @@ $str = '
</TD>
</TR>
</TABLE>
';
return $str;
......@@ -243,7 +243,7 @@ $element_id =$_GET['element_id'];
$result = getOneLinkById($element_id);
$str = '
$str = '
<table width="80%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td bgcolor="#000000">
......@@ -254,27 +254,27 @@ $str = '
<font color="#ffffff">
&nbsp d e l e t e &nbsp l i n k
</font>
</b>
</b>
</td>
</tr>
</tr>
<tr>
<td bgcolor="#303030">
<table cellpadding="0" cellspacing="0" width="100%">
<tr>
<tr>
';
if (mysql_num_rows($result)){
$link = mysql_fetch_array($result);
$link = mysql_fetch_array($result);
}
$str .= '
<form name="saisie" method="post" action="index.php?section=AdminHome&section_admin=DelLink&element_id='.$element_id.'">
<form name="saisie" method="post" action="index.php?html=AdminHome&section_admin=DelLink&element_id='.$element_id.'">
<TABLE CELLSPACING="0" CELLPADDING="10" BORDER="0">
<TR><TD> Lien: </TD>
<TD>'.$link["link_link"].'</TD>
</TR>
<TR><TD>Commentaire: </TD>
<TD>
'.$link["link_comment"].'
......@@ -284,7 +284,7 @@ $str = '
<TR>
<TD> </TD>
<TD> <INPUT class="button" TYPE="submit" NAME="action" VALUE=" SUPPRIMER "> </TD>
</TR>
</TR>
</TABLE>
</FORM>
</TR>
......
......@@ -14,7 +14,7 @@ function dispAdminMembers () {
$result = getAllMembers();
$str = '
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td bgcolor="#000000">
......@@ -25,7 +25,7 @@ function dispAdminMembers () {
<font color="#ffffff">
&nbsp a l l &nbsp e p t v &nbsp m e m b e r s
</font>
</b>
</b>
</td>
</tr>
......@@ -35,7 +35,7 @@ function dispAdminMembers () {
$str .= '
<tr>
<td>
<FORM name="new_user" method="post" action="index.php?section=AdminHome&section_admin=AdminAddMember">
<FORM name="new_user" method="post" action="index.php?html=AdminHome&section_admin=AdminAddMember">
<INPUT class="button" TYPE="submit" NAME="action" VALUE=" NOUVEAU MEMBRE "><BR> </TD>
</FORM>
</td>
......@@ -44,7 +44,7 @@ function dispAdminMembers () {
}
$str .= '
$str .= '
<tr>
<td bgcolor="#303030">
<table cellpadding="0" cellspacing="0" width="100%">
......@@ -56,7 +56,7 @@ function dispAdminMembers () {
<td><b>Pseudo</b></td>
<td><b>Statut</b></td>
<td><b>Droit</b></td>
</TR>
<TR>
';
......@@ -107,7 +107,7 @@ function dispAdminMembers () {
$result = getOneUserByID($tab[$cpt]);
$member = mysql_fetch_array($result);
$element_id = $member["user_id"];
$element_id = $member["user_id"];
$str .= '
<tr>
......@@ -132,8 +132,8 @@ function dispAdminMembers () {
if ($_SESSION["user_right"] == $GLOBALS["ROOT"] || $member["user_id"] == $_SESSION["user_id"]) {
$str .= '
<TD width=10% align=right>
<FORM name="update_member" method="post" action="index.php?section=AdminHome&section_admin=AdminModifMember&element_id='.$element_id.'">
<INPUT class="button" TYPE="submit" NAME="action" VALUE=" MODIFIER ">
<FORM name="update_member" method="post" action="index.php?html=AdminHome&section_admin=AdminModifMember&element_id='.$element_id.'">
<INPUT class="button" TYPE="submit" NAME="action" VALUE=" MODIFIER ">
</FORM>
</TD>
';
......@@ -142,7 +142,7 @@ function dispAdminMembers () {
if ($_SESSION["user_right"] == $GLOBALS["ROOT"]) {
$str .= '
<TD width=10% align=right>
<FORM name="supp_member" method="post" action="index.php?section=AdminHome&section_admin=AdminDelMember&element_id='.$element_id.'">
<FORM name="supp_member" method="post" action="index.php?html=AdminHome&section_admin=AdminDelMember&element_id='.$element_id.'">
<INPUT class="button" TYPE="submit" NAME="action" VALUE=" SUPPRIMER ">
</FORM>
</TD>
......@@ -152,7 +152,7 @@ function dispAdminMembers () {
$str .= '
</tr>
';
$cpt++;
}
}
......@@ -171,7 +171,7 @@ function dispAdminMembers () {
</td>
</tr>
</table>
';
......@@ -187,7 +187,7 @@ function dispAdminAddMember() {
$date = get_date();
$str = '
$str = '
<table width="80%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td bgcolor="#000000">
......@@ -198,20 +198,20 @@ function dispAdminAddMember() {
<font color="#ffffff">
&nbsp a d d &nbsp m e m b e r &nbsp t o &nbsp d a t a b a s e
</font>
</b>
</b>
</td>
</tr>
</tr>
<tr>
<td bgcolor="#303030">
<table cellpadding="0" cellspacing="0" width="100%">
<tr>
<form name="saisie" method="post" action="index.php?section=AdminHome&section_admin=AddMember&element_id='.$element_id.'">
<tr>
<form name="saisie" method="post" action="index.php?html=AdminHome&section_admin=AddMember&element_id='.$element_id.'">
<TABLE CELLSPACING="0" CELLPADDING="10" BORDER="0">
<TR><TD> Login: </TD>
<TD> <INPUT TYPE="text" NAME="member_get_login" VALUE="" SIZE="20" MAXLENGTH="20"> </TD>
</TR>
<TR><TD> Pseudo: </TD>
<TD> <INPUT TYPE="text" NAME="member_get_pseudo" VALUE="" SIZE="20" MAXLENGTH="20"> </TD>
</TR>
......@@ -236,7 +236,7 @@ function dispAdminAddMember() {
<TR><TD> Date d entr&eacute;e: </TD>
<TD> <INPUT TYPE="text" NAME="member_get_date" VALUE="'.$date.'" SIZE="8" MAXLENGTH="10"> </TD>
</TR>
<TR><TD>Statut: </TD>
<TD>
<TABLE CELLSPACING"0" CELLPADDING="1" BORDER="0">
......@@ -249,8 +249,8 @@ function dispAdminAddMember() {
//// SELECT IF DISPLAY EACH STATUT IF FREE
$result_statut = getAnExistingStatut("President");
$statut = mysql_fetch_array($result_statut);
$statut = mysql_fetch_array($result_statut);
if (!$statut) {
$str .= '<option value="President">President</option>';
}
......@@ -337,7 +337,7 @@ $element_id =$_GET['element_id'];
$result = getOneUserById($element_id);
$str = '
$str = '
<table width="80%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td bgcolor="#000000">
......@@ -348,37 +348,37 @@ $str = '
<font color="#ffffff">
&nbsp m o d i f y &nbsp m e m b e r
</font>
</b>
</b>
</td>
</tr>
</tr>
<tr>
<td bgcolor="#303030">
<table cellpadding="0" cellspacing="0" width="100%">
<tr>
<tr>
';
if (mysql_num_rows($result)){
$user = mysql_fetch_array($result);
$user = mysql_fetch_array($result);
}
$str .= '
<form name="saisie" method="post" action="index.php?section=AdminHome&section_admin=ModifMember&element_id='.$element_id.'">
<form name="saisie" method="post" action="index.php?html=AdminHome&section_admin=ModifMember&element_id='.$element_id.'">
<TABLE CELLSPACING="0" CELLPADDING="10" BORDER="0">
<TR><TD> Login: </TD>
<TD> <INPUT TYPE="text" NAME="member_get_login" VALUE="'.$user["user_login"].'" SIZE="20" MAXLENGTH="20"
';
if ($_SESSION["user_right"] != $GLOBALS["ROOT"]) {
$str .= 'readonly';
}
$str .= '
> </TD>
</TR>
<TR><TD> Pseudo: </TD>
<TD> <INPUT TYPE="text" NAME="member_get_pseudo" VALUE="'.$user["user_pseudo"].'" SIZE="20" MAXLENGTH="20"> </TD>
</TR>
</TR>
</TR>
<TR><TD> Pass: </TD>
......@@ -398,7 +398,7 @@ $str = '
</TR>
';
if ($_SESSION["user_right"] == $GLOBALS["ROOT"]) {
$str .= '
<TR><TD> Date: </TD>
......@@ -418,7 +418,7 @@ $str = '
$result_statut = getAnExistingStatut("President");
$statut = mysql_fetch_array($result_statut);
if (!$statut || $statut["user_statut"] == $user["user_statut"]) {
$str .= '<option value="President" '.get_selected_option("President",$user["user_statut"]).' >President</option>';
}
......@@ -470,7 +470,7 @@ $str = '
<TR><TD>Signature: </TD>
<TD> <TEXTAREA rows="3" cols="38" name="member_get_signature" ONFOCUS="">'.$user["user_signature"].'</textarea> </TD>
</TR>
';
';
......@@ -502,7 +502,7 @@ $str = '
<TD> </TD>
<TD> <INPUT class="button" TYPE="reset" NAME="action" VALUE=" RESET "> </TD>
</TR>
</TABLE>
</FORM>
</TR>
......@@ -510,7 +510,7 @@ $str = '
</TD>
</TR>
</TABLE>
';
return $str;
......@@ -522,7 +522,7 @@ function dispAdminDelMember() {
$result = getOneUserById($element_id);
$str = '
$str = '
<table width="80%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td bgcolor="#000000">
......@@ -533,27 +533,27 @@ $str = '
<font color="#ffffff">
&nbsp d e l e t e &nbsp m e m b e r
</font>
</b>