<?php
/*********************************************************************************
 * Gest'Ecole is a school management software developped by
 * DOX Conception Copyright (C) 2012-2013 DOX Conception
 *
 * This program is free software; you can redistribute it and/or modify it under
 * the terms of the license published by DOX Conception.
 * 
 * This program is distributed in the hope that it will be useful, but WITHOUT
 * ANY WARRANTY.  See the Software License for more details.
 * 
 * You should have received a copy of the software license along with
 * this program; if not, see:
 * http://www.doxconception.com/index.php/licence-de-gestecole.html
 ********************************************************************************/

  $id=$_POST['id'];
  $titre=$_POST['titre'];
  $nb_param=$_POST['nb_param'];
  $param="";
  for ($i=1;$i<=$nb_param;$i++)
  {
    $param=$param.$_POST['param'.$i]."|";
  }
  $req=mysql_query("UPDATE `accueil_perso` SET titre='".$titre."', parametre='".substr($param,0,strlen($param)-1)."' WHERE id='$id'");
?>