Foxy in a box
Geplaatst: 20 mar 2005, 12:36
Ik heb deze mod toegevoegd en dat werkt perfect. Helaas als er geen pop-up blokker gebruikt wordt dan krijgt de gebuiker 2 berichten te zien. 1 Normale en deze mod.
Als de functie in het profiel wordt uitgezet dan heeft dan geen inlvoed op deze mod.
Is dit alles makkelijk aan te passen?
Als de functie in het profiel wordt uitgezet dan heeft dan geen inlvoed op deze mod.
Is dit alles makkelijk aan te passen?
Code: Selecteer alles
##############################################################
## MOD Title: Foxy in a box
## MOD Author: RedFoxy < redfoxy@redfoxy.it > (Massimo Cicciò) http://www.redfoxy.it/
## MOD Description: Using that mod, you can solve problems with private message pop-up and
## anti-pop-up system (such as Internet Explorer for Windows XP SP2,
## Google Tool Bar, FireFox etc...), this mod show a CSS frame on forum
## with private message alert. Very simple and usefully
##
## MOD Version: 1.0.0
##
## Installation Level: Easy
## Installation Time: 1 Minutes
## Files To Edit:
## includes/page_header.php
## templates/subSilver/subSilver.css
## templates/subSilver/simple_header.tpl
## templates/subSilver/overall_header.tpl
## Included Files:
## privmsgs_box.tpl
##
##############################################################
## For Security Purposes, Please Check: http://www.phpbb.com/mods/ for the
## latest version of this MOD. Downloading this MOD from other sites could cause malicious code
## to enter into your phpBB Forum. As such, phpBB will not offer support for MOD's not offered
## in our MOD-Database, located at: http://www.phpbb.com/mods/
##############################################################
## Author Notes:
## That's my first release of that MOD, just to remember what I've do...
## I have tested this MOD whit phpBB 2.0.10 and MySQL Database 3.23.56/4.0.16
## but i'm that it goes wit 2.0.4/2.0.6/2.0.11
##
## EasyMod: Tested with 0.1.13
##
## Future versions can be found at http://www.redfoxy.it
## I've set up a support forum for my mods at http://www.forum.redfoxy.com
##
## This MOD is released under the GPL License.
## Intellectual Property is retained by the MOD Author(s) listed above
## Copyright: (C) 2004 Foxy in a box 1.0.0 - RedFoxy
##############################################################
## MOD History:
##
## 2004-12-15 - Version 1.0.0
## - First release version
##############################################################
## Before Adding This MOD To Your Forum, You Should Back Up All Files Related To This MOD
##############################################################
#
#-----[ COPY ]------------------------------------------------
#
copy privmsgs_box.tpl to templates/subSilver/privmsgs_box.tpl
#
#-----[ SQL ]-------------------------------------------------
#
ALTER TABLE phpbb_users ADD user_notify_box_pm TINYINT(1) DEFAULT '1' NOT NULL;
#
#-----[ OPEN ]------------------------------------------------
#
includes/page_header.php
#
#-----[ FIND ]------------------------------------------------
#
<?php
#
#-----[ AFTER, ADD ]------------------------------------------
#
//-- mod : Foxy in a box --------------------------------------------------------------------------
#
#-----[ FIND ]------------------------------------------------
#
//
// Login box?
//
if ( !$userdata['session_logged_in'] )
{
$template->assign_block_vars('switch_user_logged_out', array());
}
else
{
$template->assign_block_vars('switch_user_logged_in', array());
if ( !empty($userdata['user_popup_pm']) )
{
$template->assign_block_vars('switch_enable_pm_popup', array());
}
}
#
#-----[ AFTER, ADD ]------------------------------------------
#
//-- mod : Foxy in a box --------------------------------------------------------------------------
//-- add
if ($s_privmsg_new==1 && $userdata['user_notify_box_pm']==1) {
if ( $userdata['session_logged_in'] )
{
if ( $userdata['user_new_privmsg'] )
{
$l_new_message = ( $userdata['user_new_privmsg'] == 1 ) ? $lang['You_new_pm'] : $lang['You_new_pms'];
}
else
{
$l_new_message = $lang['You_no_new_pm'];
}
$l_new_message .= '<br /><br />' . sprintf($lang['Click_view_privmsg'], '<a href="' . append_sid("privmsg.".$phpEx."?folder=inbox") . '">', '</a>');
}
else
{
$l_new_message = $lang['Login_check_pm'];
}
$template->set_filenames(array(
'msg_box' => 'privmsgs_box.tpl')
);
$template->assign_vars(array(
'L_CLOSE_WINDOW' => $lang['Close_window'],
'L_MESSAGE' => $l_new_message)
);
$template->assign_var_from_handle('MSG_BOX', 'msg_box');
}
//-- end mod : Foxy in a box ----------------------------------------------------------------------
#
#-----[ OPEN ]------------------------------------------------
#
templates/subSilver/subSilver.css
#
#-----[ FIND ]------------------------------------------------
#
/* General page style. The scroll bar colours only visible in IE5.5+ */
#
#-----[ BEFORE, ADD ]-----------------------------------------
#
/*-- mod : Foxy in a box --------------------------------------------------------------------------*/
/*-- add */
div#private_message{
font:10px Tahoma;
padding:2px;
position:absolute;
top:10%;
left:30%;
width:400px;
height:140px;
border:1px solid silver;
background:#E5E5E5;
}
/*-- end mod : Foxy in a box ----------------------------------------------------------------------*/
#
#-----[ OPEN ]------------------------------------------------
#
templates/subSilver/simple_header.tpl
#
#-----[ FIND ]------------------------------------------------
#
/* General page style. The scroll bar colours only visible in IE5.5+ */
#
#-----[ BEFORE, ADD ]-----------------------------------------
#
/*-- mod : Foxy in a box --------------------------------------------------------------------------*/
/*-- add */
div#private_message{
font:10px Tahoma;
padding:2px;
position:absolute;
top:10%;
left:30%;
width:400px;
height:140px;
border:1px solid silver;
background:#E5E5E5;
}
/*-- end mod : Foxy in a box ----------------------------------------------------------------------*/
#
#-----[ FIND ]------------------------------------------------
#
<body bgcolor="{T_BODY_BGCOLOR}" text="{T_BODY_TEXT}" link="{T_BODY_LINK}" vlink="{T_BODY_VLINK}">
#
#-----[ AFTER, ADD ]------------------------------------------
#
{MSG_BOX}
#
#-----[ OPEN ]------------------------------------------------
#
templates/subSilver/overall_header.tpl
#
#-----[ FIND ]------------------------------------------------
#
/* General page style. The scroll bar colours only visible in IE5.5+ */
#
#-----[ BEFORE, ADD ]-----------------------------------------
#
/*-- mod : Foxy in a box --------------------------------------------------------------------------*/
/*-- add */
div#private_message{
font:10px Tahoma;
padding:2px;
position:absolute;
top:10%;
left:30%;
width:400px;
height:140px;
border:1px solid silver;
background:#E5E5E5;
}
/*-- end mod : Foxy in a box ----------------------------------------------------------------------*/
#
#-----[ FIND ]------------------------------------------------
#
<body bgcolor="{T_BODY_BGCOLOR}" text="{T_BODY_TEXT}" link="{T_BODY_LINK}" vlink="{T_BODY_VLINK}">
#
#-----[ AFTER, ADD ]------------------------------------------
#
{MSG_BOX}
#
#-----[ SAVE/CLOSE ALL FILES ]--------------------------------
#
# EoM