Exemple #1
0
	static function get_toolbar($options=array('add'=>'1','cancel'=>'1','send'=>'1')) {
		$toolbar = "<ul>";
		if(!empty($options['send'])) 	{
			switch($options['send']) {
				case 1 : 
				$toolbar .=  "<li><a href='?a=5&expediteur=" . CTableUser::get_email_admin() . "'><img src='../img/quicksend.gif' /> Envoi rapide</a></li>";
				break;
				case 2 :
				$toolbar .=  "<li><img src='../img/quicksend.png' class='grise'/> Envoi rapide</li>";
				break;
			}
		}
		if(!empty($options['add'])) 	{
			switch($options['add']) {
				case 1 : 
					$toolbar .=  "<li><a href='?a=4'><img src='../img/ajouter.gif' />Planifier un envoi group&eacute;</a></li>";
				break;
				case 2 :
					$toolbar .=  "<li><img src='../img/ajouter.gif' class='grise'/>Planifier un envoi group&eacute;</li>";
				break;
			}
		}
		if(!empty($options['cancel'])) 	{
			switch($options['cancel']) {
				case 1 : 
				$toolbar .=  "<li><a href='?a=0'><img src='../img/annuler.gif' />Annuler</a></li>";
				break;
				case 2 :
				$toolbar .=  "<li><img src='../img/cancel.png' class='grise'/>Annuler</li>";
				break;
			}
		}
		$toolbar .= "</ul>";
		return $toolbar;
	}
Exemple #2
0
        }

/*------------------------------------------------------
		A FAIRE DANS TOUS LES CAS
--------------------------------------------------------*/
        $filtre_etat 		= CSession::get('filtre_etat', 0);
        $filtre_date_debut 	= CDate::date_switch(CSession::get('filtre_date_debut'));
        $filtre_date_fin 	= CDate::date_switch(CSession::get('filtre_date_fin'));
        $filtre_sujet 		= CSession::get('filtre_sujet', '%%');
        $filtre_nom_user 	= CSession::get('filtre_nom_user');
        $filtre_prenom_user	= CSession::get('filtre_prenom_user');

        $_filtre_etat = ($filtre_etat=='%%')?"etat LIKE '%%'":' etat = '.$filtre_etat;
        //echo $_filtre_etat;

        $filtre  = " expediteur LIKE '" . CTableUser::get_email_admin() .  "' AND " . $_filtre_etat . " AND " . CSql::between($filtre_date_debut, $filtre_date_fin)  . " AND nom LIKE '" . $filtre_sujet . "' AND destinataire LIKE '%" . CTableUser::get_element($filtre_nom_user, 'email') . "%' AND destinataire LIKE '%" . CTableUser::get_element($filtre_prenom_user, 'email') . "%'"; // AND type = 'default'";
        // echo $filtre;

        $r_email = CTableEmail::select("*", $filtre, $order);

        ?>
        <!-- InstanceEndEditable -->
        <div id="mainwrap">
            <div id="header"><?php include("../nav/header.php"); ?></div>
            <div id="top"><?php include("../nav/menu_h.php"); ?></div>
            <div id="filet">
                <div id="zonetitre">
                    <div id="signe"></div>
                    <div id="titre"><!-- InstanceBeginEditable name="titre" -->Envoi<!-- InstanceEndEditable --></div>
                </div>
            </div>
Exemple #3
0
<?php
include("../inc/init.php");

if(!empty($_GET['message_number'])) $message_number = $_GET['message_number'];
if(!empty($_GET['passe'])) 			$passe 			= $_GET['passe'];

$imap = new CImap(CTableConfiguration::get_value_by_element('POP_SERVER'), CTableUser::get_email_admin(), $passe);
if(@$imap->connect()) {
	$info 	  = @$imap->get_info($message_number);
	$email_id = $imap->load($message_number);
	echo "Sauvegarde du message " . $message_number;
?>
<script type="text/javascript">
$('first').insert({after:'<tr><td><a href="show_reception.php?id=<?php echo $email_id ?>" target="popup" onclick="popup(this.href, this.target, 800, 600);"><?php echo $email_id ?></a></td><td><?php echo CTableGroupe::get_href($info['from']) ?></td><td><?php echo utf8_encode($info['subject']) ?></td><td><?php echo CDate::date_switch(CDate::formate_date($info['date'])) ?></td><td align="center" class="info etat <?php echo 'etat_0'?>"><div class="bulle"><img src="../img/publish_x.png" alt="Non lu" /> Non lu<br /><a href="reception.php?a=2&id=<?php echo $email_id ?>&etat=1"><img src="../img/publish_g.png" alt="Lu" /> Lu</a><br /><a href="reception.php?a=2&id=<?php echo $email_id ?>&etat=2"><img src="../img/publish_u.png" alt="Archivé" /> Archiv&eacute;</a></div></td></tr>'});
</script>
<?php
} else  {
	echo "Echec de chargement du message " . $message_number;
}
?>

<a href="show_reception.php?id=<?php echo stripslashes($email['id']) ?>" target="popup" onclick="popup(this.href, this.target, '800', '600');"> <?php echo $email['id'] ?> </a>
Exemple #4
0
		$trdv = new CTableRdv(array('iduser' => $id, 'nom'=>CFunctions::addslashes($nom_rdv), 'date' => $date_rdv, 'heure' => $heure_rdv,  'type' => $type_rdv, 'etat' => $etat_rdv));
		$trdv->insert();
	}
	
	// --- DEBUT envoye mail
    if ($radioText && $idopportunite)
    {
        
        $zSqlEnvoieMail  = " SELECT opportunite.*, hbpiecesjointes.piece AS piece, text FROM opportunite" ;
        $zSqlEnvoieMail .= " LEFT JOIN hbpiecesjointes ON hbpiecesjointes.id = pieId" ;
        $zSqlEnvoieMail .= " LEFT JOIN texte ON texte.id = texId" ;
        $zSqlEnvoieMail .= " WHERE opportunite.id = " . $idopportunite ;
        
        $toEnvoyes = CBdd::select_row($zSqlEnvoieMail) ;
        
        $expediteur = CTableUser::get_email_admin() ;
        $destinataire = $email ;
        $liste_email = CTableHbGroupe::get_liste_email($destinataire);
        
        // --- Creation du mail en HTML
        $texte = CBdd::select_row("SELECT nom, text, style FROM texte WHERE id = " . $toEnvoyes['texId']);
        
        $body = CNmail::build_html_body($texte['style'], $texte['text']);
        
        $zDate = date('Y-m-d H:i:s')  ;
              
        $obj = new CTableEmail(array(
        	'expediteur'=>CFunctions::addslashes($expediteur),
        	'destinataire'=>CFunctions::addslashes($destinataire),
        	'nom'=>CFunctions::addslashes($texte['nom']),
        	'id_text' => $toEnvoyes['texId'],	
Exemple #5
0
                <?php } ?>
              </div></td>
              <td><a href="envoi.php?a=5&reply=<?php echo $email['id'] ?>">&gt;</a></td>
              <td><?php echo CHtmlSession::get_delbutton($a, $email['id'], $id, CTableUser::is_admin($_SESSION['idmbr'])) ?></td>
          </tr>
          <?php $i++; } ?>
        </table>
<?php } 
//----------------------------------------------------------------------------------------------
// AJOUT
//----------------------------------------------------------------------------------------------
if($a == 4) { ?>
        <form id="form_ajout" method="post" action="reception.php">
          <p> <?php echo CForm::get_hidden(44) ?> </p>
          <fieldset>
            <legend>Formulaire de rel&egrave;ve des courriers de <u><?php echo CTableUser::get_email_admin() ?></u> du serveur : <u><?php echo CTableConfiguration::get_value_by_element('POP_SERVER') ?></u></legend>
            <p>
              <label>Password  POP </label>
              <input name="passe" type="password" id="passe" value="<?php echo $passe ?>"/>
              <?php echo CHtml::get_msginfo($error_signe['passe'])?></p>
            <p>
              <label>Relever les</label>
              <input name="nb_traitement" type="text" id="nb_traitement" value="<?php echo $nb_traitement ?>"/> 
              derniers messages ( Par d&eacute;faut et Maximum : <?php echo MAIL_MAX_RECEPT ?>)
            </p>
            <p>
              <input name="creer" type="submit" value="Relever >>"/>
            </p>
          </fieldset>
        </form>
<?php } ?>