/*******************************************************************************
*     MOD PrintAndDownload :: version 1.0.0
*
*   ---------- Auteur --------------------------------------------------------
*   Auteur ::				Grummfy
*   Email ::				grrumf@yahoo.fr
*   Site Web ::				http://www.grummfy.com
*
*   ---------- Mod -----------------------------------------------------------
*   Nom ::					PrintAndDownload
*   Version ::				1.0.0
*   Compatible ::			FSB 1.0.5
*
*   Description ::			Permet d'imprimer et de tlcharger un sujet et/ou un messagge
*
*   Temps d'installation ::	~7 minutes
*   Requete ::				Oui
*   Cache ::				Oui
*   Fichiers joins ::		6
*   Fichiers  modifier ::	4
*
*   ---------- Note ----------------------------------------------------------
*	
*
*   ---------- Historique ----------------------------------------------------
*   Commenc ::               Le 08 / 04 / 2006
*   Dernire modification ::  Le 
**   Le 08 / 04 / 2006 ::
*		Premire version
**
*******************************************************************************/
#
# [1] ---------- copier ---------------------------------------------------------
#
"root/includes/printanddownload.php" >> "includes/printanddownload.php"
"root/includes/class/class_tplextended.php" >> "includes/class/class_tplextended.php"
"root/themes/IceCold/images/fr/*" >> "root/themes/IceCold/images/fr/*"

#
# [2] ---------- ouvrir ---------------------------------------------------------
#
includes/functions/fonctions_session.php

#
# [3] ---------- chercher -------------------------------------------------------
#
$tpl = new Tpl($racine . 'themes/' . $membre['membre_theme'], $racine . 'cache/cache_tpl/' . $membre['membre_theme']);

#
# [4] ---------- apres, ajouter -------------------------------------------------
#
// mods :: PrintAndDownload ----------------------------------------------------
// ajout
	if (defined('PRINTANDDOWNLOAD'))
	{
		include($racine . 'includes/class/class_tplextended.php');
		$tpl = new TplExtended($racine . 'themes/' . $membre['membre_theme'], $racine . 'cache/cache_tpl/' . $membre['membre_theme']);
	}
// fin ajout
// mods :: PrintAndDownload ----------------------------------------------------

#
# [5] ---------- ouvrir ---------------------------------------------------------
#
sujet.php

#
# [6] ---------- chercher -------------------------------------------------------
#
define('FORUM', TRUE);

#
# [7] ---------- apres, ajouter -------------------------------------------------
#
#
// mods :: PrintAndDownload ----------------------------------------------------
// ajout
define('PRINTANDDOWNLOAD', true);
// fin ajout
// mods :: PrintAndDownload ----------------------------------------------------

#
# [8] ---------- chercher -------------------------------------------------------
#
if ( ! $droits['droit_voir'] || ! $droits['droit_lire'] )
{
	info($langue['info_titre'], $langue['interdit_droit_voir']);
}

#
# [9] ---------- apres, ajouter -------------------------------------------------
#
// mods :: PrintAndDownload ----------------------------------------------------
// ajout
if ($GLOBALS['MOD']['printanddownload'])
{
	include_once($racine . 'includes/printanddownload.php');
}
// fin ajout
// mods :: PrintAndDownload ----------------------------------------------------

#
# [10] ---------- chercher -------------------------------------------------------
#
	'FORUMBOX_CODE' =>	$forumbox['code']
));

#
# [11] ---------- apres, ajouter -------------------------------------------------
#
// mods :: PrintAndDownload ----------------------------------------------------
// ajout
if ($GLOBALS['MOD']['printanddownload'])
{
	printanddownload_tpl(&$tpl, $theme['img'], $racine . 'themes/' . $membre['membre_theme'] . 'images/' . $membre['membre_langue'], $sujet_id);
}
// fin ajout
// mods :: PrintAndDownload ----------------------------------------------------

#
# [12] ---------- chercher -------------------------------------------------------
#
	if( $message[$p]['membre_id'] != INVITE )
	{
		$tpl->assign_block_vars( 'message.pas_invite', array() );
	}
#
# [13] ---------- avant, ajouter -------------------------------------------------
#
// mods :: PrintAndDownload ----------------------------------------------------
// ajout
	if ($GLOBALS['MOD']['printanddownload'])
	{
		printanddownload_tpl_message(&$tpl, $theme['img'], $racine . 'themes/' . $membre['membre_theme'] . 'images/' . $membre['membre_langue'], $message[$p]['message_id']);
	}
// fin ajout
// mods :: PrintAndDownload ----------------------------------------------------

#
# [14] ---------- ouvrir ---------------------------------------------------------
#
langues/fr/langue_module.php

#
# [15] ---------- chercher -------------------------------------------------------
#
?>

#
# [16] ---------- avant, ajouter -------------------------------------------------
#
// mods :: PrintAndDownload ----------------------------------------------------
// ajout
if ($GLOBALS['MOD']['printanddownload'])
{
	$langue['teleprint_dpost'] = 'Tlcharger le message';
	$langue['teleprint_dtopic'] = 'Tlcharger le topic';
	$langue['teleprint_print_t'] = 'Imprimer le sujet';
	$langue['teleprint_print_m'] = 'Imprimer le message';
	// erreur
	$langue['teleprint_nooption'] = 'La clef n\'est pas dfinie';
}
// fin ajout
// mods :: PrintAndDownload ----------------------------------------------------

#
# [17] ---------- ouvrir ---------------------------------------------------------
#
themes/IceCold/sujet_corps.tpl

#
# [18] ---------- chercher -------------------------------------------------------
#
<td width="200">{IMG_NOUVEAU} {IMG_REPONDRE}</td>

#
# [19] ---------- dans la ligne chercher -----------------------------------------
#
<td width="200">{IMG_NOUVEAU} {IMG_REPONDRE}

#
# [20] ---------- apres, ajouter -------------------------------------------------
#
<!-- IFEXIST switch_mod_printanddownload --><a href="{DOWNLOAD_TOPIC}" class="genmed">{DOWNLOAD_IMG_T}</a><a href="{PRINT_T}" target="{PRINT_TARGET}" onclick="{PRINT_JS}">{PRINT_IMG_T}</a><!-- ENDIF -->

#
# [21] ---------- chercher -------------------------------------------------------
#
<td class="td_entete_sujet" height="25" valign="middle" align="right" nowrap="nowrap">{message.IMG_EDITER} {message.IMG_SUPPR} {message.IMG_CITER} </td>

#
# [22] ---------- dans la ligne chercher -----------------------------------------
#
<td class="td_entete_sujet" height="25" valign="middle" align="right" nowrap="nowrap">{message.IMG_EDITER} {message.IMG_SUPPR} {message.IMG_CITER} 

#
# [23] ---------- apres, ajouter -------------------------------------------------
#
<!-- IFEXIST switch_mod_printanddownload -->{message.IMG_DOWNLOAD} {message.IMG_PRINT}<!-- ENDIF -->

#
# [24] ---------- chercher -------------------------------------------------------
#
<td width="200">{IMG_NOUVEAU} {IMG_REPONDRE}</td>

#
# [25] ---------- dans la ligne chercher -----------------------------------------
#
<td width="200">{IMG_NOUVEAU} {IMG_REPONDRE}

#
# [26] ---------- apres, ajouter -------------------------------------------------
#
<!-- IFEXIST switch_mod_printanddownload --><a href="{DOWNLOAD_TOPIC}" class="genmed">{DOWNLOAD_IMG_T}</a><a href="{PRINT_T}" target="{PRINT_TARGET}" onclick="{PRINT_JS}">{PRINT_IMG_T}</a><!-- ENDIF -->

#
# [27] ---------- requete cache --------------------------------------------------
#
INSERT ac_mods FIELDS mod_name mod_version mod_description mod_auteur mod_email mod_actif VALUES 'printanddownload' '1.0.0' 'Permet d'imprimer et de tlcharger un sujet et/ou un messagge' 'grummfy' 'grummfy@yahoo.fr' '1'
# si vous utiliser le mod "up mod mods" :
#INSERT ac_mods FIELDS mod_name mod_version mod_description mod_auteur mod_email mod_actif mod_use_desactivation last_verf mod_a_jour mod_auteur_site mod_compatible  VALUES 'printanddownload' '1.0.0' 'Permet d'imprimer et de tlcharger un sujet et/ou un messagge' 'grummfy' 'grummfy@yahoo.fr' '1'  '1' '0' '1' 'http://www.grummfy.com' '1.0.5';