Skip to content

Commit

Permalink
Merge pull request #76 from Galixte/master
Browse files Browse the repository at this point in the history
pdate to 3.0.26 + Update the FRENCH translation
  • Loading branch information
LMOspaceace committed May 16, 2019
2 parents 4cd8318 + f5052d5 commit 1c12c87
Show file tree
Hide file tree
Showing 26 changed files with 59 additions and 607 deletions.
4 changes: 1 addition & 3 deletions adm/style/ajax_chat.html
Expand Up @@ -10,12 +10,10 @@

<a id="maincontent"></a>

<h1>{{ lang('ACP_AJAX_CHAT') }}</h1>
<h1>{{ lang('ACP_AJAX_CHAT') }} {{ AJAX_CHAT_VERSION }}</h1>

<p>{{ lang('ACP_AJAX_CHAT_EXPLAIN') }}</p>

<img style="float: {{ S_CONTENT_FLOW_END }};" src="https://img.shields.io/badge/{{ lang('VERSION') }}-{{ AJAX_CHAT_VERSION }}-blue.svg?style=plastic" /><br />

{% if S_ERROR %}
<div class="errorbox">
<h3>{{ lang('WARNING') }}</h3>
Expand Down
25 changes: 14 additions & 11 deletions composer.json
@@ -1,12 +1,13 @@
{
"name": "spaceace/ajaxchat",
"type": "phpbb-extension",
"description": "Chat for phpBB 3.1",
"homepage": "http://www.livemembersonly.com",
"version": "3.0.25",
"time": "2017-08-23",
"description": "Chat for phpBB 3.1 and 3.2",
"homepage": "https://www.livemembersonly.com",
"version": "3.0.26",
"time": "2017-09-24",
"license": "GPL-2.0",
"authors": [{
"authors": [
{
"name": "spaceace",
"email": "spaceace@livemembersonly.com",
"homepage": "https://www.livemembersonly.com",
Expand All @@ -22,10 +23,12 @@
"email": "royk@myraytech.net",
"homepage": "https://myraytech.net",
"role": "Extension Co-Developer"
}],
}
],
"require": {
"php": ">= 5.4",
"phpbb/phpbb": ">=3.1.0,<3.3"
"phpbb/phpbb": ">=3.1.0,<3.3",
"composer/installers": "~1.0.0"
},
"require-dev": {
"phpbb/epv": "dev-master",
Expand All @@ -37,9 +40,9 @@
"phpbb/phpbb": ">=3.1.0,<3.3"
},
"version-check": {
"host": "www.livemembersonly.com",
"directory": "/version",
"filename": "ajaxchat.json"
"host": "www.phpbb.com",
"directory": "/customise/db/extension/ajax_chat",
"filename": "version_check"
}
}
}
}
32 changes: 1 addition & 31 deletions controller/chat.php
Expand Up @@ -71,7 +71,7 @@ class chat
/** @var core.php_ext */
protected $php_ext;

/** @var core.php_ext */
/* @var string table_prefix */
protected $table_prefix;

/** @var int */
Expand Down Expand Up @@ -341,11 +341,6 @@ public function defaultAction($page)

foreach ($rows as $row)
{
/*if ($row['forum_id'] && !$row['post_visibility'] == ITEM_APPROVED && !$this->auth->acl_get('m_approve', $row['forum_id']))
{
continue;
}*/

if ($row['forum_id'] && !$this->auth->acl_get('f_read', $row['forum_id']))
{
continue;
Expand Down Expand Up @@ -499,11 +494,6 @@ public function readAction()

foreach ($rows as $row)
{
/*if ($row['forum_id'] && !$row['post_visibility'] == ITEM_APPROVED && !$this->auth->acl_get('m_approve', $row['forum_id']))
{
continue;
}*/

if ($row['forum_id'] && !$this->auth->acl_get('f_read', $row['forum_id']))
{
continue;
Expand Down Expand Up @@ -611,14 +601,6 @@ public function editAction($chat_id)
$row = $this->db->sql_fetchrow($result);
$this->db->sql_freeresult($result);

/*
, p.post_visibility
LEFT JOIN ' . $this->posts_table . ' as p ON c.post_id = p.post_id
if ($row['forum_id'] && !$row['post_visibility'] == ITEM_APPROVED && !$this->auth->acl_get('m_approve', $row['forum_id']))
{
return;
}*/

if ($row['forum_id'] && !$this->auth->acl_get('f_read', $row['forum_id']))
{
throw new http_exception(403, 'NO_EDIT_PERMISSION');
Expand Down Expand Up @@ -741,16 +723,6 @@ public function addAction()

foreach ($rows as $row)
{
/*if ($row['forum_id'] && !$row['post_visibility'] == ITEM_APPROVED && !$this->auth->acl_get('m_approve', $row['forum_id']))
{
continue;
}
if ($row['forum_id'] && !$this->auth->acl_get('f_read', $row['forum_id']))
{
continue;
}*/

if ($this->count++ == 0)
{
$this->last_id = $row['message_id'];
Expand Down Expand Up @@ -845,8 +817,6 @@ public function get_chat_rows_sql()
LEFT JOIN ' . $this->users_table . ' as u ON c.user_id = u.user_id
WHERE c.message_id > ' . (int) $this->last_id . '
ORDER BY c.message_id DESC';
//, p.post_visibility
//LEFT JOIN ' . $this->posts_table . ' as p ON c.post_id = p.post_id
return $sql;
}

Expand Down
10 changes: 5 additions & 5 deletions core/acp_manager.php
Expand Up @@ -48,7 +48,7 @@ public function move($action)
}

$sql = 'UPDATE ' . BBCODES_TABLE . '
SET bbcode_order = ' . $order . '
SET bbcode_order = ' . (int) $order . '
WHERE bbcode_id = ' . (int) $bbcode_id;
$this->db->sql_query($sql);
}
Expand Down Expand Up @@ -130,10 +130,10 @@ public function install_bbcodes($bbcode_data)
'second_pass_replace' => $data['second_pass_replace']
);

$sql = 'SELECT bbcode_id
$sql = 'SELECT bbcode_id
FROM ' . BBCODES_TABLE . "
WHERE LOWER(bbcode_tag) = '" . strtolower($bbcode_name) . "'
OR LOWER(bbcode_tag) = '" . strtolower($bbcode_array['bbcode_tag']) . "'";
WHERE LOWER(bbcode_tag) = '" . $this->db->sql_escape(strtolower($bbcode_name)) . "'
OR LOWER(bbcode_tag) = '" . $this->db->sql_escape(strtolower($bbcode_array['bbcode_tag'])) . "'";
$result = $this->db->sql_query($sql);
$row_exists = $this->db->sql_fetchrow($result);
$this->db->sql_freeresult($result);
Expand All @@ -144,7 +144,7 @@ public function install_bbcodes($bbcode_data)

$sql = 'UPDATE ' . BBCODES_TABLE . '
SET ' . $this->db->sql_build_array('UPDATE', $bbcode_array) . '
WHERE bbcode_id = ' . $bbcode_id;
WHERE bbcode_id = ' . (int) $bbcode_id;
$this->db->sql_query($sql);
}
else
Expand Down
2 changes: 1 addition & 1 deletion ext.php
Expand Up @@ -16,7 +16,7 @@
*/
class ext extends \phpbb\extension\base
{
const AJAX_CHAT_VERSION = '3.0.25';
const AJAX_CHAT_VERSION = '3.0.26';

public function is_enableable()
{
Expand Down
1 change: 0 additions & 1 deletion language/en/info_acp_ajax_chat.php
Expand Up @@ -62,7 +62,6 @@
'CHAT_AMOUNT_AJAX_CHAT' => 'Chat messages',
'CHAT_AMOUNT_AJAX_CHAT_EXPLAIN' => 'Amount of chat messages to display. Between 5 and 150. Default is 60.',
'AJAX_CHAT_RULES' => 'Chat rules',
'RULES_AJAX_CHAT' => 'Insert a simple rule for chat',
'RULES_AJAX_CHAT_EXPLAIN' => 'You are able to enter the rules for chat here. Or you can enter a URL of a page/post containing your chat rules.',
'AJAX_CHAT_LOCATION' => 'Chat location',
'LOCATION_AJAX_CHAT_OVERRIDE' => 'Override user’s chat position',
Expand Down
2 changes: 1 addition & 1 deletion language/en/info_ucp_ajax_chat.php
Expand Up @@ -34,7 +34,7 @@
// in a url you again do not need to specify an order e.g., 'Click %sHERE%s' is fine
//
// Some characters you may want to copy&paste:
// ’ « » “ ” …
// ’ « » “ ” …
//

$lang = array_merge(
Expand Down
6 changes: 3 additions & 3 deletions language/fr/ajax_chat.php
Expand Up @@ -2,10 +2,10 @@
/**
*
* Ajax Chat. An extension for the phpBB Forum Software package.
* French translation by stratege1401 (http://www.forum.fasx.org/phpbb/) & Galixte (http://www.galixte.com)
* French translation by stratege1401 (http://www.forum.fasx.org/phpbb/) & by Galixte (http://www.galixte.com)
*
* @copyright (c) 2017 spaceace <http://www.livemembersonly.com>
* @license GNU General Public License, version 2 (GPL-2.0)
* @copyright (c) 2018 spaceace <http://www.livemembersonly.com>
* @license GNU General Public License, version 2 (GPL-2.0-only)
*
*/

Expand Down
7 changes: 3 additions & 4 deletions language/fr/info_acp_ajax_chat.php
Expand Up @@ -2,10 +2,10 @@
/**
*
* Ajax Chat. An extension for the phpBB Forum Software package.
* French translation by stratege1401 (http://www.forum.fasx.org/phpbb/) & Galixte (http://www.galixte.com)
* French translation by stratege1401 (http://www.forum.fasx.org/phpbb/) & by Galixte (http://www.galixte.com)
*
* @copyright (c) 2017 spaceace <http://www.livemembersonly.com>
* @license GNU General Public License, version 2 (GPL-2.0)
* @copyright (c) 2018 spaceace <http://www.livemembersonly.com>
* @license GNU General Public License, version 2 (GPL-2.0-only)
*
*/

Expand Down Expand Up @@ -63,7 +63,6 @@
'CHAT_AMOUNT_AJAX_CHAT' => 'Messages de la messagerie instantanée',
'CHAT_AMOUNT_AJAX_CHAT_EXPLAIN' => 'Nombres des messages à afficher sur la page dédiée à la messagerie instantanée. Entre 5 et 150, et par défaut à 60.',
'AJAX_CHAT_RULES' => 'Règles de la messagerie instantanée',
'RULES_AJAX_CHAT' => 'Définir une règle simple',
'RULES_AJAX_CHAT_EXPLAIN' => 'Permet de saisir les règles pour la messagerie instantanée. Il est possible de saisir une adresse URL vers un sujet stipulant vos règles, telle que : page/message-contenant-vos-regles.',
'AJAX_CHAT_LOCATION' => 'Emplacement de la messagerie instantanée',
'LOCATION_AJAX_CHAT_OVERRIDE' => 'Outrepasser le choix de l’emplacement sur la page « Index »',
Expand Down
6 changes: 3 additions & 3 deletions language/fr/info_ucp_ajax_chat.php
Expand Up @@ -2,10 +2,10 @@
/**
*
* Ajax Chat. An extension for the phpBB Forum Software package.
* French translation by stratege1401 (http://www.forum.fasx.org/phpbb/) & Galixte (http://www.galixte.com)
* French translation by stratege1401 (http://www.forum.fasx.org/phpbb/) & by Galixte (http://www.galixte.com)
*
* @copyright (c) 2017 spaceace <http://www.livemembersonly.com>
* @license GNU General Public License, version 2 (GPL-2.0)
* @copyright (c) 2018 spaceace <http://www.livemembersonly.com>
* @license GNU General Public License, version 2 (GPL-2.0-only)
*
*/

Expand Down
79 changes: 0 additions & 79 deletions language/nl/ajax_chat.php

This file was deleted.

0 comments on commit 1c12c87

Please sign in to comment.