mirror of
https://github.com/phpbb/phpbb.git
synced 2025-05-04 22:58:10 +02:00
hopefully not too late in the game. Checked in new jabber class (the class done by the flyspray project). It would be nice if this could be tested with more servers - jabber.org seems to work fine...
- other fixes git-svn-id: file:///svn/phpbb/trunk@7687 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
parent
fda482ce29
commit
1b32236b1e
@ -38,10 +38,13 @@
|
||||
<dt><label for="jab_password">{L_JAB_PASSWORD}:</label></dt>
|
||||
<dd><input type="password" id="jab_password" name="jab_password" value="{JAB_PASSWORD}" /></dd>
|
||||
</dl>
|
||||
<!-- IF S_CAN_USE_SSL -->
|
||||
<dl>
|
||||
<dt><label for="jab_resource">{L_JAB_RESOURCE}:</label><br /><span>{L_JAB_RESOURCE_EXPLAIN}</span></dt>
|
||||
<dd><input type="text" id="jab_resource" name="jab_resource" value="{JAB_RESOURCE}" /></dd>
|
||||
<dt><label for="jab_use_ssl">{L_JAB_USE_SSL}:</label><br /><span>{L_JAB_USE_SSL_EXPLAIN}</span></dt>
|
||||
<dd><label><input type="radio" class="radio" id="jab_use_ssl" name="jab_use_ssl" value="1"<!-- IF JAB_USE_SSL --> checked="checked"<!-- ENDIF --> /> {L_YES}</label>
|
||||
<label><input type="radio" class="radio" name="jab_use_ssl" value="0"<!-- IF not JAB_USE_SSL --> checked="checked"<!-- ENDIF --> /> {L_NO}</label></dd>
|
||||
</dl>
|
||||
<!-- ENDIF -->
|
||||
<dl>
|
||||
<dt><label for="jab_package_size">{L_JAB_PACKAGE_SIZE}:</label><br /><span>{L_JAB_PACKAGE_SIZE_EXPLAIN}</span></dt>
|
||||
<dd><input type="text" id="jab_package_size" name="jab_package_size" value="{JAB_PACKAGE_SIZE}" maxlength="5" size="5" /></dd>
|
||||
|
@ -173,7 +173,7 @@
|
||||
<tbody>
|
||||
<!-- BEGIN attach -->
|
||||
<!-- IF attach.S_ROW_COUNT is even --><tr class="row1"><!-- ELSE --><tr class="row2"><!-- ENDIF -->
|
||||
<td><a href="{attach.U_DOWNLOAD}">{attach.REAL_FILENAME}</a><br /><span class="small"><!-- IF attach.S_IN_MESSAGE --><strong>{L_PM}: </strong><!-- ELSE --><strong>{L_TOPIC}: </strong><!-- ENDIF --><a href="{attach.U_VIEW_TOPIC}">{attach.TOPIC_TITLE}</a></span></td>
|
||||
<td><a href="{attach.U_DOWNLOAD}">{attach.REAL_FILENAME}</a><br /><span class="small"><!-- IF attach.S_IN_MESSAGE --><strong>{L_PM}: </strong><!-- ELSE --><strong>{L_POST}: </strong><!-- ENDIF --><a href="{attach.U_VIEW_TOPIC}">{attach.TOPIC_TITLE}</a></span></td>
|
||||
<td style="text-align: center">{attach.POST_TIME}</td>
|
||||
<td style="text-align: center">{attach.SIZE}</td>
|
||||
<td style="text-align: center">{attach.DOWNLOAD_COUNT}</td>
|
||||
|
@ -721,7 +721,7 @@ option {
|
||||
}
|
||||
|
||||
option.disabled-option {
|
||||
color: #aaa;
|
||||
color: graytext;
|
||||
}
|
||||
|
||||
.rtl option {
|
||||
|
@ -46,7 +46,7 @@ Smarty (c) 2001, 2002 by ispi of Lincoln, Inc, http://smarty.php.net/
|
||||
|
||||
GPL licenced:
|
||||
phpMyAdmin (c) 2001,2003 phpMyAdmin Devel team, http://www.phpmyadmin.net/
|
||||
Jabber Class (c) 2004 Nathan Fritz, http://cjphp.netflint.net
|
||||
Jabber Class (c) 2006 Flyspray.org, http://www.flyspray.org/
|
||||
Chora (c) 2000-2006, The Horde Project. http://horde.org/chora/
|
||||
Horde Project (c) 2000-2006, The Horde Project. http://horde.org/
|
||||
|
||||
|
@ -218,6 +218,14 @@ p a {
|
||||
<li>[Fix] Do not use the gen_random_string function to create cookie names during install (Bug #11431)</li>
|
||||
<li>[Fix] Send stylesheet in style.php even without a valid session id (Bug #11531)</li>
|
||||
<li>[Fix] request_var should strictly return the requested number of dimensions</li>
|
||||
<li>[Fix] Correct assignment of custom width to $user->img(); / Correctly display poll bars in subsilver2 (Bug #11301)</li>
|
||||
<li>[Fix] Allow removing polls in prosilver</li>
|
||||
<li>{Fix] Correct link to post in managing users attachments (Bug #11765)</li>
|
||||
<li>[Fix] Reload confirm screen for selecting new forum for global topic type change if not postable forum is chosen (Bug #11711)</li>
|
||||
<li>[Fix] Correctly show system default color for disabled options in Internet Explorer which does not support disabled option fields</li>
|
||||
<li>[Fix] Update query for custom profiles in user management used wrong order for left/right delimiter (affecting mssql) (Bug #11781)</li>
|
||||
<li>[Feature] Replaced outdated jabber class with the one from the flyspray project</li>
|
||||
<li>Limit maximum number of allowed characters in messages to 60.000 by default. Admins should increase their PHP time limits if they want to raise this tremedously.</li>
|
||||
</ul>
|
||||
|
||||
</div>
|
||||
|
@ -41,121 +41,59 @@ class acp_jabber
|
||||
$jab_port = request_var('jab_port', $config['jab_port']);
|
||||
$jab_username = request_var('jab_username', $config['jab_username']);
|
||||
$jab_password = request_var('jab_password', $config['jab_password']);
|
||||
$jab_resource = request_var('jab_resource', $config['jab_resource']);
|
||||
$jab_package_size = request_var('jab_package_size', $config['jab_package_size']);
|
||||
$jab_use_ssl = request_var('jab_use_ssl', $config['jab_use_ssl']);
|
||||
|
||||
$jabber = new jabber($jab_host, $jab_port, $jab_username, $jab_password, $jab_resource);
|
||||
$error = array();
|
||||
|
||||
$message = $user->lang['JAB_SETTINGS_CHANGED'];
|
||||
$log = 'JAB_SETTINGS_CHANGED';
|
||||
|
||||
// Are changing (or initialising) a new host or username? If so run some checks and
|
||||
// try to create account if it doesn't exist
|
||||
if ($jab_enable)
|
||||
if ($submit)
|
||||
{
|
||||
if (($jab_host != $config['jab_host'] || $jab_username != $config['jab_username']) && $jab_username)
|
||||
$error = array();
|
||||
|
||||
$message = $user->lang['JAB_SETTINGS_CHANGED'];
|
||||
$log = 'JAB_SETTINGS_CHANGED';
|
||||
|
||||
// Is this feature enabled? Then try to establish a connection
|
||||
if ($jab_enable)
|
||||
{
|
||||
$jabber = new jabber($jab_host, $jab_port, $jab_username, $jab_password);
|
||||
|
||||
if (!$jabber->connect())
|
||||
{
|
||||
trigger_error($user->lang['ERR_JAB_CONNECT'] . $jabber->get_log() . adm_back_link($this->u_action), E_USER_WARNING);
|
||||
}
|
||||
|
||||
// First we'll try to authorise using this account, if that fails we'll try to create it.
|
||||
if (!($result = $jabber->send_auth()))
|
||||
{
|
||||
if (($result = $jabber->account_registration($config['board_email'], $config['sitename'])) <> 2)
|
||||
{
|
||||
$error[] = ($result == 1) ? $user->lang['ERR_JAB_USERNAME'] : sprintf($user->lang['ERR_JAB_REGISTER'], $result);
|
||||
}
|
||||
else
|
||||
{
|
||||
$message = $user->lang['JAB_REGISTERED'];
|
||||
$log = 'JAB_REGISTER';
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
$message = $user->lang['JAB_CHANGED'];
|
||||
$log = 'JAB_CHANGED';
|
||||
}
|
||||
|
||||
sleep(1);
|
||||
$jabber->disconnect();
|
||||
}
|
||||
else if ($jab_password != $config['jab_password'])
|
||||
{
|
||||
if (!$jabber->connect())
|
||||
{
|
||||
trigger_error($user->lang['ERR_JAB_CONNECT'] . $jabber->get_log() . adm_back_link($this->u_action), E_USER_WARNING);
|
||||
}
|
||||
|
||||
if (!$jabber->send_auth())
|
||||
// We'll try to authorise using this account
|
||||
if (!$jabber->login())
|
||||
{
|
||||
trigger_error($user->lang['ERR_JAB_AUTH'] . $jabber->get_log() . adm_back_link($this->u_action), E_USER_WARNING);
|
||||
}
|
||||
$jabber->send_presence(NULL, NULL, 'online');
|
||||
|
||||
if (($result = $jabber->change_password($jab_password)) <> 2)
|
||||
{
|
||||
$error[] = ($result == 1) ? $user->lang['ERR_JAB_PASSCHG'] : sprintf($user->lang['ERR_JAB_PASSFAIL'], $result);
|
||||
}
|
||||
else
|
||||
{
|
||||
$message = $user->lang['JAB_PASS_CHANGED'];
|
||||
$log = 'JAB_PASSCHG';
|
||||
}
|
||||
|
||||
sleep(1);
|
||||
$jabber->disconnect();
|
||||
}
|
||||
}
|
||||
|
||||
// Pull relevant config data
|
||||
$sql = 'SELECT *
|
||||
FROM ' . CONFIG_TABLE . "
|
||||
WHERE config_name LIKE 'jab_%'";
|
||||
$result = $db->sql_query($sql);
|
||||
set_config('jab_enable', $jab_enable);
|
||||
set_config('jab_host', $jab_host);
|
||||
set_config('jab_port', $jab_port);
|
||||
set_config('jab_username', $jab_username);
|
||||
set_config('jab_password', $jab_password);
|
||||
set_config('jab_package_size', $jab_package_size);
|
||||
set_config('jab_use_ssl', $jab_use_ssl);
|
||||
|
||||
while ($row = $db->sql_fetchrow($result))
|
||||
{
|
||||
$config_name = $row['config_name'];
|
||||
$config_value = $row['config_value'];
|
||||
|
||||
$default_config[$config_name] = $config_value;
|
||||
$new[$config_name] = (isset($_POST[$config_name])) ? request_var($config_name, '') : $default_config[$config_name];
|
||||
|
||||
if ($submit && !sizeof($error))
|
||||
{
|
||||
set_config($config_name, $new[$config_name]);
|
||||
}
|
||||
}
|
||||
|
||||
if ($submit && !sizeof($error))
|
||||
{
|
||||
add_log('admin', 'LOG_' . $log);
|
||||
trigger_error($message . adm_back_link($this->u_action));
|
||||
}
|
||||
|
||||
if (sizeof($error))
|
||||
{
|
||||
$template->assign_vars(array(
|
||||
'S_WARNING' => true,
|
||||
'WARNING_MSG' => implode('<br />', $error))
|
||||
);
|
||||
}
|
||||
|
||||
$template->assign_vars(array(
|
||||
'U_ACTION' => $this->u_action,
|
||||
'JAB_ENABLE' => $new['jab_enable'],
|
||||
'JAB_ENABLE' => $jab_enable,
|
||||
'L_JAB_SERVER_EXPLAIN' => sprintf($user->lang['JAB_SERVER_EXPLAIN'], '<a href="http://www.jabber.org/">', '</a>'),
|
||||
'JAB_HOST' => $new['jab_host'],
|
||||
'JAB_PORT' => $new['jab_port'],
|
||||
'JAB_USERNAME' => $new['jab_username'],
|
||||
'JAB_PASSWORD' => $new['jab_password'],
|
||||
'JAB_RESOURCE' => $new['jab_resource'],
|
||||
'JAB_PACKAGE_SIZE' => $new['jab_package_size'])
|
||||
);
|
||||
'JAB_HOST' => $jab_host,
|
||||
'JAB_PORT' => $jab_port,
|
||||
'JAB_USERNAME' => $jab_username,
|
||||
'JAB_PASSWORD' => $jab_password,
|
||||
'JAB_PACKAGE_SIZE' => $jab_package_size,
|
||||
'JAB_USE_SSL' => $jab_use_ssl,
|
||||
'S_CAN_USE_SSL' => jabber::can_use_ssl(),
|
||||
));
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1067,7 +1067,7 @@ class acp_users
|
||||
|
||||
foreach ($cp_data as $key => $value)
|
||||
{
|
||||
$cp_data[$right_delim . $key . $left_delim] = $value;
|
||||
$cp_data[$left_delim . $key . $right_delim] = $value;
|
||||
unset($cp_data[$key]);
|
||||
}
|
||||
|
||||
@ -1616,7 +1616,7 @@ class acp_users
|
||||
}
|
||||
else
|
||||
{
|
||||
$view_topic = append_sid("{$phpbb_root_path}viewtopic.$phpEx", "t={$row['topic_id']}&p={$row['post_msg_id']}#{$row['post_msg_id']}");
|
||||
$view_topic = append_sid("{$phpbb_root_path}viewtopic.$phpEx", "t={$row['topic_id']}&p={$row['post_msg_id']}") . '#p' . $row['post_msg_id'];
|
||||
}
|
||||
|
||||
$template->assign_block_vars('attach', array(
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -458,7 +458,7 @@ class messenger
|
||||
if (!$use_queue)
|
||||
{
|
||||
include_once($phpbb_root_path . 'includes/functions_jabber.' . $phpEx);
|
||||
$this->jabber = new jabber($config['jab_host'], $config['jab_port'], $config['jab_username'], $config['jab_password'], $config['jab_resource']);
|
||||
$this->jabber = new jabber($config['jab_host'], $config['jab_port'], $config['jab_username'], $config['jab_password']);
|
||||
|
||||
if (!$this->jabber->connect())
|
||||
{
|
||||
@ -466,19 +466,17 @@ class messenger
|
||||
return false;
|
||||
}
|
||||
|
||||
if (!$this->jabber->send_auth())
|
||||
if (!$this->jabber->login())
|
||||
{
|
||||
$this->error('JABBER', 'Could not authorise on Jabber server<br />' . $this->jabber->get_log());
|
||||
return false;
|
||||
}
|
||||
$this->jabber->send_presence(NULL, NULL, 'online');
|
||||
|
||||
foreach ($addresses as $address)
|
||||
{
|
||||
$this->jabber->send_message($address, 'normal', NULL, array('body' => $this->msg, 'subject' => $this->subject));
|
||||
$this->jabber->send_message($address, $this->msg, $this->subject);
|
||||
}
|
||||
|
||||
sleep(1);
|
||||
$this->jabber->disconnect();
|
||||
}
|
||||
else
|
||||
@ -592,7 +590,7 @@ class queue
|
||||
}
|
||||
|
||||
include_once($phpbb_root_path . 'includes/functions_jabber.'.$phpEx);
|
||||
$this->jabber = new jabber($config['jab_host'], $config['jab_port'], $config['jab_username'], $config['jab_password'], $config['jab_resource']);
|
||||
$this->jabber = new jabber($config['jab_host'], $config['jab_port'], $config['jab_username'], $config['jab_password']);
|
||||
|
||||
if (!$this->jabber->connect())
|
||||
{
|
||||
@ -600,12 +598,11 @@ class queue
|
||||
continue 2;
|
||||
}
|
||||
|
||||
if (!$this->jabber->send_auth())
|
||||
if (!$this->jabber->login())
|
||||
{
|
||||
messenger::error('JABBER', 'Could not authorise on Jabber server');
|
||||
continue 2;
|
||||
}
|
||||
$this->jabber->send_presence(NULL, NULL, 'online');
|
||||
|
||||
break;
|
||||
|
||||
@ -647,7 +644,7 @@ class queue
|
||||
case 'jabber':
|
||||
foreach ($addresses as $address)
|
||||
{
|
||||
if ($this->jabber->send_message($address, 'normal', NULL, array('body' => $msg, 'subject' => $subject)) === false)
|
||||
if ($this->jabber->send_message($address, $msg, $subject) === false)
|
||||
{
|
||||
messenger::error('JABBER', $this->jabber->get_log());
|
||||
continue 3;
|
||||
@ -669,7 +666,6 @@ class queue
|
||||
case 'jabber':
|
||||
// Hang about a couple of secs to ensure the messages are
|
||||
// handled, then disconnect
|
||||
sleep(1);
|
||||
$this->jabber->disconnect();
|
||||
break;
|
||||
}
|
||||
|
@ -1712,7 +1712,7 @@ class user extends session
|
||||
|
||||
$img_data = &$imgs[$img];
|
||||
|
||||
if (empty($img_data) || $width !== false)
|
||||
if (empty($img_data))
|
||||
{
|
||||
if (!isset($this->img_array[$img]))
|
||||
{
|
||||
@ -1735,7 +1735,7 @@ class user extends session
|
||||
break;
|
||||
|
||||
case 'width':
|
||||
return $img_data['width'];
|
||||
return ($width === false) ? $img_data['width'] : $width;
|
||||
break;
|
||||
|
||||
case 'height':
|
||||
@ -1743,7 +1743,9 @@ class user extends session
|
||||
break;
|
||||
|
||||
default:
|
||||
return '<img src="' . $img_data['src'] . '"' . (($img_data['width']) ? ' width="' . $img_data['width'] . '"' : '') . (($img_data['height']) ? ' height="' . $img_data['height'] . '"' : '') . ' alt="' . $alt . '" title="' . $alt . '" />';
|
||||
$use_width = ($width === false) ? $img_data['width'] : $width;
|
||||
|
||||
return '<img src="' . $img_data['src'] . '"' . (($use_width) ? ' width="' . $use_width . '"' : '') . (($img_data['height']) ? ' height="' . $img_data['height'] . '"' : '') . ' alt="' . $alt . '" title="' . $alt . '" />';
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
@ -592,7 +592,6 @@ if (version_compare($current_version, '3.0.RC1', '<='))
|
||||
AND ug.user_id = u.user_id';
|
||||
$result = $db->sql_query($sql);
|
||||
|
||||
|
||||
while ($row = $db->sql_fetchrow($result))
|
||||
{
|
||||
$bots[] = (int)$row['user_id'];
|
||||
@ -612,6 +611,11 @@ if (version_compare($current_version, '3.0.RC1', '<='))
|
||||
sql_column_change($map_dbms, POSTS_TABLE, 'post_subject', array('XSTEXT_UNI', '', 'true_sort'));
|
||||
}
|
||||
|
||||
$sql = 'DELETE FROM ' . CONFIG_TABLE . " WHERE config_name = 'jab_resource'";
|
||||
_sql($sql, $errored, $error_ary);
|
||||
|
||||
set_config('jab_use_ssl', '0');
|
||||
|
||||
$no_updates = false;
|
||||
}
|
||||
|
||||
|
@ -113,7 +113,7 @@ INSERT INTO phpbb_config (config_name, config_value) VALUES ('jab_host', '');
|
||||
INSERT INTO phpbb_config (config_name, config_value) VALUES ('jab_password', '');
|
||||
INSERT INTO phpbb_config (config_name, config_value) VALUES ('jab_package_size', '20');
|
||||
INSERT INTO phpbb_config (config_name, config_value) VALUES ('jab_port', '5222');
|
||||
INSERT INTO phpbb_config (config_name, config_value) VALUES ('jab_resource', '');
|
||||
INSERT INTO phpbb_config (config_name, config_value) VALUES ('jab_use_ssl', '0');
|
||||
INSERT INTO phpbb_config (config_name, config_value) VALUES ('jab_username', '');
|
||||
INSERT INTO phpbb_config (config_name, config_value) VALUES ('ldap_base_dn', '');
|
||||
INSERT INTO phpbb_config (config_name, config_value) VALUES ('ldap_email', '');
|
||||
@ -148,7 +148,7 @@ INSERT INTO phpbb_config (config_name, config_value) VALUES ('max_login_attempts
|
||||
INSERT INTO phpbb_config (config_name, config_value) VALUES ('max_name_chars', '20');
|
||||
INSERT INTO phpbb_config (config_name, config_value) VALUES ('max_pass_chars', '30');
|
||||
INSERT INTO phpbb_config (config_name, config_value) VALUES ('max_poll_options', '10');
|
||||
INSERT INTO phpbb_config (config_name, config_value) VALUES ('max_post_chars', '0');
|
||||
INSERT INTO phpbb_config (config_name, config_value) VALUES ('max_post_chars', '60000');
|
||||
INSERT INTO phpbb_config (config_name, config_value) VALUES ('max_post_font_size', '200');
|
||||
INSERT INTO phpbb_config (config_name, config_value) VALUES ('max_post_img_height', '0');
|
||||
INSERT INTO phpbb_config (config_name, config_value) VALUES ('max_post_img_width', '0');
|
||||
|
@ -412,32 +412,24 @@ $lang = array_merge($lang, array(
|
||||
|
||||
// Jabber settings
|
||||
$lang = array_merge($lang, array(
|
||||
'ACP_JABBER_SETTINGS_EXPLAIN' => 'Here you can enable and control the use of Jabber for instant messaging and board notifications. Jabber is an open source protocol and therefore available for use by anyone. Some Jabber servers include gateways or transports which allow you to contact users on other networks. Not all servers offer all transports and changes in protocols can prevent transports from operating. Note that it may take several seconds to update Jabber account details, so do not stop the script until it is completed!',
|
||||
'ACP_JABBER_SETTINGS_EXPLAIN' => 'Here you can enable and control the use of Jabber for instant messaging and board notifications. Jabber is an open source protocol and therefore available for use by anyone. Some Jabber servers include gateways or transports which allow you to contact users on other networks. Not all servers offer all transports and changes in protocols can prevent transports from operating. Please be sure to enter already registered account details - phpBB will use the details you enter here as is.',
|
||||
|
||||
'ERR_JAB_AUTH' => 'Could not authorise on Jabber server.',
|
||||
'ERR_JAB_CONNECT' => 'Could not connect to Jabber server.',
|
||||
'ERR_JAB_PASSCHG' => 'Could not change password.',
|
||||
'ERR_JAB_PASSFAIL' => 'Password update failed, %s.',
|
||||
'ERR_JAB_REGISTER' => 'An error occurred trying to register this account, %s.',
|
||||
'ERR_JAB_USERNAME' => 'The username specified already exists, please choose an alternative.',
|
||||
|
||||
'JAB_CHANGED' => 'Jabber account changed successfully.',
|
||||
'JAB_ENABLE' => 'Enable Jabber',
|
||||
'JAB_ENABLE_EXPLAIN' => 'Enables use of Jabber messaging and notifications.',
|
||||
'JAB_PACKAGE_SIZE' => 'Jabber package size',
|
||||
'JAB_PACKAGE_SIZE_EXPLAIN' => 'This is the number of messages sent in one package. If set to 0 the message is sent immediately and is not queued for later sending.',
|
||||
'JAB_PACKAGE_SIZE_EXPLAIN' => 'This is the number of messages sent in one package. If set to 0 the message is sent immediately and will not be queued for later sending.',
|
||||
'JAB_PASSWORD' => 'Jabber password',
|
||||
'JAB_PASS_CHANGED' => 'Jabber password changed successfully.',
|
||||
'JAB_PORT' => 'Jabber port',
|
||||
'JAB_PORT_EXPLAIN' => 'Leave blank unless you know it is not port 5222.',
|
||||
'JAB_REGISTERED' => 'New account registered successfully.',
|
||||
'JAB_RESOURCE' => 'Jabber resource',
|
||||
'JAB_RESOURCE_EXPLAIN' => 'The resource locates this particular connection, e.g. board, home, etc.',
|
||||
'JAB_SERVER' => 'Jabber server',
|
||||
'JAB_SERVER_EXPLAIN' => 'See %sjabber.org%s for a list of servers.',
|
||||
'JAB_SETTINGS_CHANGED' => 'Jabber settings changed successfully.',
|
||||
'JAB_USE_SSL' => 'Use SSL to connect',
|
||||
'JAB_USE_SSL_EXPLAIN' => 'If enabled a secure connection is tried to be established. The Jabber port will be modified to 5223 if port 5222 is specified.',
|
||||
'JAB_USERNAME' => 'Jabber username',
|
||||
'JAB_USERNAME_EXPLAIN' => 'If this user is not registered it will be created if possible.',
|
||||
'JAB_USERNAME_EXPLAIN' => 'Specify a registered username. The username will not be checked for validity.',
|
||||
));
|
||||
|
||||
?>
|
@ -291,7 +291,7 @@ $lang = array_merge($lang, array(
|
||||
'LOGIN_ERROR_PASSWORD_CONVERT' => 'It was not possible to convert your password when updating this bulletin board’s software. Please %srequest a new password%s. If you continue to have problems please contact the %sBoard Administrator%s.',
|
||||
'LOGIN_ERROR_USERNAME' => 'You have specified an incorrect username. Please check your username and try again. If you continue to have problems please contact the %sBoard Administrator%s.',
|
||||
'LOGIN_FORUM' => 'To view or post in this forum you must enter its password.',
|
||||
'LOGIN_INFO' => 'In order to login you must be registered. Registering takes only a few seconds but gives you increased capabilities. The board administrator may also grant additional permissions to registered users. Before you login please ensure you are familiar with our terms of use and related policies. Please ensure you read any forum rules as you navigate around the board.',
|
||||
'LOGIN_INFO' => 'In order to login you must be registered. Registering takes only a few moments but gives you increased capabilities. The board administrator may also grant additional permissions to registered users. Before you register please ensure you are familiar with our terms of use and related policies. Please ensure you read any forum rules as you navigate around the board.',
|
||||
'LOGIN_VIEWFORUM' => 'The board requires you to be registered and logged in to view this forum.',
|
||||
'LOGIN_EXPLAIN_EDIT' => 'In order to edit posts in this forum you have to be registered and logged in.',
|
||||
'LOGOUT' => 'Logout',
|
||||
|
@ -844,7 +844,7 @@ if ($submit || $preview || $refresh)
|
||||
$sql = 'SELECT topic_type, forum_id
|
||||
FROM ' . TOPICS_TABLE . "
|
||||
WHERE topic_id = $topic_id";
|
||||
$result = $db->sql_query_limit($sql, 1);
|
||||
$result = $db->sql_query($sql);
|
||||
$row = $db->sql_fetchrow($result);
|
||||
$db->sql_freeresult($result);
|
||||
|
||||
@ -852,6 +852,21 @@ if ($submit || $preview || $refresh)
|
||||
{
|
||||
$to_forum_id = request_var('to_forum_id', 0);
|
||||
|
||||
if ($to_forum_id)
|
||||
{
|
||||
$sql = 'SELECT forum_type
|
||||
FROM ' . FORUMS_TABLE . '
|
||||
WHERE forum_id = ' . $to_forum_id;
|
||||
$result = $db->sql_query($sql);
|
||||
$forum_type = (int) $db->sql_fetchfield('forum_type');
|
||||
$db->sql_freeresult($result);
|
||||
|
||||
if ($forum_type != FORUM_POST || !$auth->acl_get('f_post', $to_forum_id))
|
||||
{
|
||||
$to_forum_id = 0;
|
||||
}
|
||||
}
|
||||
|
||||
if (!$to_forum_id)
|
||||
{
|
||||
include_once($phpbb_root_path . 'includes/functions_admin.' . $phpEx);
|
||||
|
@ -25,9 +25,9 @@
|
||||
|
||||
<!-- IF not forumrow.S_IS_CAT -->
|
||||
<li class="row">
|
||||
<dl class="icon" style="background-image: url({forumrow.FORUM_FOLDER_IMG_SRC});">
|
||||
<dl class="icon" style="background-image: url({forumrow.FORUM_FOLDER_IMG_SRC}); background-repeat: no-repeat;">
|
||||
<dt>
|
||||
<!-- IF forumrow.FORUM_IMAGE --><div style="float: left; padding-top: 5px; margin-right: 5px;">{forumrow.FORUM_IMAGE}</div><!-- ENDIF -->
|
||||
<!-- IF forumrow.FORUM_IMAGE --><div class="forum-image">{forumrow.FORUM_IMAGE}</div><!-- ENDIF -->
|
||||
<a href="{forumrow.U_VIEWFORUM}" class="forumtitle">{forumrow.FORUM_NAME}</a><br />
|
||||
{forumrow.FORUM_DESC}
|
||||
<!-- IF forumrow.MODERATORS -->
|
||||
|
@ -34,8 +34,8 @@
|
||||
|
||||
<!-- BEGIN topicrow -->
|
||||
<li class="row<!-- IF topicrow.S_ROW_COUNT is odd --> bg1<!-- ELSE --> bg2<!-- ENDIF --><!-- IF topicrow.S_TOPIC_REPORTED --> reported<!-- ENDIF -->">
|
||||
<dl class="icon" style="background-image: url({topicrow.TOPIC_FOLDER_IMG_SRC});">
|
||||
<dt <!-- IF topicrow.TOPIC_ICON_IMG and S_TOPIC_ICONS -->style="background-image: url({T_ICONS_PATH}{topicrow.TOPIC_ICON_IMG});"<!-- ENDIF -->>
|
||||
<dl class="icon" style="background-image: url({topicrow.TOPIC_FOLDER_IMG_SRC}); background-repeat: no-repeat;">
|
||||
<dt <!-- IF topicrow.TOPIC_ICON_IMG and S_TOPIC_ICONS -->style="background-image: url({T_ICONS_PATH}{topicrow.TOPIC_ICON_IMG}); background-repeat: no-repeat;"<!-- ENDIF -->>
|
||||
<!-- IF topicrow.S_SELECT_TOPIC --><a href="{topicrow.U_SELECT_TOPIC}" class="topictitle">[ {L_SELECT_MERGE} ]</a> <!-- ENDIF -->
|
||||
<a href="{topicrow.U_VIEW_TOPIC}" class="topictitle">{topicrow.TOPIC_TITLE}</a>
|
||||
<!-- IF topicrow.S_TOPIC_UNAPPROVED or topicrow.S_POSTS_UNAPPROVED --><a href="{topicrow.U_MCP_QUEUE}">{topicrow.UNAPPROVED_IMG}</a> <!-- ENDIF -->
|
||||
|
@ -11,7 +11,10 @@ function insert_marked(users)
|
||||
{
|
||||
if (typeof(users.length) == "undefined")
|
||||
{
|
||||
insert_user(users.value);
|
||||
if (users.checked)
|
||||
{
|
||||
insert_user(users.value);
|
||||
}
|
||||
}
|
||||
else if (users.length > 0)
|
||||
{
|
||||
|
@ -7,6 +7,12 @@
|
||||
|
||||
<fieldset class="fields2">
|
||||
<!-- IF S_SHOW_POLL_BOX -->
|
||||
<!-- IF S_POLL_DELETE -->
|
||||
<dl>
|
||||
<dt><label for="poll_delete">{L_POLL_DELETE}:</label></dt>
|
||||
<dd><label for="poll_delete"><input type="checkbox" name="poll_delete" id="poll_delete"<!-- IF S_POLL_DELETE_CHECKED --> checked="checked"<!-- ENDIF --> /> </label></dd>
|
||||
</dl>
|
||||
<!-- ENDIF -->
|
||||
<dl>
|
||||
<dt><label for="poll_title">{L_POLL_QUESTION}:</label></dt>
|
||||
<dd><input type="text" name="poll_title" id="poll_title" maxlength="255" value="{POLL_TITLE}" class="inputbox" /></dd>
|
||||
@ -38,10 +44,10 @@
|
||||
</dl>
|
||||
<!-- ENDIF -->
|
||||
|
||||
<!-- ELSE -->
|
||||
<!-- ELSEIF S_POLL_DELETE -->
|
||||
<dl class="fields1">
|
||||
<dt><label for="poll_delete">{L_POLL_DELETE}:</label></dt>
|
||||
<dd><label for="poll_delete"><input type="checkbox" name="poll_delete" id="poll_delete"<!-- IF S_POLL_DELETE_CHECKED --> checked="checked"<!-- ENDIF --> /> {L_DELETE_POST_WARN}</label></dd>
|
||||
<dd><label for="poll_delete"><input type="checkbox" name="poll_delete" id="poll_delete"<!-- IF S_POLL_DELETE_CHECKED --> checked="checked"<!-- ENDIF --> /> </label></dd>
|
||||
</dl>
|
||||
<!-- ENDIF -->
|
||||
</fieldset>
|
||||
|
@ -52,8 +52,8 @@
|
||||
|
||||
<!-- BEGIN searchresults -->
|
||||
<li class="row<!-- IF searchresults.S_ROW_COUNT is even --> bg1<!-- ELSE --> bg2<!-- ENDIF -->">
|
||||
<dl class="icon" style="background-image: url({searchresults.TOPIC_FOLDER_IMG_SRC});">
|
||||
<dt <!-- IF searchresults.TOPIC_ICON_IMG -->style="background-image: url({T_ICONS_PATH}{searchresults.TOPIC_ICON_IMG});"<!-- ENDIF -->>
|
||||
<dl class="icon" style="background-image: url({searchresults.TOPIC_FOLDER_IMG_SRC}); background-repeat: no-repeat;">
|
||||
<dt <!-- IF searchresults.TOPIC_ICON_IMG -->style="background-image: url({T_ICONS_PATH}{searchresults.TOPIC_ICON_IMG}); background-repeat: no-repeat;"<!-- ENDIF -->>
|
||||
<!-- IF searchresults.S_UNREAD_TOPIC --><a href="{searchresults.U_NEWEST_POST}">{NEWEST_POST_IMG}</a> <!-- ENDIF -->
|
||||
<a href="{searchresults.U_VIEW_TOPIC}" class="topictitle">{searchresults.TOPIC_TITLE}</a> {searchresults.ATTACH_ICON_IMG}
|
||||
<!-- IF searchresults.S_TOPIC_UNAPPROVED or searchresults.S_POSTS_UNAPPROVED --><a href="{searchresults.U_MCP_QUEUE}">{searchresults.UNAPPROVED_IMG}</a> <!-- ENDIF -->
|
||||
|
@ -31,8 +31,8 @@
|
||||
<dd class="mark"><input type="checkbox" name="t[{topicrow.TOPIC_ID}]" id="t{topicrow.TOPIC_ID}" /></dd>
|
||||
</dl>
|
||||
<!-- ELSE -->
|
||||
<dl class="icon" style="background-image: url({topicrow.TOPIC_FOLDER_IMG_SRC});">
|
||||
<dt style="<!-- IF topicrow.TOPIC_ICON_IMG -->background-image: url({T_ICONS_PATH}{topicrow.TOPIC_ICON_IMG});<!-- ENDIF -->" title="{topicrow.TOPIC_FOLDER_IMG_ALT}">
|
||||
<dl class="icon" style="background-image: url({topicrow.TOPIC_FOLDER_IMG_SRC}); background-repeat: no-repeat;">
|
||||
<dt style="<!-- IF topicrow.TOPIC_ICON_IMG -->background-image: url({T_ICONS_PATH}{topicrow.TOPIC_ICON_IMG}); background-repeat: no-repeat;<!-- ENDIF -->" title="{topicrow.TOPIC_FOLDER_IMG_ALT}">
|
||||
<!-- IF topicrow.S_UNREAD_TOPIC --><a href="{topicrow.U_NEWEST_POST}">{NEWEST_POST_IMG}</a> <!-- ENDIF --><a href="{topicrow.U_VIEW_TOPIC}" class="topictitle">{topicrow.TOPIC_TITLE}</a>
|
||||
<!-- IF topicrow.S_TOPIC_UNAPPROVED or topicrow.S_POSTS_UNAPPROVED --><a href="{topicrow.U_MCP_QUEUE}">{topicrow.UNAPPROVED_IMG}</a> <!-- ENDIF -->
|
||||
<!-- IF topicrow.S_TOPIC_REPORTED --><a href="{topicrow.U_MCP_REPORT}">{REPORTED_IMG}</a><!-- ENDIF --><br />
|
||||
|
@ -13,8 +13,8 @@
|
||||
<ul class="topiclist cplist">
|
||||
<!-- BEGIN topicrow -->
|
||||
<li class="row<!-- IF topicrow.S_ROW_COUNT is odd --> bg1<!-- ELSE --> bg2<!-- ENDIF -->">
|
||||
<dl class="icon" style="background-image: url({topicrow.TOPIC_FOLDER_IMG_SRC});">
|
||||
<dt <!-- IF topicrow.TOPIC_ICON_IMG -->style="background-image: url({T_ICONS_PATH}{topicrow.TOPIC_ICON_IMG});"<!-- ENDIF -->>
|
||||
<dl class="icon" style="background-image: url({topicrow.TOPIC_FOLDER_IMG_SRC}); background-repeat: no-repeat;">
|
||||
<dt <!-- IF topicrow.TOPIC_ICON_IMG -->style="background-image: url({T_ICONS_PATH}{topicrow.TOPIC_ICON_IMG}); background-repeat: no-repeat;"<!-- ENDIF -->>
|
||||
<!-- IF topicrow.S_UNREAD --><a href="{topicrow.U_NEWEST_POST}">{NEWEST_POST_IMG}</a> <!-- ENDIF --><a href="{topicrow.U_VIEW_TOPIC}" class="topictitle">{topicrow.TOPIC_TITLE}</a><br />
|
||||
<!-- IF topicrow.PAGINATION --><strong class="pagination"><span>{topicrow.PAGINATION}</span></strong><!-- ENDIF -->
|
||||
<!-- IF topicrow.ATTACH_ICON_IMG -->{topicrow.ATTACH_ICON_IMG} <!-- ENDIF -->{L_POST_BY_AUTHOR} {topicrow.TOPIC_AUTHOR_FULL} {L_POSTED_ON_DATE} {topicrow.FIRST_POST_TIME}
|
||||
|
@ -21,7 +21,7 @@
|
||||
|
||||
<!-- BEGIN forumrow -->
|
||||
<li class="row<!-- IF forumrow.S_ROW_COUNT is odd --> bg1<!-- ELSE --> bg2<!-- ENDIF -->">
|
||||
<dl class="icon" style="background-image: url({forumrow.FORUM_FOLDER_IMG_SRC});">
|
||||
<dl class="icon" style="background-image: url({forumrow.FORUM_FOLDER_IMG_SRC}); background-repeat: no-repeat;">
|
||||
<dt><a href="{forumrow.U_VIEWFORUM}" class="forumtitle">{forumrow.FORUM_NAME}</a><br />
|
||||
<!-- IF forumrow.LAST_POST_TIME -->{L_LAST_POST} {L_POST_BY_AUTHOR} <!-- IF forumrow.U_LAST_POST_AUTHOR --><a href="{forumrow.U_LAST_POST_AUTHOR}">{forumrow.LAST_POST_AUTHOR}</a>
|
||||
<!-- ELSE -->{forumrow.LAST_POST_AUTHOR}<!-- ENDIF --> <a href="{forumrow.U_LAST_POST}">{LAST_POST_IMG}</a> {L_POSTED_ON_DATE} {forumrow.LAST_POST_TIME}
|
||||
@ -49,8 +49,8 @@
|
||||
|
||||
<!-- BEGIN topicrow -->
|
||||
<li class="row<!-- IF topicrow.S_TOPIC_REPORTED --> reported<!-- ELSEIF topicrow.S_ROW_COUNT is odd --> bg1<!-- ELSE --> bg2<!-- ENDIF -->">
|
||||
<dl class="icon" style="background-image: url({topicrow.TOPIC_FOLDER_IMG_SRC});">
|
||||
<dt style="<!-- IF topicrow.TOPIC_ICON_IMG -->background-image: url({T_ICONS_PATH}{topicrow.TOPIC_ICON_IMG});<!-- ENDIF -->" title="{topicrow.TOPIC_FOLDER_IMG_ALT}">
|
||||
<dl class="icon" style="background-image: url({topicrow.TOPIC_FOLDER_IMG_SRC}); background-repeat: no-repeat;">
|
||||
<dt style="<!-- IF topicrow.TOPIC_ICON_IMG -->background-image: url({T_ICONS_PATH}{topicrow.TOPIC_ICON_IMG}); background-repeat: no-repeat;<!-- ENDIF -->" title="{topicrow.TOPIC_FOLDER_IMG_ALT}">
|
||||
<!-- IF topicrow.S_UNREAD_TOPIC --><a href="{topicrow.U_NEWEST_POST}">{NEWEST_POST_IMG}</a> <!-- ENDIF --><a href="{topicrow.U_VIEW_TOPIC}" class="topictitle">{topicrow.TOPIC_TITLE}</a>
|
||||
<!-- IF topicrow.S_TOPIC_UNAPPROVED or topicrow.S_POSTS_UNAPPROVED --><a href="{topicrow.U_MCP_QUEUE}">{topicrow.UNAPPROVED_IMG}</a> <!-- ENDIF -->
|
||||
<!-- IF topicrow.S_TOPIC_REPORTED --><a href="{topicrow.U_MCP_REPORT}">{REPORTED_IMG}</a><!-- ENDIF --><br />
|
||||
|
@ -57,8 +57,8 @@
|
||||
|
||||
<!-- BEGIN messagerow -->
|
||||
<li class="row<!-- IF messagerow.S_ROW_COUNT is odd --> bg1<!-- ELSE --> bg2<!-- ENDIF --><!-- IF messagerow.PM_CLASS --> {messagerow.PM_CLASS}<!-- ENDIF -->">
|
||||
<dl class="icon" style="background-image: url({messagerow.FOLDER_IMG_SRC});">
|
||||
<dt<!-- IF messagerow.PM_ICON_URL and S_PM_ICONS --> style="background-image: url({messagerow.PM_ICON_URL});"<!-- ENDIF -->>
|
||||
<dl class="icon" style="background-image: url({messagerow.FOLDER_IMG_SRC}); background-repeat: no-repeat;">
|
||||
<dt<!-- IF messagerow.PM_ICON_URL and S_PM_ICONS --> style="background-image: url({messagerow.PM_ICON_URL}); background-repeat: no-repeat;"<!-- ENDIF -->>
|
||||
|
||||
<!-- IF messagerow.S_PM_DELETED -->
|
||||
<a href="{messagerow.U_REMOVE_PM}" class="topictitle">{L_DELETE_MESSAGE}</a><br />
|
||||
|
@ -65,7 +65,7 @@
|
||||
<dl>
|
||||
<dt><label for="{profile_fields.FIELD_ID}">{profile_fields.LANG_NAME}:<!-- IF profile_fields.S_REQUIRED --> *<!-- ENDIF --></label>
|
||||
<!-- IF profile_fields.LANG_EXPLAIN --><br /><span>{profile_fields.LANG_EXPLAIN}</span><!-- ENDIF -->
|
||||
<!-- IF profile_fields.ERROR --><br /><span style="color:red">{profile_fields.ERROR}</span><!-- ENDIF --></dt>
|
||||
<!-- IF profile_fields.ERROR --><br /><span class="error">{profile_fields.ERROR}</span><!-- ENDIF --></dt>
|
||||
<dd>{profile_fields.FIELD}</dd>
|
||||
</dl>
|
||||
<!-- END profile_fields -->
|
||||
|
@ -137,8 +137,8 @@
|
||||
<!-- ENDIF -->
|
||||
|
||||
<li class="row<!-- IF topicrow.S_ROW_COUNT is even --> bg1<!-- ELSE --> bg2<!-- ENDIF --><!-- IF topicrow.S_POST_ANNOUNCE --> announce<!-- ENDIF --><!-- IF topicrow.S_POST_STICKY --> sticky<!-- ENDIF --><!-- IF topicrow.S_TOPIC_REPORTED --> reported<!-- ENDIF -->">
|
||||
<dl class="icon" style="background-image: url({topicrow.TOPIC_FOLDER_IMG_SRC});">
|
||||
<dt style="<!-- IF topicrow.TOPIC_ICON_IMG and S_TOPIC_ICONS -->background-image: url({T_ICONS_PATH}{topicrow.TOPIC_ICON_IMG});<!-- ENDIF -->" title="{topicrow.TOPIC_FOLDER_IMG_ALT}"><!-- IF topicrow.S_UNREAD_TOPIC --><a href="{topicrow.U_NEWEST_POST}">{NEWEST_POST_IMG}</a> <!-- ENDIF --><a href="{topicrow.U_VIEW_TOPIC}" class="topictitle">{topicrow.TOPIC_TITLE}</a>
|
||||
<dl class="icon" style="background-image: url({topicrow.TOPIC_FOLDER_IMG_SRC}); background-repeat: no-repeat;">
|
||||
<dt style="<!-- IF topicrow.TOPIC_ICON_IMG and S_TOPIC_ICONS -->background-image: url({T_ICONS_PATH}{topicrow.TOPIC_ICON_IMG}); background-repeat: no-repeat;<!-- ENDIF -->" title="{topicrow.TOPIC_FOLDER_IMG_ALT}"><!-- IF topicrow.S_UNREAD_TOPIC --><a href="{topicrow.U_NEWEST_POST}">{NEWEST_POST_IMG}</a> <!-- ENDIF --><a href="{topicrow.U_VIEW_TOPIC}" class="topictitle">{topicrow.TOPIC_TITLE}</a>
|
||||
<!-- IF topicrow.S_TOPIC_UNAPPROVED or topicrow.S_POSTS_UNAPPROVED --><a href="{topicrow.U_MCP_QUEUE}">{topicrow.UNAPPROVED_IMG}</a> <!-- ENDIF -->
|
||||
<!-- IF topicrow.S_TOPIC_REPORTED --><a href="{topicrow.U_MCP_REPORT}">{REPORTED_IMG}</a><!-- ENDIF --><br />
|
||||
<!-- IF topicrow.PAGINATION --><strong class="pagination"><span>{topicrow.PAGINATION}</span></strong><!-- ENDIF -->
|
||||
|
@ -875,6 +875,10 @@ label {
|
||||
color: #425067;
|
||||
}
|
||||
|
||||
option.disabled-option {
|
||||
color: graytext;
|
||||
}
|
||||
|
||||
/* Definition list layout for forms
|
||||
---------------------------------------- */
|
||||
dd label {
|
||||
@ -954,4 +958,4 @@ a.button1:hover, input.button1:hover, a.button2:hover, input.button2:hover, inpu
|
||||
|
||||
input.search {
|
||||
background-image: url("{T_THEME_PATH}/images/icon_textbox_search.gif");
|
||||
}
|
||||
}
|
||||
|
@ -56,6 +56,12 @@ ul.topiclist li.row dt a.subforum {
|
||||
padding: 0 0 0 12px;
|
||||
}
|
||||
|
||||
.forum-image {
|
||||
float: left;
|
||||
padding-top: 5px;
|
||||
margin-right: 5px;
|
||||
}
|
||||
|
||||
li.row {
|
||||
border-top: 1px solid #FFFFFF;
|
||||
border-bottom: 1px solid #8f8f8f;
|
||||
|
@ -32,6 +32,10 @@ option {
|
||||
padding-right: 1em;
|
||||
}
|
||||
|
||||
option.disabled-option {
|
||||
color: graytext;
|
||||
}
|
||||
|
||||
textarea {
|
||||
font-family: "Lucida Grande", Verdana, Helvetica, Arial, sans-serif;
|
||||
width: 60%;
|
||||
|
@ -12,7 +12,10 @@
|
||||
{
|
||||
if (typeof(users.length) == "undefined")
|
||||
{
|
||||
insert_user(users.value);
|
||||
if (users.checked)
|
||||
{
|
||||
insert_user(users.value);
|
||||
}
|
||||
}
|
||||
else if (users.length > 0)
|
||||
{
|
||||
|
@ -482,6 +482,10 @@ option {
|
||||
padding: 0 1em 0 0;
|
||||
}
|
||||
|
||||
option.disabled-option {
|
||||
color: graytext;
|
||||
}
|
||||
|
||||
.rtl option {
|
||||
padding: 0 0 0 1em;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user