-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathshoutbox_send.php
More file actions
61 lines (50 loc) · 1.92 KB
/
shoutbox_send.php
File metadata and controls
61 lines (50 loc) · 1.92 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
<?php
/**
*
* @version $Id: shoutbox_send.php,v 1.0.5 11/02/2006 23:16 PastisD Exp $
* @copyright (c) 2006 PastisD
* @license http://opensource.org/licenses/gpl-license.php GNU Public License
*
* Original author : Malach, http://www.phantasia-fr.com, 2006
*
*/
define('IN_PHPBB', true);
$phpbb_root_path = './';
$phpEx = substr(strrchr(__FILE__, '.'), 1);
include($phpbb_root_path . 'common.'.$phpEx);
include($get->url('includes/functions_post'));
$userdata = session_pagestart($user_ip, PAGE_INDEX);
init_userprefs($userdata);
$hide_txt = '<a href="' . append_sid('shoutbox_send.'.$phpEx) . '?mode=hide">' . $lang['sb_hide'] . '</a>';
if ( isset($HTTP_GET_VARS['mode']) || isset($HTTP_POST_VARS['mode']) )
{
$mode = ( isset($HTTP_GET_VARS['mode']) ) ? $HTTP_GET_VARS['mode'] : $HTTP_POST_VARS['mode'];
}
if ( $mode == 'hide' )
{
@setcookie('shoutbox',off , (time()+3600*9000), $board_config['cookie_path'], $board_config['cookie_domain'], $board_config['cookie_secure']);
$hide_txt = $lang['sb_hide_done'];
}
$template->set_filenames(array('body' => 'shoutbox_send_body.tpl'));
generate_smilies('inline', PAGE_INDEX);
$template->assign_vars(array(
'S_CONTENT_ENCODING' => $lang['ENCODING'],
'L_SEND' => $lang['Submit'],
'L_GG_MES' => $lang['gg_mes'],
'NICK' => $userdata['username'],
'U_MORE_SMILIES' => append_sid('posting.'.$phpEx . '?mode=smilies'),
'MAXLENGHT' => $board_config['shoutbox_text_lenght'],
'SB_USER_ID' => $userdata['user_id'],
'SB_HIDE' => $hide_txt,
'GO' => $images['icon_go'],
//-- mod : rank color system ---------------------------------------------------
//-- add
'T_TEMPLATE_NAME' => $theme['template_name'],
//-- fin mod : rank color system -----------------------------------------------
'REFRESH' => $images['icon_refresh'],
'SMILIES' => $images['icon_smilies'],
'SHOUTBOX_ACTION' => append_sid('shoutbox_view.'.$phpEx),
'T_HEAD_STYLESHEET' => $theme['head_stylesheet']
));
$template->pparse('body');
?>