window.location = "./empr.php";'; die; } $empr_temp = new emprunteur($id_empr, '', FALSE, 0); $rqt="select duree_adhesion from empr_categ where id_categ_empr='$empr_temp->categ'"; $res_dur_adhesion = pmb_mysql_query($rqt, $dbh); $row = pmb_mysql_fetch_row($res_dur_adhesion); $nb_jour_adhesion_categ = $row[0]; $query = 'update empr set empr_date_expiration = date_add("'.$empr_temp->date_expiration.'",INTERVAL '.$nb_jour_adhesion_categ.' DAY) WHERE id_empr = '.$id_empr; pmb_mysql_query($query); echo '

'.sprintf($msg['empr_renewal_success'], date_format(date_add(date_create($empr_temp->date_expiration), date_interval_create_from_date_string($nb_jour_adhesion_categ.' days')), $msg['date_format'])).'

'; echo '';