50 lines
2.4 KiB
PHP
Executable File
50 lines
2.4 KiB
PHP
Executable File
<?php
|
|
$header_title="Mes abonnements - ".SITE_NOM;
|
|
$body_title="Gestion de vos abonnements.";
|
|
|
|
$ariane_items[0]["txt"]="<li>Gérez vos abonnements.</li>";
|
|
$ariane_items[0]["form"]=false;
|
|
$ariane_items[0]["actif"]=false;
|
|
|
|
$msg_infos[0]="Hello ".$_SESSION["pseudo"]." !<br>Voici un récapitulatif des principales configurations de vos abonnements.<br>Pour voir leurs actualités, <a href='".PAGE_ACCUEIL."'>rendez vous sur votre page d'accueil</a>.";
|
|
if(!empty($_SESSION["message"]))
|
|
{
|
|
$msg_infos[1]="<strong>".$_SESSION["message"]."</strong>";
|
|
$_SESSION["message"]="";
|
|
}
|
|
$body_content="<p class='liste_liens_btn'>Accès rapide : <a href='".PAGE_ACCUEIL."' class='btn btn-info btn-xs' title=\"Votre page d'accueil\">Accueil.</a> <a href='".PAGE_REPERTOIRE_ACCUEIL."' class='btn btn-info btn-xs' title='Créer un nouvel abonnement'>+ Nouvel abonnement.</a></p>";
|
|
foreach($mes_abos as $abo_infos)
|
|
{
|
|
$body_content.="<div class='liste_abos' id='abo_".$abo_infos["id_abonnement"]."'><h3>".$abo_infos["designation"]." <a href='".PAGE_ABO_AFFICHE.$abo_infos["id_abonnement"]."' class='btn btn-success btn-xs' title=\"Voir les dernières actualités de cet abonnement.\">Voir.</a></h3>
|
|
<p class='lead'>Vous recevez les actualités de cet abonnement par email : <u>";
|
|
$jours=explode("|",str_replace(array("]","["),"",str_replace("][","|",$abo_infos["jours_alerte"])));
|
|
$nb=count($jours);
|
|
if(($nb==0)||(empty($abo_infos["jours_alerte"])))
|
|
$body_content.=" jamais";
|
|
elseif($nb==7)
|
|
$body_content.=" tous les jours";
|
|
else
|
|
{
|
|
if($nb==1)
|
|
$body_content.=" le ";
|
|
else
|
|
$body_content.=" les ";
|
|
foreach($jours as $j)
|
|
$body_content.=" ".$Jours_semaine[$j];
|
|
}
|
|
if(($nb!=0)&&(!empty($abo_infos["jours_alerte"]))&&(!empty($abo_infos["heure_alerte"])))
|
|
$body_content.=" à ".$abo_infos["heure_alerte"]." H</u>.<br><br>";
|
|
else
|
|
$body_content.="</u>.<br>";
|
|
if(!empty($abo_infos["hubs"]))
|
|
{
|
|
$body_content.="Cet abonnement concerne :";
|
|
foreach($abo_infos["hubs"] as $hub_infos)
|
|
$body_content.=" <a href='".PAGE_REPERTOIRE_HUB_INFO.$hub_infos["id_hub"]."' target='_blank'>".$hub_infos["nom"]."</a> |";
|
|
$body_content.="";
|
|
}
|
|
$body_content.="<p><a href='".PAGE_ABO_MAJ.$abo_infos["id_abonnement"]."' class='btn btn-info'>Modifier / supprimer.</a></p></div>";
|
|
}
|
|
$body_content.="<p><a href='".PAGE_REPERTOIRE_ACCUEIL."' class='btn btn-success btn-lg' title='Créer un nouvel abonnement.'>+ Nouvel abonnement.</a></p>";
|
|
|
|
require(TEMPLATE_REP."/page.php"); |