Compare commits
114 Commits
v2.1.0-RC2
...
v2.1.0-RC3
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
44a1937237 | ||
|
|
5899c9e7a5 | ||
|
|
072957b6ec | ||
|
|
76003767d5 | ||
|
|
229033a618 | ||
|
|
85337f9a09 | ||
|
|
3e0ec62751 | ||
|
|
2239850ba9 | ||
|
|
6cd36b4b13 | ||
|
|
5678dd2251 | ||
|
|
b4f68afd3c | ||
|
|
1f6ddc245e | ||
|
|
92a960ebd5 | ||
|
|
9d0146918d | ||
|
|
d699ef0e3b | ||
|
|
6767c6406b | ||
|
|
33a96b967b | ||
|
|
7e4a6468a2 | ||
|
|
5007b9ee35 | ||
|
|
8c0c123627 | ||
|
|
605c7bc41f | ||
|
|
0123621025 | ||
|
|
3f2e5d56a6 | ||
|
|
dd43a8364c | ||
|
|
6c8b63db06 | ||
|
|
7e0034cd1a | ||
|
|
112b7d2db7 | ||
|
|
9792360f03 | ||
|
|
4d042239d6 | ||
|
|
2a5d91b474 | ||
|
|
61782b6e77 | ||
|
|
39482d5441 | ||
|
|
6835979dbf | ||
|
|
2dd46f61b6 | ||
|
|
24f18700bb | ||
|
|
01cb85005a | ||
|
|
1a4587a2a3 | ||
|
|
eb24ba1425 | ||
|
|
c0430bb20e | ||
|
|
08a4d74937 | ||
|
|
f8de6be004 | ||
|
|
cd4e7e2993 | ||
|
|
22e48beb8f | ||
|
|
545f7af4de | ||
|
|
53a9dbf5dd | ||
|
|
9ca1e197ee | ||
|
|
131b7a691d | ||
|
|
c3e1128ad6 | ||
|
|
2d5a14db22 | ||
|
|
4134f59a15 | ||
|
|
1a74082154 | ||
|
|
9fe7e17124 | ||
|
|
726f94e798 | ||
|
|
1e405e9d91 | ||
|
|
42973b1a10 | ||
|
|
a699a92e31 | ||
|
|
22ef20d0e7 | ||
|
|
a9c5913c1f | ||
|
|
74adacbe1f | ||
|
|
e2c85346b0 | ||
|
|
7129e5e2a2 | ||
|
|
af21b2edc4 | ||
|
|
f65f132649 | ||
|
|
7ac5201425 | ||
|
|
6488dd8d0c | ||
|
|
df854fe083 | ||
|
|
36db7c0b28 | ||
|
|
3c23f6b405 | ||
|
|
de98a00df5 | ||
|
|
96b31e8abb | ||
|
|
dec789fef7 | ||
|
|
3e18e50f89 | ||
|
|
53eb8ebe02 | ||
|
|
9551290fcf | ||
|
|
e838684ae5 | ||
|
|
b68bb7f4a6 | ||
|
|
119855aedf | ||
|
|
5b6b6740ca | ||
|
|
3ab38cdf31 | ||
|
|
5c79d9452a | ||
|
|
ce17432e78 | ||
|
|
7b9380360c | ||
|
|
a8655fc78d | ||
|
|
d16acc444b | ||
|
|
76c5f62cbd | ||
|
|
faedc2bd25 | ||
|
|
cfa2657da4 | ||
|
|
8e85752c65 | ||
|
|
9899d4fd3c | ||
|
|
1e7dc9b576 | ||
|
|
30bd67f3d8 | ||
|
|
311c7cb97f | ||
|
|
f75dd66601 | ||
|
|
0ea8d11360 | ||
|
|
70efdf099e | ||
|
|
bc3b430569 | ||
|
|
ee096bf60d | ||
|
|
f2b002c49b | ||
|
|
a50e6c04d0 | ||
|
|
e4861caed8 | ||
|
|
7a63c9a3a8 | ||
|
|
2397563b9a | ||
|
|
ce42fb4fb8 | ||
|
|
b98c6fed23 | ||
|
|
8d38348f15 | ||
|
|
64eb8f871a | ||
|
|
6614a7c320 | ||
|
|
9bf8fd049d | ||
|
|
6e6e3c504b | ||
|
|
e3163df594 | ||
|
|
3713332da0 | ||
|
|
68af642d73 | ||
|
|
f4ce532f69 | ||
|
|
2c62ff85a9 |
3
.gitattributes
vendored
@@ -8,5 +8,4 @@ phpunit.xml.* export-ignore
|
||||
README.md export-ignore
|
||||
git-tools/ export-ignore
|
||||
.coveralls.yml export-ignore
|
||||
composer.phar export-ignore
|
||||
composer.lock export-ignore
|
||||
build.xml export-ignore
|
||||
|
||||
1
.gitignore
vendored
@@ -1,3 +1,4 @@
|
||||
/.idea/*
|
||||
/tests/test_config.php
|
||||
/vendor/
|
||||
/build/
|
||||
|
||||
@@ -22,8 +22,11 @@ matrix:
|
||||
env: DB=mysqli
|
||||
- php: hhvm
|
||||
env: DB=mysqli
|
||||
- php: 7.0
|
||||
env: DB=mysqli
|
||||
allow_failures:
|
||||
- php: hhvm
|
||||
- php: 7.0
|
||||
fast_finish: true
|
||||
|
||||
env:
|
||||
@@ -34,11 +37,11 @@ env:
|
||||
- COVERAGE="1" # Should we send coverage?
|
||||
- EPV="1" # Should we run EPV (Extension Pre Validator) on your code?
|
||||
- SPELLCHECK="1" # Should the php files be checked for obvious spelling errors?
|
||||
- PHPBB_BRANCH="develop-ascraeus"
|
||||
- PHPBB_BRANCH="3.1.x"
|
||||
|
||||
branches:
|
||||
except:
|
||||
- master
|
||||
- 2.0.x
|
||||
- develop-1_0_X
|
||||
|
||||
install:
|
||||
|
||||
@@ -17,7 +17,7 @@ The extension is currently under heavy development and not supported until furth
|
||||
## AUTOMATED TESTING
|
||||
|
||||
We are starting to have unit and functional tests in order to prevent regressions. You can check our travis build below.
|
||||
develop-2.1.x - [](https://travis-ci.org/board3/Board3-Portal)
|
||||
2.1.x - [](https://travis-ci.org/board3/Board3-Portal)
|
||||
[](https://scrutinizer-ci.com/g/board3/Board3-Portal/?branch=develop-2.1.x)
|
||||
[](https://scrutinizer-ci.com/g/board3/Board3-Portal/?branch=develop-2.1.x)
|
||||
|
||||
|
||||
@@ -26,6 +26,9 @@ class portal_module
|
||||
/** @var \board3\portal\portal\modules\constraints_handler */
|
||||
protected $modules_constraints;
|
||||
|
||||
/** @var \board3\portal\controller\helper */
|
||||
protected $board3_controller_helper;
|
||||
|
||||
/** @var int Board3 module enabled */
|
||||
const B3_MODULE_ENABLED = 1;
|
||||
|
||||
@@ -55,8 +58,13 @@ class portal_module
|
||||
$this->portal_columns = $this->phpbb_container->get('board3.portal.columns');
|
||||
$this->modules_manager = $this->phpbb_container->get('board3.portal.modules.manager');
|
||||
$this->modules_constraints = $this->phpbb_container->get('board3.portal.modules.constraints_handler');
|
||||
$this->board3_controller_helper = $this->phpbb_container->get('board3.portal.controller_helper');
|
||||
|
||||
if (!defined('PORTAL_MODULES_TABLE'))
|
||||
{
|
||||
define('PORTAL_MODULES_TABLE', $this->phpbb_container->getParameter('board3.portal.modules.table'));
|
||||
define('PORTAL_CONFIG_TABLE', $this->phpbb_container->getParameter('board3.portal.config.table'));
|
||||
}
|
||||
|
||||
if(!function_exists('obtain_portal_config'))
|
||||
{
|
||||
@@ -97,6 +105,10 @@ class portal_module
|
||||
'legend2' => 'ACP_PORTAL_COLUMN_WIDTH_SETTINGS',
|
||||
'board3_left_column_width' => array('lang' => 'PORTAL_LEFT_COLUMN_WIDTH', 'validate' => 'int', 'type' => 'text:3:3', 'explain' => true),
|
||||
'board3_right_column_width' => array('lang' => 'PORTAL_RIGHT_COLUMN_WIDTH', 'validate' => 'int', 'type' => 'text:3:3', 'explain' => true),
|
||||
|
||||
'legend3' => 'ACP_PORTAL_SHOW_ALL',
|
||||
'board3_show_all_pages' => array('lang' => 'ACP_PORTAL_SHOW_ALL', 'validate' => 'bool', 'type' => 'radio:yes_no', 'explain' => true),
|
||||
'board3_show_all_side' => array('lang' => 'PORTAL_SHOW_ALL_SIDE', 'validate' => 'bool', 'type' => 'custom', 'method' => array('board3.portal.modules_helper', 'display_left_right'), 'submit' => array('board3.portal.modules_helper', 'store_left_right'), 'explain' => true),
|
||||
)
|
||||
);
|
||||
|
||||
@@ -118,10 +130,9 @@ class portal_module
|
||||
continue;
|
||||
}
|
||||
|
||||
if ($this->c_class->get_language())
|
||||
{
|
||||
$this->user->add_lang_ext('board3/portal', 'modules/' . $this->c_class->get_language());
|
||||
}
|
||||
// Load module language
|
||||
$this->board3_controller_helper->load_module_language($this->c_class);
|
||||
|
||||
$module_name = $this->user->lang[$this->c_class->get_name()];
|
||||
$display_vars = $this->c_class->get_template_acp($module_id);
|
||||
$this->template->assign_vars(array(
|
||||
@@ -129,7 +140,7 @@ class portal_module
|
||||
'MODULE_IMAGE' => $module_data['module_image_src'],
|
||||
'MODULE_IMAGE_WIDTH' => $module_data['module_image_width'],
|
||||
'MODULE_IMAGE_HEIGHT' => $module_data['module_image_height'],
|
||||
'MODULE_IMAGE_SRC' => ($module_data['module_image_src']) ? $this->root_path . 'styles/' . $this->user->style['style_path'] . '/theme/images/portal/' . $module_data['module_image_src'] : '',
|
||||
'MODULE_IMAGE_SRC' => ($module_data['module_image_src']) ? $this->root_path . 'styles/all/theme/images/portal/' . $module_data['module_image_src'] : '',
|
||||
'MODULE_ENABLED' => ($module_data['module_status']) ? true : false,
|
||||
'MODULE_SHOW_IMAGE' => (in_array($this->portal_columns->number_to_string($module_data['module_column']), array('center', 'top', 'bottom'))) ? false : true,
|
||||
));
|
||||
@@ -215,11 +226,11 @@ class portal_module
|
||||
if ($null['submit'][0] == 'board3.portal.modules_helper')
|
||||
{
|
||||
$func = array($this->modules_helper, $null['submit'][1]);
|
||||
$args = ($module_id != 0) ? array($config_name, $module_id) : $config_name;
|
||||
$args = ($module_id != 0) ? array($config_name, $module_id) : array($config_name);
|
||||
}
|
||||
else
|
||||
{
|
||||
$args = ($module_id != 0) ? array($cfg_array[$config_name], $config_name, $module_id) : $config_name;
|
||||
$args = ($module_id != 0) ? array($cfg_array[$config_name], $config_name, $module_id) : array($config_name);
|
||||
$func = $null['submit'];
|
||||
}
|
||||
}
|
||||
@@ -285,7 +296,7 @@ class portal_module
|
||||
WHERE module_id = ' . (int) $module_id;
|
||||
$this->db->sql_query($sql);
|
||||
|
||||
$this->cache->destroy('portal_modules');
|
||||
$this->cache->destroy('sql', PORTAL_MODULES_TABLE);
|
||||
$this->cache->destroy('sql', CONFIG_TABLE);
|
||||
|
||||
if(isset($module_name))
|
||||
@@ -299,7 +310,7 @@ class portal_module
|
||||
{
|
||||
$this->log->add('admin', $this->user->data['user_id'], $this->user->data['user_ip'], 'LOG_PORTAL_CONFIG', false, array($this->user->lang['ACP_PORTAL_' . strtoupper($mode) . '_INFO']));
|
||||
}
|
||||
trigger_error($this->user->lang['CONFIG_UPDATED'] . ((!empty($img_error) ? '<br /><br />' . $this->user->lang['MODULE_IMAGE_ERROR'] . '<br />' . $img_error : '')) . adm_back_link(($module_id) ? append_sid("{$this->phpbb_root_path}adm/index.{$this->php_ext}", 'i=\board3\portal\acp\portal_module&mode=modules') : $this->u_action));
|
||||
trigger_error($this->user->lang['CONFIG_UPDATED'] . ((!empty($img_error) ? '<br /><br />' . $this->user->lang['MODULE_IMAGE_ERROR'] . '<br />' . $img_error : '')) . adm_back_link(($module_id) ? append_sid("{$this->phpbb_admin_path}index.{$this->php_ext}", 'i=\board3\portal\acp\portal_module&mode=modules') : $this->u_action));
|
||||
}
|
||||
|
||||
// show custom HTML files on the settings page of the modules instead of the standard board3 portal one, if chosen by module
|
||||
@@ -534,10 +545,9 @@ class portal_module
|
||||
|
||||
if ($module->get_allowed_columns() & $this->portal_columns->string_to_constant($add_module))
|
||||
{
|
||||
if ($module->get_language())
|
||||
{
|
||||
$this->user->add_lang_ext('board3/portal', 'modules/' . $module->get_language());
|
||||
}
|
||||
// Load module language
|
||||
$this->board3_controller_helper->load_module_language($module);
|
||||
|
||||
$fileinfo[] = array(
|
||||
'module' => $module_class,
|
||||
'name' => $this->user->lang[$module->get_name()],
|
||||
@@ -597,10 +607,9 @@ class portal_module
|
||||
continue;
|
||||
}
|
||||
|
||||
if ($this->c_class->get_language())
|
||||
{
|
||||
$this->user->add_lang_ext('board3/portal', 'modules/' . $this->c_class->get_language());
|
||||
}
|
||||
// Load module language
|
||||
$this->board3_controller_helper->load_module_language($this->c_class);
|
||||
|
||||
$template_column = $this->portal_columns->number_to_string($row['module_column']);
|
||||
|
||||
// find out of we can move modules to the left or right
|
||||
@@ -666,7 +675,7 @@ class portal_module
|
||||
|
||||
$this->template->assign_block_vars('modules_' . $template_column, array(
|
||||
'MODULE_NAME' => (isset($this->user->lang[$row['module_name']])) ? $this->user->lang[$row['module_name']] : $row['module_name'],
|
||||
'MODULE_IMAGE' => ($row['module_image_src']) ? '<img src="' . $this->root_path . 'styles/' . $this->user->style['style_path'] . '/theme/images/portal/' . $row['module_image_src'] . '" alt="' . $row['module_name'] . '" />' : '',
|
||||
'MODULE_IMAGE' => ($row['module_image_src']) ? '<img src="' . $this->root_path . 'styles/all/theme/images/portal/' . $row['module_image_src'] . '" alt="' . $row['module_name'] . '" />' : '',
|
||||
'MODULE_ENABLED' => ($row['module_status']) ? true : false,
|
||||
|
||||
'U_DELETE' => $this->modules_manager->get_module_link('modules', $row['module_id']) . '&action=delete&module_classname=' . $row['module_classname'],
|
||||
@@ -683,6 +692,7 @@ class portal_module
|
||||
'ICON_MOVE_LEFT_DISABLED' => '<img src="' . $this->root_path . 'adm/images/icon_left_disabled.gif" alt="' . $this->user->lang['MOVE_LEFT'] . '" title="' . $this->user->lang['MOVE_LEFT'] . '" />',
|
||||
'ICON_MOVE_RIGHT' => '<img src="' . $this->root_path . 'adm/images/icon_right.gif" alt="' . $this->user->lang['MOVE_RIGHT'] . '" title="' . $this->user->lang['MOVE_RIGHT'] . '" />',
|
||||
'ICON_MOVE_RIGHT_DISABLED' => '<img src="' . $this->root_path . 'adm/images/icon_right_disabled.gif" alt="' . $this->user->lang['MOVE_RIGHT'] . '" title="' . $this->user->lang['MOVE_RIGHT'] . '" />',
|
||||
'B3P_U_ACTION' => $this->modules_manager->get_module_link('modules', $module_id),
|
||||
));
|
||||
}
|
||||
|
||||
|
||||
@@ -45,7 +45,7 @@
|
||||
<h1>{L_ACP_PORTAL_MODULES}</h1>
|
||||
<p>{L_ACP_PORTAL_MODULES_EXP}</p>
|
||||
|
||||
<form id="acp_portal_modules" method="post" action="{U_ACTION}" data-ajax="true">
|
||||
<form id="acp_portal_modules" method="post" action="{B3P_U_ACTION}" data-ajax="true">
|
||||
<fieldset class="tabulated">
|
||||
<legend>{L_ACP_PORTAL_MODULES}</legend>
|
||||
|
||||
|
||||
134
build.xml
Normal file
@@ -0,0 +1,134 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project name="Extension Builder" description="Builds an extension.zip from a git repository" default="all">
|
||||
<property name="vendor-name" value="board3" />
|
||||
<property name="extension-name" value="portal" />
|
||||
<!--
|
||||
Only set this to "true" if you have dependencies in the composer.json,
|
||||
otherwise use "false".
|
||||
-->
|
||||
<property name="has-dependencies" value="true" />
|
||||
|
||||
<target name="clean-package">
|
||||
<!--
|
||||
Remove some unnecessary files/directories
|
||||
${dir}/ is the folder of your extension, e.g. ext/nickvergessen/newspage/
|
||||
-->
|
||||
<delete dir="${dir}/tests" />
|
||||
<delete dir="${dir}/travis" />
|
||||
<delete dir="${dir}/vendor/nickvergessen/phpbb-tool-trimmessage/src/Nickvergessen/TrimMessage/Tests" />
|
||||
<delete dir="${dir}/vendor/nickvergessen/phpbb-tool-trimmessage/tests" />
|
||||
|
||||
<delete file="${dir}/.gitignore" />
|
||||
<delete file="${dir}/.gitattributes" />
|
||||
<delete file="${dir}/.travis.yml" />
|
||||
<delete file="${dir}/build.xml" />
|
||||
<delete file="${dir}/composer.lock" />
|
||||
<delete file="${dir}/composer.phar" />
|
||||
<delete file="${dir}/phpunit.xml.dist" />
|
||||
<delete file="${dir}/README.md" />
|
||||
<delete file="${dir}/vendor/nickvergessen/phpbb-tool-trimmessage/composer.lock" />
|
||||
<delete file="${dir}/vendor/nickvergessen/phpbb-tool-trimmessage/composer.phar" />
|
||||
<delete file="${dir}/vendor/nickvergessen/phpbb-tool-trimmessage/phpunit.xml" />
|
||||
<delete file="${dir}/vendor/nickvergessen/phpbb-tool-trimmessage/README.md" />
|
||||
<delete file="${dir}/vendor/nickvergessen/phpbb-tool-trimmessage/.gitignore" />
|
||||
<delete file="${dir}/vendor/nickvergessen/phpbb-tool-trimmessage/.travis.yml" />
|
||||
</target>
|
||||
|
||||
<!--
|
||||
TODO: DO NOT EDIT BELOW THIS LINE!!!!
|
||||
-->
|
||||
|
||||
<property name="version" value="HEAD" override="true" />
|
||||
<property name="build-directory" value="build" override="true" />
|
||||
<property name="package-directory" value="${build-directory}/package/${vendor-name}/${extension-name}" />
|
||||
<property name="phpbb-root" value="${build-directory}/../../../../../" />
|
||||
|
||||
<!-- These are the main targets which you will probably want to use -->
|
||||
<target name="all" depends="prepare-structure,package" />
|
||||
|
||||
<!--
|
||||
Clean up the build directory
|
||||
-->
|
||||
<target name="clean">
|
||||
<delete dir="${build-directory}" />
|
||||
</target>
|
||||
|
||||
<target name="composer">
|
||||
<exec dir="${build-directory}/../"
|
||||
command="php composer.phar install"
|
||||
passthru="true" />
|
||||
</target>
|
||||
|
||||
<target name="test" depends="clean,composer">
|
||||
<exec dir="${phpbb-root}"
|
||||
command="phpBB/vendor/bin/phpunit
|
||||
-c phpBB/ext/${vendor-name}/${extension-name}/"
|
||||
passthru="true" />
|
||||
</target>
|
||||
|
||||
<target name="test-slow" depends="clean,composer">
|
||||
<exec dir="${phpbb-root}"
|
||||
command="phpBB/vendor/bin/phpunit
|
||||
-c phpBB/ext/${vendor-name}/${extension-name}/
|
||||
--group slow"
|
||||
passthru="true" />
|
||||
</target>
|
||||
|
||||
<!--
|
||||
Recreate the necessary folders
|
||||
-->
|
||||
<target name="prepare-structure" depends="clean,composer,test,test-slow">
|
||||
<mkdir dir="${build-directory}" />
|
||||
<mkdir dir="${build-directory}/checkout" />
|
||||
<mkdir dir="${build-directory}/package" />
|
||||
<mkdir dir="${build-directory}/package/${vendor-name}" />
|
||||
<mkdir dir="${build-directory}/package/${vendor-name}/${extension-name}" />
|
||||
<mkdir dir="${build-directory}/upload" />
|
||||
</target>
|
||||
|
||||
<!--
|
||||
The real packaging
|
||||
-->
|
||||
<target name="package">
|
||||
<echo msg="Extracting ${version}" />
|
||||
|
||||
<phingcall target="git-checkout">
|
||||
<property name="archive-version" value="${version}" />
|
||||
</phingcall>
|
||||
|
||||
<if>
|
||||
<equals arg1="${has-dependencies}" arg2="1" />
|
||||
<then>
|
||||
<exec dir="${package-directory}" command="php composer.phar install --no-dev"
|
||||
checkreturn="true" />
|
||||
</then>
|
||||
</if>
|
||||
|
||||
<phingcall target="clean-package">
|
||||
<property name="dir" value="${package-directory}" />
|
||||
</phingcall>
|
||||
|
||||
<phingcall target="wrap-package">
|
||||
<property name="destination-filename" value="${build-directory}/upload/${vendor-name}_${extension-name}-${version}" />
|
||||
</phingcall>
|
||||
</target>
|
||||
|
||||
<!--
|
||||
Checkout a given version and install/clean the dependencies
|
||||
-->
|
||||
<target name="git-checkout">
|
||||
<echo msg="Getting archive for ${archive-version}" />
|
||||
|
||||
<exec command="git archive ${archive-version} --format zip --output ${build-directory}/checkout/${archive-version}.zip"
|
||||
checkreturn="true" />
|
||||
<unzip file="${build-directory}/checkout/${archive-version}.zip" todir="${package-directory}" />
|
||||
</target>
|
||||
|
||||
<!--
|
||||
Create the zip and tar ball
|
||||
-->
|
||||
<target name="wrap-package">
|
||||
<echo msg="Creating archives (${vendor-name}/${extension-name} ${version})" />
|
||||
<zip basedir="${build-directory}/package/" destfile="${destination-filename}.zip" />
|
||||
</target>
|
||||
</project>
|
||||
@@ -3,8 +3,8 @@
|
||||
"type": "phpbb-extension",
|
||||
"description": "Adds a portal with several blocks to your forum. You can change the settings, move the blocks, add new blocks and more in the ACP.",
|
||||
"homepage": "http://www.board3.de",
|
||||
"version": "2.1.0-rc2",
|
||||
"time": "2015-02-07 16:41:42",
|
||||
"version": "2.1.0-rc3",
|
||||
"time": "2015-05-07 14:01:15",
|
||||
"license": "GPL-2.0",
|
||||
"authors": [{
|
||||
"name": "Marc Alexander",
|
||||
@@ -28,7 +28,7 @@
|
||||
"extra": {
|
||||
"display-name": "Board3 Portal",
|
||||
"soft-require": {
|
||||
"phpbb/phpbb": ">=3.1.3,<3.2.*@dev"
|
||||
"phpbb/phpbb": ">=3.1.4,<3.2.*@dev"
|
||||
},
|
||||
"version-check": {
|
||||
"host": "board3.de",
|
||||
|
||||
73
composer.lock
generated
@@ -4,20 +4,20 @@
|
||||
"Read more about it at http://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file",
|
||||
"This file is @generated automatically"
|
||||
],
|
||||
"hash": "fcaf26c5c7d6cd3f177ec06f4ce681e6",
|
||||
"hash": "b5a11feb74a85a9825b7b83aaaf8fa0e",
|
||||
"packages": [
|
||||
{
|
||||
"name": "nickvergessen/phpbb-tool-trimmessage",
|
||||
"version": "1.3.0",
|
||||
"version": "1.3.1",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/nickvergessen/phpbb-tool-trimmessage.git",
|
||||
"reference": "2a3d8273dc1238dd06454688bcb6496f62f66c3b"
|
||||
"reference": "0ed883bc2d473ec2e84cabb9c9395785daeeebcf"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/nickvergessen/phpbb-tool-trimmessage/zipball/2a3d8273dc1238dd06454688bcb6496f62f66c3b",
|
||||
"reference": "2a3d8273dc1238dd06454688bcb6496f62f66c3b",
|
||||
"url": "https://api.github.com/repos/nickvergessen/phpbb-tool-trimmessage/zipball/0ed883bc2d473ec2e84cabb9c9395785daeeebcf",
|
||||
"reference": "0ed883bc2d473ec2e84cabb9c9395785daeeebcf",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
@@ -46,7 +46,7 @@
|
||||
],
|
||||
"description": "This tool contains a class, that is able to trim a message from the phpbb message_parser to a maximum length without breaking the bbcodes/smilies and links.",
|
||||
"homepage": "https://github.com/nickvergessen/phpbb-tool-trimmessage",
|
||||
"time": "2014-07-06 19:42:34"
|
||||
"time": "2015-04-17 16:41:50"
|
||||
}
|
||||
],
|
||||
"packages-dev": [
|
||||
@@ -153,12 +153,12 @@
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/phpbb/epv.git",
|
||||
"reference": "07e017ea9d92581d5b83066469eb33b4b2a8f6ed"
|
||||
"reference": "75df9936ffbb8f05a1351cf622cf6f41c7d2d9f2"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/phpbb/epv/zipball/07e017ea9d92581d5b83066469eb33b4b2a8f6ed",
|
||||
"reference": "07e017ea9d92581d5b83066469eb33b4b2a8f6ed",
|
||||
"url": "https://api.github.com/repos/phpbb/epv/zipball/75df9936ffbb8f05a1351cf622cf6f41c7d2d9f2",
|
||||
"reference": "75df9936ffbb8f05a1351cf622cf6f41c7d2d9f2",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
@@ -171,7 +171,8 @@
|
||||
"symfony/yaml": ">=2.3.0|>=2.4.0|>=2.5.0"
|
||||
},
|
||||
"require-dev": {
|
||||
"phpunit/phpunit": "4.0.*"
|
||||
"phpunit/phpunit": "4.4.*",
|
||||
"phpunit/phpunit-mock-objects": "2.3.*"
|
||||
},
|
||||
"bin": [
|
||||
"src/EPV.php"
|
||||
@@ -193,7 +194,7 @@
|
||||
}
|
||||
],
|
||||
"description": "A extension validator for phpBB extensions. Extensions are required to pass the validator when submitted to the extension database.",
|
||||
"time": "2014-12-13 10:15:27"
|
||||
"time": "2015-02-12 12:13:06"
|
||||
},
|
||||
{
|
||||
"name": "sensiolabs/ansi-to-html",
|
||||
@@ -241,17 +242,17 @@
|
||||
},
|
||||
{
|
||||
"name": "symfony/console",
|
||||
"version": "v2.6.3",
|
||||
"version": "v2.6.5",
|
||||
"target-dir": "Symfony/Component/Console",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/symfony/Console.git",
|
||||
"reference": "6ac6491ff60c0e5a941db3ccdc75a07adbb61476"
|
||||
"reference": "53f86497ccd01677e22435cfb7262599450a90d1"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/symfony/Console/zipball/6ac6491ff60c0e5a941db3ccdc75a07adbb61476",
|
||||
"reference": "6ac6491ff60c0e5a941db3ccdc75a07adbb61476",
|
||||
"url": "https://api.github.com/repos/symfony/Console/zipball/53f86497ccd01677e22435cfb7262599450a90d1",
|
||||
"reference": "53f86497ccd01677e22435cfb7262599450a90d1",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
@@ -260,6 +261,7 @@
|
||||
"require-dev": {
|
||||
"psr/log": "~1.0",
|
||||
"symfony/event-dispatcher": "~2.1",
|
||||
"symfony/phpunit-bridge": "~2.7",
|
||||
"symfony/process": "~2.1"
|
||||
},
|
||||
"suggest": {
|
||||
@@ -294,26 +296,29 @@
|
||||
],
|
||||
"description": "Symfony Console Component",
|
||||
"homepage": "http://symfony.com",
|
||||
"time": "2015-01-06 17:50:02"
|
||||
"time": "2015-03-13 17:37:22"
|
||||
},
|
||||
{
|
||||
"name": "symfony/finder",
|
||||
"version": "v2.6.3",
|
||||
"version": "v2.6.5",
|
||||
"target-dir": "Symfony/Component/Finder",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/symfony/Finder.git",
|
||||
"reference": "16513333bca64186c01609961a2bb1b95b5e1355"
|
||||
"reference": "bebc7479c566fa4f14b9bcef9e32e719eabec74e"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/symfony/Finder/zipball/16513333bca64186c01609961a2bb1b95b5e1355",
|
||||
"reference": "16513333bca64186c01609961a2bb1b95b5e1355",
|
||||
"url": "https://api.github.com/repos/symfony/Finder/zipball/bebc7479c566fa4f14b9bcef9e32e719eabec74e",
|
||||
"reference": "bebc7479c566fa4f14b9bcef9e32e719eabec74e",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"php": ">=5.3.3"
|
||||
},
|
||||
"require-dev": {
|
||||
"symfony/phpunit-bridge": "~2.7"
|
||||
},
|
||||
"type": "library",
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
@@ -341,26 +346,29 @@
|
||||
],
|
||||
"description": "Symfony Finder Component",
|
||||
"homepage": "http://symfony.com",
|
||||
"time": "2015-01-03 08:01:59"
|
||||
"time": "2015-03-12 10:28:44"
|
||||
},
|
||||
{
|
||||
"name": "symfony/process",
|
||||
"version": "v2.6.3",
|
||||
"version": "v2.6.5",
|
||||
"target-dir": "Symfony/Component/Process",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/symfony/Process.git",
|
||||
"reference": "319794f611bd8bdefbac72beb3f05e847f8ebc92"
|
||||
"reference": "4d717f34f3d1d6ab30fbe79f7132960a27f4a0dc"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/symfony/Process/zipball/319794f611bd8bdefbac72beb3f05e847f8ebc92",
|
||||
"reference": "319794f611bd8bdefbac72beb3f05e847f8ebc92",
|
||||
"url": "https://api.github.com/repos/symfony/Process/zipball/4d717f34f3d1d6ab30fbe79f7132960a27f4a0dc",
|
||||
"reference": "4d717f34f3d1d6ab30fbe79f7132960a27f4a0dc",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"php": ">=5.3.3"
|
||||
},
|
||||
"require-dev": {
|
||||
"symfony/phpunit-bridge": "~2.7"
|
||||
},
|
||||
"type": "library",
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
@@ -388,26 +396,29 @@
|
||||
],
|
||||
"description": "Symfony Process Component",
|
||||
"homepage": "http://symfony.com",
|
||||
"time": "2015-01-06 22:47:52"
|
||||
"time": "2015-03-12 10:28:44"
|
||||
},
|
||||
{
|
||||
"name": "symfony/yaml",
|
||||
"version": "v2.6.3",
|
||||
"version": "v2.6.5",
|
||||
"target-dir": "Symfony/Component/Yaml",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/symfony/Yaml.git",
|
||||
"reference": "82462a90848a52c2533aa6b598b107d68076b018"
|
||||
"reference": "0cd8e72071e46e15fc072270ae39ea1b66b10a9d"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/symfony/Yaml/zipball/82462a90848a52c2533aa6b598b107d68076b018",
|
||||
"reference": "82462a90848a52c2533aa6b598b107d68076b018",
|
||||
"url": "https://api.github.com/repos/symfony/Yaml/zipball/0cd8e72071e46e15fc072270ae39ea1b66b10a9d",
|
||||
"reference": "0cd8e72071e46e15fc072270ae39ea1b66b10a9d",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"php": ">=5.3.3"
|
||||
},
|
||||
"require-dev": {
|
||||
"symfony/phpunit-bridge": "~2.7"
|
||||
},
|
||||
"type": "library",
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
@@ -435,7 +446,7 @@
|
||||
],
|
||||
"description": "Symfony Yaml Component",
|
||||
"homepage": "http://symfony.com",
|
||||
"time": "2015-01-03 15:33:07"
|
||||
"time": "2015-03-12 10:28:44"
|
||||
}
|
||||
],
|
||||
"aliases": [],
|
||||
|
||||
BIN
composer.phar
@@ -311,6 +311,7 @@ services:
|
||||
class: board3\portal\modules\whois_online
|
||||
arguments:
|
||||
- @auth
|
||||
- @config
|
||||
- @dbal.conn
|
||||
- @template
|
||||
- @user
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
board3_portal_controller:
|
||||
pattern: /portal
|
||||
path: /portal
|
||||
defaults: { _controller: board3.portal.main:handle }
|
||||
|
||||
# This is currently not supported yet
|
||||
@@ -9,5 +9,5 @@ board3_portal_controller:
|
||||
|
||||
# Redirect to portal by default
|
||||
board3_portal_redirect_controller:
|
||||
pattern: /
|
||||
path: /
|
||||
defaults: { _controller: board3.portal.main:handle }
|
||||
|
||||
@@ -87,6 +87,7 @@ services:
|
||||
board3.portal.listener:
|
||||
class: board3\portal\event\listener
|
||||
arguments:
|
||||
- @board3.portal.main
|
||||
- @auth
|
||||
- @config
|
||||
- @controller.helper
|
||||
@@ -102,6 +103,7 @@ services:
|
||||
arguments:
|
||||
- @cache
|
||||
- @dbal.conn
|
||||
- @board3.portal.controller_helper
|
||||
- @board3.portal.columns
|
||||
- @board3.portal.helper
|
||||
- @board3.portal.modules.constraints_handler
|
||||
|
||||
@@ -226,8 +226,8 @@ class helper
|
||||
if (is_array($template_module))
|
||||
{
|
||||
$this->template->assign_block_vars('modules_' . $this->portal_columns->number_to_string($row['module_column']), array(
|
||||
'TEMPLATE_FILE' => 'portal/modules/' . $template_module['template'],
|
||||
'IMAGE_SRC' => $this->path_helper->get_web_root_path() . $this->root_path . 'styles/' . $this->user->style['style_path'] . '/theme/images/portal/' . $template_module['image_src'],
|
||||
'TEMPLATE_FILE' => $this->parse_template_file($template_module['template']),
|
||||
'IMAGE_SRC' => $this->path_helper->get_web_root_path() . ltrim($this->root_path . 'styles/all/theme/images/portal/' . $template_module['image_src'], './'),
|
||||
'TITLE' => $template_module['title'],
|
||||
'CODE' => $template_module['code'],
|
||||
'MODULE_ID' => $row['module_id'],
|
||||
@@ -238,8 +238,8 @@ class helper
|
||||
else
|
||||
{
|
||||
$this->template->assign_block_vars('modules_' . $this->portal_columns->number_to_string($row['module_column']), array(
|
||||
'TEMPLATE_FILE' => 'portal/modules/' . $template_module,
|
||||
'IMAGE_SRC' => $this->path_helper->get_web_root_path() . $this->root_path . 'styles/' . $this->user->style['style_path'] . '/theme/images/portal/' . $row['module_image_src'],
|
||||
'TEMPLATE_FILE' => $this->parse_template_file($template_module),
|
||||
'IMAGE_SRC' => $this->path_helper->get_web_root_path() . ltrim($this->root_path . 'styles/all/theme/images/portal/' . $row['module_image_src'], './'),
|
||||
'IMAGE_WIDTH' => $row['module_image_width'],
|
||||
'IMAGE_HEIGHT' => $row['module_image_height'],
|
||||
'MODULE_ID' => $row['module_id'],
|
||||
@@ -264,4 +264,21 @@ class helper
|
||||
// Obtain portal config
|
||||
obtain_portal_config();
|
||||
}
|
||||
|
||||
/**
|
||||
* Parse template file by prefixing default modules with the portal path
|
||||
*
|
||||
* @param string $template_file HTML template
|
||||
*
|
||||
* @return string Parsed template file
|
||||
*/
|
||||
protected function parse_template_file($template_file)
|
||||
{
|
||||
if (strpos($template_file, '@') === false)
|
||||
{
|
||||
$template_file = 'portal/modules/' . $template_file;
|
||||
}
|
||||
|
||||
return $template_file;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -80,6 +80,12 @@ class main
|
||||
*/
|
||||
protected $portal_modules;
|
||||
|
||||
/** @var int Allowed columns */
|
||||
protected $allowed_columns;
|
||||
|
||||
/** @var bool Portal active flag */
|
||||
protected $portal_active = false;
|
||||
|
||||
/**
|
||||
* Constructor
|
||||
* NOTE: The parameters of this method must match in order and type with
|
||||
@@ -123,12 +129,27 @@ class main
|
||||
/**
|
||||
* Extension front handler method. This is called automatically when your extension is accessed
|
||||
* through index.php?ext=example/foobar
|
||||
*
|
||||
* @param array $columns Columns to display
|
||||
*
|
||||
* @return null
|
||||
*/
|
||||
public function handle()
|
||||
public function handle($columns = array())
|
||||
{
|
||||
// Do not run portal if it's already active
|
||||
if ($this->portal_active)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
$this->controller_helper->run_initial_tasks();
|
||||
|
||||
// Set portal active
|
||||
$this->portal_active = true;
|
||||
|
||||
// Check if we should limit the columns to display
|
||||
$this->set_allowed_columns($columns);
|
||||
|
||||
// Set default data
|
||||
$this->portal_modules = obtain_portal_modules();
|
||||
$display_online = false;
|
||||
@@ -181,6 +202,14 @@ class main
|
||||
// Assign specific vars
|
||||
$this->assign_template_vars();
|
||||
|
||||
// Return if columns were specified. Columns are only specified if
|
||||
// portal columns are displayed on pages other than the portal itself.
|
||||
if ($this->allowed_columns !== 0)
|
||||
{
|
||||
$this->template->assign_var('S_PORTAL_ALL', true);
|
||||
return;
|
||||
}
|
||||
|
||||
// And now to output the page.
|
||||
page_header($this->user->lang('PORTAL'), $display_online);
|
||||
|
||||
@@ -206,8 +235,15 @@ class main
|
||||
public function get_module_template($row, $module)
|
||||
{
|
||||
$template_module = false;
|
||||
|
||||
$column = $this->portal_columns->number_to_string($row['module_column']);
|
||||
|
||||
// Make sure we should actually load this module
|
||||
if (!$this->display_module_allowed($this->portal_columns->string_to_constant($column)))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
if (in_array($column, array('left', 'right')) && $this->config['board3_' . $column . '_column'])
|
||||
{
|
||||
++$this->module_count[$column];
|
||||
@@ -252,7 +288,7 @@ class main
|
||||
'S_BOTTOM_COLUMN' => $this->check_module_count('bottom'),
|
||||
'S_DISPLAY_PHPBB_MENU' => $this->config['board3_phpbb_menu'],
|
||||
'B3P_DISPLAY_JUMPBOX' => $this->config['board3_display_jumpbox'],
|
||||
'T_EXT_THEME_PATH' => $this->path_helper->get_web_root_path() . $this->root_path . 'styles/' . $this->user->style['style_path'] . '/theme/',
|
||||
'T_EXT_THEME_PATH' => $this->path_helper->get_web_root_path() . ltrim($this->root_path . 'styles/' . $this->user->style['style_path'] . '/theme/', './'),
|
||||
));
|
||||
}
|
||||
|
||||
@@ -282,4 +318,36 @@ class main
|
||||
make_jumpbox(append_sid("{$this->phpbb_root_path}viewforum{$this->php_ext}"));
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Check whether displaying the module is allowed
|
||||
*
|
||||
* @param int $module_column The column of the module
|
||||
*
|
||||
* @return bool True if module can be displayed, false if not
|
||||
*/
|
||||
protected function display_module_allowed($module_column)
|
||||
{
|
||||
return ($this->allowed_columns > 0) ? (bool) ($this->allowed_columns & $module_column) : true;
|
||||
}
|
||||
|
||||
/**
|
||||
* Set allowed columns based on supplied columns array
|
||||
*
|
||||
* @param array $columns Allowed columns
|
||||
*/
|
||||
protected function set_allowed_columns($columns)
|
||||
{
|
||||
if (!empty($columns))
|
||||
{
|
||||
foreach ($columns as $column => $show)
|
||||
{
|
||||
$this->allowed_columns |= ($show) ? $this->portal_columns->string_to_constant($column) : 0;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
$this->allowed_columns = 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -13,6 +13,9 @@ use Symfony\Component\EventDispatcher\EventSubscriberInterface;
|
||||
|
||||
class listener implements EventSubscriberInterface
|
||||
{
|
||||
/** @var \board3\portal\controller\main */
|
||||
protected $board3_controller;
|
||||
|
||||
/** @var \phpbb\auth\auth */
|
||||
protected $auth;
|
||||
|
||||
@@ -37,6 +40,7 @@ class listener implements EventSubscriberInterface
|
||||
/**
|
||||
* Constructor of Board3 Portal event listener
|
||||
*
|
||||
* @param \board3\portal\controller\main $board3_controller Board3 Portal controller
|
||||
* @param \phpbb\auth\auth $auth phpBB auth object
|
||||
* @param \phpbb\config\config $config phpBB config
|
||||
* @param \phpbb\controller\helper $controller_helper Controller helper object
|
||||
@@ -45,8 +49,9 @@ class listener implements EventSubscriberInterface
|
||||
* @param \phpbb\user $user User object
|
||||
* @param string $php_ext phpEx
|
||||
*/
|
||||
public function __construct(\phpbb\auth\auth $auth, \phpbb\config\config $config, \phpbb\controller\helper $controller_helper, \phpbb\path_helper $path_helper, \phpbb\template\template $template, \phpbb\user $user, $php_ext)
|
||||
public function __construct(\board3\portal\controller\main $board3_controller, \phpbb\auth\auth $auth, \phpbb\config\config $config, \phpbb\controller\helper $controller_helper, \phpbb\path_helper $path_helper, \phpbb\template\template $template, \phpbb\user $user, $php_ext)
|
||||
{
|
||||
$this->board3_controller = $board3_controller;
|
||||
$this->auth = $auth;
|
||||
$this->config = $config;
|
||||
$this->controller_helper = $controller_helper;
|
||||
@@ -113,9 +118,10 @@ class listener implements EventSubscriberInterface
|
||||
return;
|
||||
}
|
||||
|
||||
if (strpos($this->user->data['session_page'], '/portal') === false)
|
||||
if (strpos($this->controller_helper->get_current_url(), '/portal') === false)
|
||||
{
|
||||
$portal_link = $this->controller_helper->route('board3_portal_controller');
|
||||
$this->check_portal_all();
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -136,4 +142,37 @@ class listener implements EventSubscriberInterface
|
||||
{
|
||||
return $this->auth->acl_get('u_view_portal') && $this->config['board3_enable'];
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if portal on all pages should be shown and display it accordignly
|
||||
*/
|
||||
protected function check_portal_all()
|
||||
{
|
||||
// Check if we should show the portal
|
||||
if (isset($this->config['board3_show_all_pages']) && $this->config['board3_show_all_pages'] && !$this->board_disabled())
|
||||
{
|
||||
$this->display_portal();
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Display portal on all pages
|
||||
*/
|
||||
protected function display_portal()
|
||||
{
|
||||
$this->board3_controller->handle(array(
|
||||
'left' => $this->config['board3_show_all_side'] == false,
|
||||
'right' => $this->config['board3_show_all_side'] == true,
|
||||
));
|
||||
}
|
||||
|
||||
/**
|
||||
* Check whether the board has been disabled and should not be shown
|
||||
*
|
||||
* @return bool True if board has been disabled, false if not
|
||||
*/
|
||||
protected function board_disabled()
|
||||
{
|
||||
return $this->config['board_disable'] && !defined('IN_LOGIN') && !defined('SKIP_CHECK_DISABLED') && !$this->auth->acl_gets('a_', 'm_') && !$this->auth->acl_getf_global('m_');
|
||||
}
|
||||
}
|
||||
|
||||
@@ -70,32 +70,26 @@ function set_portal_config($config_name, $config_value)
|
||||
}
|
||||
|
||||
/**
|
||||
* Get portal modules
|
||||
*/
|
||||
* Get portal modules
|
||||
*
|
||||
* @return array Portal modules array
|
||||
*/
|
||||
function obtain_portal_modules()
|
||||
{
|
||||
global $db, $cache, $portal_modules;
|
||||
global $db;
|
||||
|
||||
if (($portal_modules = $cache->get('portal_modules')) === false || defined('DEBUG'))
|
||||
{
|
||||
$portal_modules = $portal_cached_modules = array();
|
||||
$portal_modules = array();
|
||||
|
||||
$sql = 'SELECT *
|
||||
FROM ' . PORTAL_MODULES_TABLE . '
|
||||
ORDER BY module_order ASC';
|
||||
$result = $db->sql_query($sql);
|
||||
$result = $db->sql_query($sql, 3600);
|
||||
|
||||
while ($row = $db->sql_fetchrow($result))
|
||||
{
|
||||
$portal_cached_modules[] = $row;
|
||||
|
||||
$portal_modules[] = $row;
|
||||
}
|
||||
$db->sql_freeresult($result);
|
||||
|
||||
$cache->put('portal_modules', $portal_cached_modules);
|
||||
}
|
||||
|
||||
return $portal_modules;
|
||||
}
|
||||
|
||||
@@ -200,7 +194,7 @@ function generate_portal_pagination($base_url, $num_items, $per_page, $start_ite
|
||||
$on_page = floor($start_item / $per_page) + 1;
|
||||
$url_delim = (strpos($base_url, '?') === false) ? '?' : '&';
|
||||
|
||||
$page_string = ($on_page == 1) ? '<ul><li class="active"><span>1</span></li>' : '<ul><li><a href="' . $base_url . $anker .'">1</a></li>';
|
||||
$page_string = ($on_page == 1) ? '<ul><li class="active"><span>1</span></li>' : '<ul><li><a href="' . $base_url . $anker .'" role="button">1</a></li>';
|
||||
|
||||
if ($total_pages > 5)
|
||||
{
|
||||
@@ -212,7 +206,7 @@ function generate_portal_pagination($base_url, $num_items, $per_page, $start_ite
|
||||
|
||||
for ($i = $start_cnt + 1; $i < $end_cnt; ++$i)
|
||||
{
|
||||
$page_string .= ($i == $on_page) ? '<li class="active"><span>' . $i . '</span></li>' : '<li><a href="' . $base_url . "{$url_delim}" . $pagination_type . '=' . (($i - 1) * $per_page) . $anker . '">' . $i . '</a></li>';
|
||||
$page_string .= ($i == $on_page) ? '<li class="active"><span>' . $i . '</span></li>' : '<li><a href="' . $base_url . "{$url_delim}" . $pagination_type . '=' . (($i - 1) * $per_page) . $anker . '" role="button">' . $i . '</a></li>';
|
||||
if ($i < $end_cnt - 1)
|
||||
{
|
||||
$page_string .= $seperator;
|
||||
@@ -228,25 +222,25 @@ function generate_portal_pagination($base_url, $num_items, $per_page, $start_ite
|
||||
|
||||
for ($i = 2; $i < $total_pages; ++$i)
|
||||
{
|
||||
$page_string .= ($i == $on_page) ? '<li class="active"><span>' . $i . '</span></li>' : '<li><a href="' . $base_url . "{$url_delim}" . $pagination_type . '=' . (($i - 1) * $per_page) . $anker . '">' . $i . '</a></li>';
|
||||
$page_string .= ($i == $on_page) ? '<li class="active"><span>' . $i . '</span></li>' : '<li><a href="' . $base_url . "{$url_delim}" . $pagination_type . '=' . (($i - 1) * $per_page) . $anker . '" role="button">' . $i . '</a></li>';
|
||||
if ($i < $total_pages)
|
||||
{
|
||||
$page_string .= $seperator;
|
||||
}
|
||||
}
|
||||
}
|
||||
$page_string .= ($on_page == $total_pages) ? '<li class="active"><span>' . $total_pages . '</span></li></ul>' : '<li><a href="' . $base_url . "{$url_delim}" . $pagination_type . '=' . (($total_pages - 1) * $per_page) . $anker . '">' . $total_pages . '</a></li></ul>';
|
||||
$page_string .= ($on_page == $total_pages) ? '<li class="active"><span>' . $total_pages . '</span></li></ul>' : '<li><a href="' . $base_url . "{$url_delim}" . $pagination_type . '=' . (($total_pages - 1) * $per_page) . $anker . '" role="button">' . $total_pages . '</a></li></ul>';
|
||||
|
||||
if ($add_prevnext_text)
|
||||
{
|
||||
if ($on_page != 1)
|
||||
{
|
||||
$page_string = '<a href="' . $base_url . "{$url_delim}" . $pagination_type . '=' . (($on_page - 2) * $per_page) . $anker . '">' . $user->lang['PREVIOUS'] . '</a> ' . $page_string;
|
||||
$page_string = '<a href="' . $base_url . "{$url_delim}" . $pagination_type . '=' . (($on_page - 2) * $per_page) . $anker . '" role="button">' . $user->lang['PREVIOUS'] . '</a> ' . $page_string;
|
||||
}
|
||||
|
||||
if ($on_page != $total_pages)
|
||||
{
|
||||
$page_string .= ' <a href="' . $base_url . "{$url_delim}" . $pagination_type . '=' . ($on_page * $per_page) . $anker . '">' . $user->lang['NEXT'] . '</a>';
|
||||
$page_string .= ' <a href="' . $base_url . "{$url_delim}" . $pagination_type . '=' . ($on_page * $per_page) . $anker . '" role="button">' . $user->lang['NEXT'] . '</a>';
|
||||
}
|
||||
}
|
||||
|
||||
@@ -433,37 +427,25 @@ function get_portal_tracking_info($fetch_news)
|
||||
*/
|
||||
function check_file_src($value, $key, $module_id, $force_error = true)
|
||||
{
|
||||
global $db, $phpbb_root_path, $phpEx, $user;
|
||||
global $phpbb_admin_path, $portal_root_path, $phpEx, $user;
|
||||
|
||||
$error = '';
|
||||
|
||||
// We check if the chosen file is present in all active styles
|
||||
$sql = 'SELECT style_path
|
||||
FROM ' . STYLES_TABLE . '
|
||||
WHERE style_active = 1';
|
||||
|
||||
$result = $db->sql_query($sql);
|
||||
while ($row = $db->sql_fetchrow($result))
|
||||
// We check if the chosen file is present in the styles/all/ folder
|
||||
if (!file_exists($portal_root_path . 'styles/all/theme/images/portal/' . $value))
|
||||
{
|
||||
if (!file_exists($phpbb_root_path . 'styles/' . $row['style_path'] . '/theme/images/portal/' . $value) &&
|
||||
!file_exists($phpbb_root_path . 'ext/board3/portal/styles/' . $row['style_path'] . '/theme/images/portal/' . $value))
|
||||
{
|
||||
$error .= $user->lang['B3P_FILE_NOT_FOUND'] . ': styles/' . $row['style_path'] . '/theme/images/portal/' . $value . '<br />';
|
||||
$error .= $user->lang['B3P_FILE_NOT_FOUND'] . ': styles/all/theme/images/portal/' . $value . '<br />';
|
||||
}
|
||||
}
|
||||
$db->sql_freeresult($result);
|
||||
|
||||
if (!empty($error))
|
||||
{
|
||||
if ($force_error)
|
||||
{
|
||||
trigger_error($error . adm_back_link(append_sid("{$phpbb_root_path}adm/index.$phpEx", 'i=\board3\portal\acp\portal_module&mode=config&module_id=' . $module_id)), E_USER_WARNING);
|
||||
trigger_error($error . adm_back_link(append_sid("{$phpbb_admin_path}index.$phpEx", 'i=\board3\portal\acp\portal_module&mode=config&module_id=' . $module_id)), E_USER_WARNING);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
return $error;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
return false;
|
||||
|
||||
@@ -158,4 +158,32 @@ class modules_helper
|
||||
{
|
||||
return $this->controller_helper->route($route, $params, $is_amp, $session_id, $reference_type);
|
||||
}
|
||||
|
||||
/**
|
||||
* Display radio buttons for left/right choice
|
||||
*
|
||||
* @param int $value Selected value
|
||||
* @param string $key Key of config variable
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function display_left_right($value, $key)
|
||||
{
|
||||
$radio_ary = array(0 => 'PORTAL_SHOW_ALL_LEFT', 1 => 'PORTAL_SHOW_ALL_RIGHT');
|
||||
|
||||
return h_radio($key, $radio_ary, $value, $key);
|
||||
}
|
||||
|
||||
/**
|
||||
* Store left right choice
|
||||
*
|
||||
* @param string $key Config key
|
||||
*/
|
||||
public function store_left_right($key)
|
||||
{
|
||||
// Get selected side
|
||||
$value = $this->request->variable($key, 0);
|
||||
|
||||
$this->config->set($key, $value);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -41,6 +41,12 @@ class version_check
|
||||
*/
|
||||
protected $current_version;
|
||||
|
||||
/** @var array Update data */
|
||||
protected $update_data;
|
||||
|
||||
/** @var array Template data */
|
||||
protected $template_data;
|
||||
|
||||
/**
|
||||
* Construct a version_check object
|
||||
*
|
||||
@@ -65,7 +71,7 @@ class version_check
|
||||
* returning current version
|
||||
*
|
||||
* @param bool $return_version Yes if current version should be returned
|
||||
* @return string Current version if $return_version is set to true
|
||||
* @return string|bool Current version if $return_version is set to true, false if not
|
||||
*/
|
||||
public function check($return_version = false)
|
||||
{
|
||||
@@ -76,7 +82,15 @@ class version_check
|
||||
|
||||
$this->version_helper->force_stability(($this->config['extension_force_unstable'] || !$this->version_helper->is_stable($this->current_version)) ? 'unstable' : null);
|
||||
|
||||
$updates = $this->version_helper->get_suggested_updates(true);
|
||||
// Expect version_helper to throw RuntimeExceptions
|
||||
try
|
||||
{
|
||||
$this->update_data = $this->version_helper->get_suggested_updates(true);
|
||||
}
|
||||
catch (\RuntimeException $e)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
// Return version if $return_version is set to true
|
||||
if ($return_version)
|
||||
@@ -84,9 +98,9 @@ class version_check
|
||||
return $this->current_version;
|
||||
}
|
||||
|
||||
$version_up_to_date = empty($updates);
|
||||
$version_up_to_date = empty($this->update_data);
|
||||
|
||||
$template_data = array(
|
||||
$this->template_data = array(
|
||||
'AUTHOR' => $this->version_data['author'],
|
||||
'CURRENT_VERSION' => $this->current_version,
|
||||
'UP_TO_DATE' => sprintf((!$version_up_to_date) ? $this->user->lang['NOT_UP_TO_DATE'] : $this->user->lang['UP_TO_DATE'], $this->version_data['title']),
|
||||
@@ -96,15 +110,25 @@ class version_check
|
||||
'LATEST_VERSION' => $this->current_version,
|
||||
);
|
||||
|
||||
if (!$version_up_to_date)
|
||||
$this->display_update_information();
|
||||
$this->template->assign_block_vars('mods', $this->template_data);
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* Display update information if updates exist
|
||||
*/
|
||||
protected function display_update_information()
|
||||
{
|
||||
$updates = array_shift($updates);
|
||||
$template_data = array_merge($template_data, array(
|
||||
'ANNOUNCEMENT' => (string) $updates['announcement'],
|
||||
'DOWNLOAD' => (string) $updates['download'],
|
||||
'LATEST_VERSION' => $updates['current'],
|
||||
if (!empty($this->update_data))
|
||||
{
|
||||
$update = array_shift($this->update_data);
|
||||
$this->template_data = array_merge($this->template_data, array(
|
||||
'ANNOUNCEMENT' => (string) $update['announcement'],
|
||||
'DOWNLOAD' => (string) $update['download'],
|
||||
'LATEST_VERSION' => $update['current'],
|
||||
));
|
||||
}
|
||||
$this->template->assign_block_vars('mods', $template_data);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -80,6 +80,8 @@ $lang = array_merge($lang, array(
|
||||
'ACP_PORTAL_CONFIG_INFO' => 'Allgemeine Einstellungen',
|
||||
'ACP_PORTAL_GENERAL_TITLE' => 'Portal Verwaltung',
|
||||
'ACP_PORTAL_GENERAL_TITLE_EXP' => 'Danke, dass du dich für board3 Portal entschieden hast. Auf dieser Seite kannst du dein Portal verwalten. Diese Anzeige gibt dir einen schnellen Überblick über die verschiedenen Portal-Einstellungen.',
|
||||
'ACP_PORTAL_SHOW_ALL' => 'Zeige portal auf allen Seiten',
|
||||
'ACP_PORTAL_SHOW_ALL_EXP' => 'Zeigt das Portal auf allen Seiten des Forums an.',
|
||||
'PORTAL_ENABLE' => 'Portal aktivieren',
|
||||
'PORTAL_ENABLE_EXP' => 'Wenn deaktiviert, wird das komplette Portal abgeschaltet.',
|
||||
'PORTAL_LEFT_COLUMN' => 'Linke Spalte aktivieren',
|
||||
@@ -94,6 +96,10 @@ $lang = array_merge($lang, array(
|
||||
'PORTAL_RIGHT_COLUMN_WIDTH_EXP' => 'Ändere hier die Breite der rechten Spalte in Pixel, empfohlener Wert 180',
|
||||
'PORTAL_DISPLAY_JUMPBOX' => 'Zeige Jumpbox',
|
||||
'PORTAL_DISPLAY_JUMPBOX_EXP' => 'Die Jumpbox auf dem Portal anzeigen. Die Jumpbox wird nur angezeigt, wenn sie gleichzeitig in den Board-Funktionalitäten aktiviert ist.',
|
||||
'PORTAL_SHOW_ALL_SIDE' => 'Spalte die auf allen Seiten angezeigt werden soll',
|
||||
'PORTAL_SHOW_ALL_SIDE_EXP' => 'Wähle welche Spalte auf allen seiten des Portals angezeigt werden soll.',
|
||||
'PORTAL_SHOW_ALL_LEFT' => 'Links',
|
||||
'PORTAL_SHOW_ALL_RIGHT' => 'Rechts',
|
||||
|
||||
'LINK_ADDED' => 'Der Link wurde erfolgreich eingetragen',
|
||||
'LINK_UPDATED' => 'Der Link wurde erfolgreich geändert',
|
||||
|
||||
@@ -80,6 +80,8 @@ $lang = array_merge($lang, array(
|
||||
'ACP_PORTAL_CONFIG_INFO' => 'General settings',
|
||||
'ACP_PORTAL_GENERAL_TITLE' => 'Portal Administration',
|
||||
'ACP_PORTAL_GENERAL_TITLE_EXP' => 'Thank you for choosing Board3 Portal! This is where you can manage your portal page. The options below let you customize the various general settings.',
|
||||
'ACP_PORTAL_SHOW_ALL' => 'Show portal on all pages',
|
||||
'ACP_PORTAL_SHOW_ALL_EXP' => 'Display the portal on all pages',
|
||||
'PORTAL_ENABLE' => 'Enable Portal',
|
||||
'PORTAL_ENABLE_EXP' => 'Turns the whole portal on or off',
|
||||
'PORTAL_LEFT_COLUMN' => 'Enable left column',
|
||||
@@ -94,6 +96,10 @@ $lang = array_merge($lang, array(
|
||||
'PORTAL_LEFT_COLUMN_WIDTH_EXP' => 'Change the width of the left column in pixels; recommended value is 180',
|
||||
'PORTAL_RIGHT_COLUMN_WIDTH' => 'Width of the right column',
|
||||
'PORTAL_RIGHT_COLUMN_WIDTH_EXP' => 'Change the width of the right column in pixels; recommended value is 180',
|
||||
'PORTAL_SHOW_ALL_SIDE' => 'Column to display on all pages',
|
||||
'PORTAL_SHOW_ALL_SIDE_EXP' => 'Choose which column should be shown on all pages.',
|
||||
'PORTAL_SHOW_ALL_LEFT' => 'Left',
|
||||
'PORTAL_SHOW_ALL_RIGHT' => 'Right',
|
||||
|
||||
'LINK_ADDED' => 'The link has been successfully added',
|
||||
'LINK_UPDATED' => 'The link has been successfully updated',
|
||||
|
||||
@@ -55,7 +55,7 @@ $lang = array_merge($lang, array(
|
||||
'PORTAL_ANNOUNCEMENTS' => 'Afficher les annonces globales',
|
||||
'PORTAL_ANNOUNCEMENTS_EXP' => 'Afficher ce bloc sur le portail.',
|
||||
'PORTAL_ANNOUNCEMENTS_STYLE' => 'Affichage compact du bloc des annonces globales',
|
||||
'PORTAL_ANNOUNCEMENTS_STYLE_EXP' => '“Oui” affiche de manière compacte le bloc des annonces globales. “Non” affiche ce bloc de manière plus large (affichage du texte).',
|
||||
'PORTAL_ANNOUNCEMENTS_STYLE_EXP' => '« Oui » affiche de manière compacte le bloc des annonces globales. « Non » affiche ce bloc de manière plus large (affichage du texte).',
|
||||
'PORTAL_NUMBER_OF_ANNOUNCEMENTS' => 'Nombre d’annonces sur le portail',
|
||||
'PORTAL_NUMBER_OF_ANNOUNCEMENTS_EXP' => '0 signifie un nombre infini.',
|
||||
'PORTAL_ANNOUNCEMENTS_DAY' => 'Nombre de jours de l’affichage des annonces',
|
||||
@@ -63,13 +63,13 @@ $lang = array_merge($lang, array(
|
||||
'PORTAL_ANNOUNCEMENTS_LENGTH' => 'Limite de caractères pour les annonces globales',
|
||||
'PORTAL_ANNOUNCEMENTS_LENGTH_EXP' => '0 signifie un nombre infini.',
|
||||
'PORTAL_GLOBAL_ANNOUNCEMENTS_FORUM' => 'Forums des annonces',
|
||||
'PORTAL_GLOBAL_ANNOUNCEMENTS_FORUM_EXP' => 'Forums depuis lesquels les annonces seront affichées. Laisser vide pour afficher toutes les annonces de tous les forums. Si “Exclure des forums” est paramétré sur “Oui”, sélectionner les forums souhaitant être exclus.<br />Si “Exclure des forums” est paramétré sur “Non”, sélectionner les forums souhaités.<br />Pour sélectionner / désélectionner plusieurs forums maintenir la touche <samp>CTRL</samp> tout en cliquant.',
|
||||
'PORTAL_GLOBAL_ANNOUNCEMENTS_FORUM_EXP' => 'Forums depuis lesquels les annonces seront affichées. Laisser vide pour afficher toutes les annonces de tous les forums. Si « Exclure des forums » est paramétré sur « Oui », sélectionner les forums souhaitant être exclus.<br />Si « Exclure des forums » est paramétré sur « Non », sélectionner les forums souhaités.<br />Pour sélectionner / désélectionner plusieurs forums maintenir la touche <samp>CTRL</samp> tout en cliquant.',
|
||||
'PORTAL_ANNOUNCEMENTS_FORUM_EXCLUDE' => 'Exclure des forums',
|
||||
'PORTAL_ANNOUNCEMENTS_FORUM_EXCLUDE_EXP'=> 'Sélectionner “Oui” pour exclure les annonces de certains forums et “Non” pour voir uniquement les annonces de certains forums.',
|
||||
'PORTAL_ANNOUNCEMENTS_FORUM_EXCLUDE_EXP'=> 'Sélectionner « Oui » pour exclure les annonces de certains forums et « Non » pour voir uniquement les annonces de certains forums.',
|
||||
'PORTAL_ANNOUNCEMENTS_PERMISSIONS' => 'Activer / désactiver les permissions',
|
||||
'PORTAL_ANNOUNCEMENTS_PERMISSIONS_EXP' => 'Lors de l’affichage des annonces prendre en compte les permissions utilisateurs / forums.',
|
||||
'PORTAL_ANNOUNCEMENTS_ARCHIVE' => 'Activer le système d’archivage des annonces',
|
||||
'PORTAL_ANNOUNCEMENTS_ARCHIVE_EXP' => 'Si activé, le système d’archivage des annonces sera affiché par numéro de page.',
|
||||
'PORTAL_SHOW_REPLIES_VIEWS' => 'Afficher le nombre de réponses et de vus',
|
||||
'PORTAL_SHOW_REPLIES_VIEWS_EXP' => 'Ce paramètre se rapporte au bloc compact.<br />Lorsqu’il est paramétré à “Oui”, le nombre de réponses et de vus sont affichés dans deux colonnes supplémentaires. Lorsqu’il est paramétré sur “Non”, le nombre de réponses et de vus sont affichés à côté du nom du forum. Sélectionner sur “Non” si il y a un problème d’affichage avec les deux colonnes supplémentaires (du fait de la largeur supplémentaire requise).',
|
||||
'PORTAL_SHOW_REPLIES_VIEWS_EXP' => 'Ce paramètre se rapporte au bloc compact.<br />Lorsqu’il est paramétré à « Oui », le nombre de réponses et de vus sont affichés dans deux colonnes supplémentaires. Lorsqu’il est paramétré sur « Non », le nombre de réponses et de vus sont affichés à côté du nom du forum. Sélectionner sur « Non » si il y a un problème d’affichage avec les deux colonnes supplémentaires (du fait de la largeur supplémentaire requise).',
|
||||
));
|
||||
|
||||
@@ -43,13 +43,13 @@ $lang = array_merge($lang, array(
|
||||
'PORTAL_ATTACHMENTS_NUMBER' => 'Limite d’affichage des fichiers joints',
|
||||
'PORTAL_ATTACHMENTS_NUMBER_EXP' => '0 signifie un nombre infini.',
|
||||
'PORTAL_ATTACHMENTS_FORUM_IDS' => 'Forums des fichiers joints',
|
||||
'PORTAL_ATTACHMENTS_FORUM_IDS_EXP' => 'Forums depuis lesquels les fichiers joints seront affichés. Laisser vide pour afficher tous les fichiers joints de tous les forums. Si “Exclure des forums” est paramétré sur “Oui”, sélectionner les forums souhaitant être exclus.<br />Si “Exclure des forums” est paramétré sur “Non”, sélectionner les forums souhaités.<br />Pour sélectionner / désélectionner plusieurs forums maintenir la touche <samp>CTRL</samp> tout en cliquant.',
|
||||
'PORTAL_ATTACHMENTS_FORUM_IDS_EXP' => 'Forums depuis lesquels les fichiers joints seront affichés. Laisser vide pour afficher tous les fichiers joints de tous les forums. Si « Exclure des forums » est paramétré sur « Oui », sélectionner les forums souhaitant être exclus.<br />Si « Exclure des forums » est paramétré sur « Non », sélectionner les forums souhaités.<br />Pour sélectionner / désélectionner plusieurs forums maintenir la touche <samp>CTRL</samp> tout en cliquant.',
|
||||
'PORTAL_ATTACHMENTS_FORUM_EXCLUDE' => 'Exclure des forums',
|
||||
'PORTAL_ATTACHMENTS_FORUM_EXCLUDE_EXP' => 'Sélectionner “Oui” pour exclure les fichiers joints de certains forums et “Non” pour voir uniquement les fichiers joints de certains forums.',
|
||||
'PORTAL_ATTACHMENTS_FORUM_EXCLUDE_EXP' => 'Sélectionner « Oui » pour exclure les fichiers joints de certains forums et « Non » pour voir uniquement les fichiers joints de certains forums.',
|
||||
'PORTAL_ATTACHMENTS_MAX_LENGTH' => 'Limite de caractères pour chaque fichier joint',
|
||||
'PORTAL_ATTACHMENTS_MAX_LENGTH_EXP' => '0 signifie un nombre infini.',
|
||||
'PORTAL_ATTACHMENTS_FILETYPE' => 'Types de fichiers',
|
||||
'PORTAL_ATTACHMENTS_FILETYPE_EXP' => 'Type de fichiers qui seront affichés. Laisser vide pour afficher tous les types de fichiers joints. Si “Exclure des types de fichiers” est paramétré sur “Oui”, sélectionner les types de fichiers souhaitant être exclus.<br />Si “Exclure des types de fichiers” est paramétré sur “Non”, sélectionner les types de fichiers souhaités.<br />Pour sélectionner / désélectionner plusieurs types de fichiers maintenir la touche <samp>CTRL</samp> tout en cliquant.',
|
||||
'PORTAL_ATTACHMENTS_FILETYPE_EXP' => 'Type de fichiers qui seront affichés. Laisser vide pour afficher tous les types de fichiers joints. Si « Exclure des types de fichiers » est paramétré sur « Oui », sélectionner les types de fichiers souhaitant être exclus.<br />Si « Exclure des types de fichiers » est paramétré sur « Non », sélectionner les types de fichiers souhaités.<br />Pour sélectionner / désélectionner plusieurs types de fichiers maintenir la touche <samp>CTRL</samp> tout en cliquant.',
|
||||
'PORTAL_ATTACHMENTS_EXCLUDE' => 'Exclure des types de fichiers',
|
||||
'PORTAL_ATTACHMENTS_EXCLUDE_EXP' => 'Sélectionner “Oui” pour exclure certains types de fichiers joints et “Non” pour voir uniquement certains types fichiers joints.',
|
||||
'PORTAL_ATTACHMENTS_EXCLUDE_EXP' => 'Sélectionner « Oui » pour exclure certains types de fichiers joints et « Non » pour voir uniquement certains types fichiers joints.',
|
||||
));
|
||||
|
||||
@@ -47,13 +47,13 @@ $lang = array_merge($lang, array(
|
||||
|
||||
'mini_cal' => array(
|
||||
'day' => array(
|
||||
'1' => 'Lu',
|
||||
'2' => 'Ma',
|
||||
'3' => 'Me',
|
||||
'4' => 'Je',
|
||||
'5' => 'Ve',
|
||||
'6' => 'Sa',
|
||||
'7' => 'Di',
|
||||
'1' => 'Di',
|
||||
'2' => 'Lu',
|
||||
'3' => 'Ma',
|
||||
'4' => 'Me',
|
||||
'5' => 'Je',
|
||||
'6' => 'Ve',
|
||||
'7' => 'Sa',
|
||||
),
|
||||
|
||||
'month' => array(
|
||||
@@ -98,7 +98,7 @@ $lang = array_merge($lang, array(
|
||||
'PORTAL_LONG_MONTH' => 'Afficher le nom complet des mois',
|
||||
'PORTAL_LONG_MONTH_EXP' => 'Si désactivé le nom des mois sera tronqué, comme par exemple : Jan. à la place de Janvier.',
|
||||
'PORTAL_SUNDAY_FIRST' => 'Premier jour de la semaine',
|
||||
'PORTAL_SUNDAY_FIRST_EXP' => 'Si désactivé le calendrier affichera Ma --> Lu, à la place de Lu --> Di.',
|
||||
'PORTAL_SUNDAY_FIRST_EXP' => 'Si désactivé le calendrier affichera Lu. --> Di., à la place de Di. --> Sa.',
|
||||
'PORTAL_DISPLAY_EVENTS' => 'Afficher les évènements',
|
||||
'PORTAL_DISPLAY_EVENTS_EXP' => 'Afficher les événements qui ont été créés pour le bloc calendrier.',
|
||||
'PORTAL_EVENTS_MANAGE' => 'Gérer les évènements',
|
||||
|
||||
@@ -33,7 +33,7 @@ if (empty($lang) || !is_array($lang))
|
||||
// equally where a string contains only two placeholders which are used to wrap text
|
||||
// in a url you again do not need to specify an order e.g., 'Click %sHERE%s' is fine
|
||||
$lang = array_merge($lang, array(
|
||||
'LATEST_BOTS' => 'Derniers robots',
|
||||
'LATEST_BOTS' => 'Dernières visites des robots',
|
||||
'LAST_VISITED_BOTS' => 'Dernières visites des robots',
|
||||
|
||||
// ACP
|
||||
|
||||
@@ -49,7 +49,7 @@ $lang = array_merge($lang, array(
|
||||
'ACP_PORTAL_NEWS_SETTINGS' => 'Paramètres des nouveaux messages',
|
||||
'ACP_PORTAL_NEWS_SETTINGS_EXP' => 'Ici vous personnalisez le bloc des nouveaux messages.',
|
||||
'PORTAL_NEWS_STYLE' => 'Affichage compact du bloc des nouveaux messages',
|
||||
'PORTAL_NEWS_STYLE_EXP' => '“Oui” affiche de manière compacte le bloc des nouveaux messages. “Non” affiche ce bloc de manière plus large (affichage du texte).',
|
||||
'PORTAL_NEWS_STYLE_EXP' => '« Oui » affiche de manière compacte le bloc des nouveaux messages. « Non » affiche ce bloc de manière plus large (affichage du texte).',
|
||||
'PORTAL_SHOW_ALL_NEWS' => 'Afficher tous les messages dans ce forum',
|
||||
'PORTAL_SHOW_ALL_NEWS_EXP' => 'Inclure les post-it.',
|
||||
'PORTAL_NUMBER_OF_NEWS' => 'Nombre de nouveaux messages sur le portail',
|
||||
@@ -57,9 +57,9 @@ $lang = array_merge($lang, array(
|
||||
'PORTAL_NEWS_LENGTH' => 'Longueur maximale en caractères des nouveaux messages',
|
||||
'PORTAL_NEWS_LENGTH_EXP' => '0 signifie un nombre infini.',
|
||||
'PORTAL_NEWS_FORUM' => 'Forums des messages',
|
||||
'PORTAL_NEWS_FORUM_EXP' => 'Forums depuis lesquels les nouveaux messages seront affichés. Laisser vide pour afficher les nouveaux messages de tous les forums. Si “Exclure des forums” est paramétré sur “Oui”, sélectionner les forums souhaitant être exclus.<br />Si “Exclure des forums” est paramétré sur “Non”, sélectionner les forums souhaités.<br />Pour sélectionner / désélectionner plusieurs forums maintenir la touche <samp>CTRL</samp> tout en cliquant.',
|
||||
'PORTAL_NEWS_FORUM_EXP' => 'Forums depuis lesquels les nouveaux messages seront affichés. Laisser vide pour afficher les nouveaux messages de tous les forums. Si « Exclure des forums » est paramétré sur « Oui », sélectionner les forums souhaitant être exclus.<br />Si « Exclure des forums » est paramétré sur « Non », sélectionner les forums souhaités.<br />Pour sélectionner / désélectionner plusieurs forums maintenir la touche <samp>CTRL</samp> tout en cliquant.',
|
||||
'PORTAL_NEWS_EXCLUDE' => 'Exclure des forums',
|
||||
'PORTAL_NEWS_EXCLUDE_EXP' => 'Sélectionner sur “Oui” pour exclure les nouveaux messages de certains forums et “Non” pour voir uniquement les nouveaux messages de certains forums.',
|
||||
'PORTAL_NEWS_EXCLUDE_EXP' => 'Sélectionner sur « Oui » pour exclure les nouveaux messages de certains forums et « Non » pour voir uniquement les nouveaux messages de certains forums.',
|
||||
'PORTAL_NEWS_PERMISSIONS' => 'Activer / désactiver les permissions',
|
||||
'PORTAL_NEWS_PERMISSIONS_EXP' => 'Lors de l’affichage des nouveaux messages prendre en compte les permissions utilisateurs / forums.',
|
||||
'PORTAL_NEWS_SHOW_LAST' => 'Classer suivant l’ordre des nouveaux messages',
|
||||
@@ -67,5 +67,5 @@ $lang = array_merge($lang, array(
|
||||
'PORTAL_NEWS_ARCHIVE' => 'Activer le système d’archivage des nouveaux messages',
|
||||
'PORTAL_NEWS_ARCHIVE_EXP' => 'Si activé, le système d’archivage des nouveaux messages sera affiché par numéro de page.',
|
||||
'PORTAL_SHOW_REPLIES_VIEWS' => 'Afficher le nombre de réponses et de vus',
|
||||
'PORTAL_SHOW_REPLIES_VIEWS_EXP' => 'Ce paramètre se rapporte au bloc compact.<br />Lorsqu’il est paramétré à “Oui”, le nombre de réponses et de vus sont affichés dans deux colonnes supplémentaires. Lorsqu’il est paramétré sur “Non”, le nombre de réponses et de vus sont affichés à côté du nom du forum. Sélectionner sur “Non” si il y a un problème d’affichage avec les deux colonnes supplémentaires (du fait de la largeur supplémentaire requise).',
|
||||
'PORTAL_SHOW_REPLIES_VIEWS_EXP' => 'Ce paramètre se rapporte au bloc compact.<br />Lorsqu’il est paramétré à « Oui », le nombre de réponses et de vus sont affichés dans deux colonnes supplémentaires. Lorsqu’il est paramétré sur « Non », le nombre de réponses et de vus sont affichés à côté du nom du forum. Sélectionner sur « Non » si il y a un problème d’affichage avec les deux colonnes supplémentaires (du fait de la largeur supplémentaire requise).',
|
||||
));
|
||||
|
||||
@@ -43,9 +43,9 @@ $lang = array_merge($lang, array(
|
||||
'ACP_PORTAL_POLLS_SETTINGS' => 'Paramètres des sondages',
|
||||
'ACP_PORTAL_POLLS_SETTINGS_EXP' => 'Ici vous personnalisez le bloc des sondages.',
|
||||
'PORTAL_POLL_TOPIC_ID' => 'Forums des sondages',
|
||||
'PORTAL_POLL_TOPIC_ID_EXP' => 'Forums depuis lesquels les sondages seront affichés. Laisser vide pour afficher tous les sondages de tous les forums. Si “Exclure des forums” est paramétré sur “Oui”, sélectionner les forums souhaitant être exclus.<br />Si “Exclure des forums” est paramétré sur “Non”, sélectionner les forums souhaités.<br />Pour sélectionner / désélectionner plusieurs forums maintenir la touche <samp>CTRL</samp> tout en cliquant.',
|
||||
'PORTAL_POLL_TOPIC_ID_EXP' => 'Forums depuis lesquels les sondages seront affichés. Laisser vide pour afficher tous les sondages de tous les forums. Si « Exclure des forums » est paramétré sur « Oui », sélectionner les forums souhaitant être exclus.<br />Si « Exclure des forums » est paramétré sur « Non », sélectionner les forums souhaités.<br />Pour sélectionner / désélectionner plusieurs forums maintenir la touche <samp>CTRL</samp> tout en cliquant.',
|
||||
'PORTAL_POLL_EXCLUDE_ID' => 'Exclure des forums',
|
||||
'PORTAL_POLL_EXCLUDE_ID_EXP' => 'Sélectionner “Oui” pour exclure les sondages de certains forums et “Non” pour voir uniquement les sondages de certains forums.',
|
||||
'PORTAL_POLL_EXCLUDE_ID_EXP' => 'Sélectionner « Oui » pour exclure les sondages de certains forums et « Non » pour voir uniquement les sondages de certains forums.',
|
||||
'PORTAL_POLL_LIMIT' => 'Nombre de sondages',
|
||||
'PORTAL_POLL_LIMIT_EXP' => 'Nombre maximum de sondages affichés sur la page du portail.',
|
||||
'PORTAL_POLL_ALLOW_VOTE' => 'Permettre de voter',
|
||||
|
||||
@@ -34,9 +34,9 @@ if (empty($lang) || !is_array($lang))
|
||||
// in a url you again do not need to specify an order e.g., 'Click %sHERE%s' is fine
|
||||
$lang = array_merge($lang, array(
|
||||
'PORTAL_RANDOM_MEMBER' => 'Membre aléatoire',
|
||||
'RND_JOIN' => 'Inscrit',
|
||||
'RND_JOIN' => 'Enregistré le',
|
||||
'RND_POSTS' => 'Messages',
|
||||
'RND_OCC' => 'Métier',
|
||||
'RND_OCC' => 'Emploi',
|
||||
'RND_FROM' => 'Localisation',
|
||||
'RND_WWW' => 'Site Internet',
|
||||
));
|
||||
|
||||
@@ -46,7 +46,7 @@ $lang = array_merge($lang, array(
|
||||
'PORTAL_RECENT_TITLE_LIMIT' => 'Limite de caractères pour chaque titre des sujets récents',
|
||||
'PORTAL_RECENT_TITLE_LIMIT_EXP' => '0 signifie un nombre infini.',
|
||||
'PORTAL_RECENT_FORUM' => 'Forums des sujets récents',
|
||||
'PORTAL_RECENT_FORUM_EXP' => 'Forums depuis lesquels les sujets récents seront affichés. Laisser vide pour afficher les sujets récents de tous les forums. Si “Exclure des forums” est paramétré sur “Oui”, sélectionner les forums souhaitant être exclus.<br />Si “Exclure des forums” est paramétré sur “Non”, sélectionner les forums souhaités.<br />Pour sélectionner / désélectionner plusieurs forums maintenir la touche <samp>CTRL</samp> tout en cliquant.',
|
||||
'PORTAL_RECENT_FORUM_EXP' => 'Forums depuis lesquels les sujets récents seront affichés. Laisser vide pour afficher les sujets récents de tous les forums. Si « Exclure des forums » est paramétré sur « Oui », sélectionner les forums souhaitant être exclus.<br />Si « Exclure des forums » est paramétré sur « Non », sélectionner les forums souhaités.<br />Pour sélectionner / désélectionner plusieurs forums maintenir la touche <samp>CTRL</samp> tout en cliquant.',
|
||||
'PORTAL_EXCLUDE_FORUM' => 'Exclure des forums',
|
||||
'PORTAL_EXCLUDE_FORUM_EXP' => 'Sélectionner “Oui” pour exclure les sujets récents de certains forums et “Non” pour voir uniquement les sujets récents de certains forums.',
|
||||
'PORTAL_EXCLUDE_FORUM_EXP' => 'Sélectionner « Oui » pour exclure les sujets récents de certains forums et « Non » pour voir uniquement les sujets récents de certains forums.',
|
||||
));
|
||||
|
||||
@@ -33,8 +33,8 @@ if (empty($lang) || !is_array($lang))
|
||||
// equally where a string contains only two placeholders which are used to wrap text
|
||||
// in a url you again do not need to specify an order e.g., 'Click %sHERE%s' is fine
|
||||
$lang = array_merge($lang, array(
|
||||
'TOPPOSTERS' => 'Utilisateurs actifs',
|
||||
'TOPPOSTERS_CONFIG' => 'Paramètres des utilisateurs actifs',
|
||||
'TOPPOSTERS' => 'Utilisateurs les plus actifs',
|
||||
'TOPPOSTERS_CONFIG' => 'Paramètres des utilisateurs les plus actifs',
|
||||
|
||||
// ACP
|
||||
'NUM_TOPPOSTERS' => 'Nombre d’utilisateurs actifs',
|
||||
|
||||
@@ -54,9 +54,9 @@ $lang = array_merge($lang, array(
|
||||
'UNABLE_TO_MOVE' => 'Il n’est pas possible de déplacer le bloc dans la colonne sélectionnée.',
|
||||
'UNABLE_TO_MOVE_ROW' => 'Il n’est pas possible de déplacer le bloc dans la rangée sélectionnée.',
|
||||
'UNABLE_TO_ADD_MODULE' => 'Il n’est pas possible d’ajouter le module dans la colonne sélectionnée.',
|
||||
'DELETE_MODULE_CONFIRM' => 'Êtes-vous sûr de vouloir supprimer le module “%1$s” ?',
|
||||
'DELETE_MODULE_CONFIRM' => 'Êtes-vous sûr de vouloir supprimer le module « %1$s » ?',
|
||||
'MODULE_RESET_SUCCESS' => 'Les paramètres du module ont été réinitialisés avec succès.',
|
||||
'MODULE_RESET_CONFIRM' => 'Êtes-vous sûr de vouloir réinitialiser les paramètres du module “%1$s” ?',
|
||||
'MODULE_RESET_CONFIRM' => 'Êtes-vous sûr de vouloir réinitialiser les paramètres du module « %1$s » ?',
|
||||
'MODULE_NOT_EXISTS' => 'Le module sélectionné n’existe pas.',
|
||||
|
||||
'MODULE_OPTIONS' => 'Options des modules',
|
||||
@@ -75,18 +75,20 @@ $lang = array_merge($lang, array(
|
||||
'MODULE_STATUS' => 'Activer le module',
|
||||
'MODULE_ADD_ONCE' => 'Ce module ne peut être ajouté qu’une seule fois.',
|
||||
'MODULE_IMAGE_ERROR' => 'Il y avait une erreur lors de la vérification de l’image du module:',
|
||||
'UNKNOWN_MODULE_METHOD' => 'Le système de module du module “%1$s” ne peut être résolu.',
|
||||
'UNKNOWN_MODULE_METHOD' => 'Le système de module du module « %1$s » ne peut être résolu.',
|
||||
|
||||
// general
|
||||
'ACP_PORTAL_CONFIG_INFO' => 'Paramètres généraux',
|
||||
'ACP_PORTAL_GENERAL_TITLE' => 'Administration du portail',
|
||||
'ACP_PORTAL_GENERAL_TITLE_EXP' => 'Merci d’avoir choisi le portail Board3 ! C’est ici que vous pouvez gérer la page de votre portail. Les options ci-dessous vous permettent de personnaliser les différents paramètres généraux.',
|
||||
'ACP_PORTAL_SHOW_ALL' => 'Afficher le portail sur toutes les pages',
|
||||
'ACP_PORTAL_SHOW_ALL_EXP' => 'Afficher le portail sur toutes les pages.',
|
||||
'PORTAL_ENABLE' => 'Activer le portail',
|
||||
'PORTAL_ENABLE_EXP' => 'Activer / désactiver tout le portail.',
|
||||
'PORTAL_LEFT_COLUMN' => 'Activer la colonne de gauche',
|
||||
'PORTAL_LEFT_COLUMN_EXP' => 'Changer sur “Non” si vous souhaitez désactiver la colonne de gauche.',
|
||||
'PORTAL_LEFT_COLUMN_EXP' => 'Changer sur « Non » si vous souhaitez désactiver la colonne de gauche.',
|
||||
'PORTAL_RIGHT_COLUMN' => 'Activer la colonne de droite',
|
||||
'PORTAL_RIGHT_COLUMN_EXP' => 'Changer sur “Non” si vous souhaitez désactiver la colonne de droite.',
|
||||
'PORTAL_RIGHT_COLUMN_EXP' => 'Changer sur « Non » si vous souhaitez désactiver la colonne de droite.',
|
||||
'PORTAL_VERSION_CHECK' => 'Vérification de la version du portail',
|
||||
'PORTAL_DISPLAY_JUMPBOX' => 'Afficher l’accès rapide aux forums',
|
||||
'PORTAL_DISPLAY_JUMPBOX_EXP' => 'Afficher l’accès rapide aux forums sur le portail. L’accès rapide aux forums ne sera affiché que si il est également activé dans les fonctionnalités du forum.',
|
||||
@@ -95,6 +97,10 @@ $lang = array_merge($lang, array(
|
||||
'PORTAL_LEFT_COLUMN_WIDTH_EXP' => 'Modifier la largeur de la colonne de gauche en pixels; la valeur recommandée est 180 pixels.',
|
||||
'PORTAL_RIGHT_COLUMN_WIDTH' => 'Largeur de la colonne de droite',
|
||||
'PORTAL_RIGHT_COLUMN_WIDTH_EXP' => 'Modifier la largeur de la colonne de droite en pixels; la valeur recommandée est 180 pixels.',
|
||||
'PORTAL_SHOW_ALL_SIDE' => 'Colonne à afficher sur toutes les pages',
|
||||
'PORTAL_SHOW_ALL_SIDE_EXP' => 'Choisir quelle colonne doit s’afficher sur toutes les pages.',
|
||||
'PORTAL_SHOW_ALL_LEFT' => 'Gauche',
|
||||
'PORTAL_SHOW_ALL_RIGHT' => 'Droite',
|
||||
|
||||
'LINK_ADDED' => 'Le lien a été ajouté avec succès',
|
||||
'LINK_UPDATED' => 'Le lien a été mis à jour avec succès',
|
||||
|
||||
@@ -183,6 +183,7 @@ class v210_beta1 extends \phpbb\db\migration\migration
|
||||
$sql = 'SELECT * FROM ' . $this->table_prefix . 'portal_config';
|
||||
$result = $this->db->sql_query_limit($sql, 1);
|
||||
$row = $this->db->sql_fetchrow($result);
|
||||
$this->db->sql_freeresult($result);
|
||||
if (!empty($row))
|
||||
{
|
||||
return;
|
||||
@@ -204,6 +205,7 @@ class v210_beta1 extends \phpbb\db\migration\migration
|
||||
{
|
||||
$groups_ary[$row['group_name']] = $row['group_id'];
|
||||
}
|
||||
$this->db->sql_freeresult($result);
|
||||
|
||||
// set portal config
|
||||
$this->set_portal_config('board3_menu_array_1', serialize(array(
|
||||
|
||||
27
migrations/v210_rc3.php
Normal file
@@ -0,0 +1,27 @@
|
||||
<?php
|
||||
/**
|
||||
*
|
||||
* @package Board3 Portal v2.1
|
||||
* @copyright (c) 2015 Board3 Group ( www.board3.de )
|
||||
* @license http://opensource.org/licenses/gpl-2.0.php GNU General Public License v2
|
||||
*
|
||||
*/
|
||||
|
||||
namespace board3\portal\migrations;
|
||||
|
||||
class v210_rc3 extends \phpbb\db\migration\migration
|
||||
{
|
||||
static public function depends_on()
|
||||
{
|
||||
return array('\board3\portal\migrations\v210_rc2');
|
||||
}
|
||||
|
||||
public function update_data()
|
||||
{
|
||||
return array(
|
||||
array('config.update', array('board3_portal_version', '2.1.0-rc3')),
|
||||
array('config.add', array('board3_show_all_pages', 0)),
|
||||
array('config.add', array('board3_show_all_side', 0)),
|
||||
);
|
||||
}
|
||||
}
|
||||
@@ -124,7 +124,7 @@ class announcements extends module_base
|
||||
$total_announcements = 1;
|
||||
|
||||
// Fetch announcements from portal functions.php with check if "read full" is requested.
|
||||
$portal_announcement_length = ($announcement < 0) ? $this->config['board3_announcements_length_' . $module_id] : 0;
|
||||
$portal_announcement_length = ($announcement < 0 && !$this->config['board3_announcements_style_' . $module_id]) ? $this->config['board3_announcements_length_' . $module_id] : 0;
|
||||
$this->fetch_posts->set_module_id($module_id);
|
||||
$fetch_news = $this->fetch_posts->get_posts(
|
||||
$this->config['board3_global_announcements_forum_' . $module_id],
|
||||
@@ -154,7 +154,7 @@ class announcements extends module_base
|
||||
);
|
||||
|
||||
// Any announcements present? If not terminate it here.
|
||||
if (sizeof($fetch_news) == 0)
|
||||
if (sizeof($fetch_news) < 3)
|
||||
{
|
||||
$this->template->assign_block_vars('announcements', $announcements_row);
|
||||
|
||||
@@ -225,7 +225,7 @@ class announcements extends module_base
|
||||
AND topic_moved_id = 0
|
||||
' . $post_time . '
|
||||
' . $str_where;
|
||||
$result = $this->db->sql_query($sql);
|
||||
$result = $this->db->sql_query($sql, 300);
|
||||
$total_announcements = (int) $this->db->sql_fetchfield('num_topics');
|
||||
$this->db->sql_freeresult($result);
|
||||
}
|
||||
|
||||
@@ -53,10 +53,10 @@ class attachments extends module_base
|
||||
/** @var \phpbb\request\request */
|
||||
protected $request;
|
||||
|
||||
/** @var \phpbb\template */
|
||||
/** @var \phpbb\template\template */
|
||||
protected $template;
|
||||
|
||||
/** @var \phpbb\db\driver */
|
||||
/** @var \phpbb\db\driver\driver_interface */
|
||||
protected $db;
|
||||
|
||||
/** @var string PHP file extension */
|
||||
@@ -74,8 +74,8 @@ class attachments extends module_base
|
||||
* @param \phpbb\auth\auth $auth phpBB auth service
|
||||
* @param \phpbb\config\config $config phpBB config
|
||||
* @param \board3\portal\includes\modules_helper $helper Modules helper
|
||||
* @param \phpbb\template $template phpBB template
|
||||
* @param \phpbb\db\driver $db Database driver
|
||||
* @param \phpbb\template\template $template phpBB template
|
||||
* @param \phpbb\db\driver\driver_interface $db Database driver
|
||||
* @param \phpbb\request\request $request phpBB request
|
||||
* @param string $phpEx php file extension
|
||||
* @param string $phpbb_root_path phpBB root path
|
||||
@@ -187,6 +187,7 @@ class attachments extends module_base
|
||||
'title' => $row['extension'],
|
||||
);
|
||||
}
|
||||
$this->db->sql_freeresult($result);
|
||||
|
||||
$selected = $this->get_selected_filetypes($module_id);
|
||||
|
||||
@@ -281,7 +282,7 @@ class attachments extends module_base
|
||||
' . $where . '
|
||||
ORDER BY
|
||||
filetime ' . ((!$this->config['display_order']) ? 'DESC' : 'ASC') . ', post_msg_id ASC';
|
||||
$result = $this->db->sql_query_limit($sql, $this->config['board3_attachments_number_' . $module_id]);
|
||||
$result = $this->db->sql_query_limit($sql, $this->config['board3_attachments_number_' . $module_id], 0, 600);
|
||||
|
||||
while ($row = $this->db->sql_fetchrow($result))
|
||||
{
|
||||
|
||||
@@ -119,7 +119,7 @@ class birthday_list extends module_base
|
||||
'ORDER BY' => $order_by,
|
||||
);
|
||||
$sql = $this->db->sql_build_query('SELECT', $sql_array);
|
||||
$result = $this->db->sql_query($sql);
|
||||
$result = $this->db->sql_query($sql, 3600);
|
||||
$today = sprintf('%2d-%2d-', $now['mday'], $now['mon']);
|
||||
|
||||
while ($row = $this->db->sql_fetchrow($result))
|
||||
|
||||
@@ -176,7 +176,7 @@ class calendar extends module_base
|
||||
$this->time = $this->user->create_datetime();
|
||||
$now = phpbb_gmgetdate($this->time->getTimestamp() + $this->time->getOffset());
|
||||
$today_timestamp = $now[0];
|
||||
$mini_cal_today = date('Ymd', $today_timestamp - date('Z'));
|
||||
$mini_cal_today = date('Ymd', $today_timestamp);
|
||||
$this->stamp = (int) $today_timestamp;
|
||||
$s_cal_month = ($this->mini_cal_month != 0) ? $this->mini_cal_month . ' month' : $mini_cal_today;
|
||||
$this->get_month($s_cal_month);
|
||||
@@ -188,8 +188,8 @@ class calendar extends module_base
|
||||
// output our general calendar bits
|
||||
$down = $this->mini_cal_month - 1;
|
||||
$up = $this->mini_cal_month + 1;
|
||||
$prev_month = '<a href="' . $this->modules_helper->route('board3_portal_controller') . "?m$module_id=$down#minical$module_id" . '"><img src="' . $this->portal_root_path . 'styles/' . $this->user->style['style_path'] . '/theme/images/portal/cal_icon_left_arrow.png' . '" title="' . $this->user->lang['VIEW_PREVIOUS_MONTH'] . '" height="16" width="16" alt="<<" /></a>';
|
||||
$next_month = '<a href="' . $this->modules_helper->route('board3_portal_controller') . "?m$module_id=$up#minical$module_id" . '"><img src="' . $this->portal_root_path . 'styles/' . $this->user->style['style_path'] . '/theme/images/portal/cal_icon_right_arrow.png' . '" title="' . $this->user->lang['VIEW_NEXT_MONTH'] . '" height="16" width="16" alt=">>" /></a>';
|
||||
$prev_month = '<a href="' . $this->modules_helper->route('board3_portal_controller') . "?m$module_id=$down#minical$module_id" . '" rel="nofollow"><img src="' . $this->portal_root_path . 'styles/' . $this->user->style['style_path'] . '/theme/images/portal/cal_icon_left_arrow.png' . '" title="' . $this->user->lang['VIEW_PREVIOUS_MONTH'] . '" height="16" width="16" alt="<<" /></a>';
|
||||
$next_month = '<a href="' . $this->modules_helper->route('board3_portal_controller') . "?m$module_id=$up#minical$module_id" . '" rel="nofollow"><img src="' . $this->portal_root_path . 'styles/' . $this->user->style['style_path'] . '/theme/images/portal/cal_icon_right_arrow.png' . '" title="' . $this->user->lang['VIEW_NEXT_MONTH'] . '" height="16" width="16" alt=">>" /></a>';
|
||||
|
||||
$this->template->assign_block_vars('minical', array(
|
||||
'S_SUNDAY_FIRST' => ($this->config['board3_sunday_first_' . $module_id]) ? true : false,
|
||||
@@ -716,11 +716,13 @@ class calendar extends module_base
|
||||
*
|
||||
* @param string $serial_str Serialized string
|
||||
*
|
||||
* @return array Unserialized array
|
||||
* @return array Unserialized string
|
||||
*/
|
||||
protected function utf_unserialize($serial_str)
|
||||
private function utf_unserialize($serial_str)
|
||||
{
|
||||
$out = preg_replace('!s:(\d+):"(.*?)";!se', "'s:'.strlen('$2').':\"$2\";'", $serial_str );
|
||||
$out = preg_replace_callback('!s:(\d+):"(.*?)";!s', function ($result) {
|
||||
return 's:' . strlen($result[2]) . ":\"{$result[2]}\";";
|
||||
}, $serial_str);
|
||||
return unserialize($out);
|
||||
}
|
||||
|
||||
|
||||
@@ -49,10 +49,10 @@ class latest_bots extends module_base
|
||||
/** @var \phpbb\config\config */
|
||||
protected $config;
|
||||
|
||||
/** @var \phpbb\db\driver */
|
||||
/** @var \phpbb\db\driver\driver_interface */
|
||||
protected $db;
|
||||
|
||||
/** @var \phpbb\template */
|
||||
/** @var \phpbb\template\template */
|
||||
protected $template;
|
||||
|
||||
/** @var \phpbb\user */
|
||||
@@ -62,8 +62,8 @@ class latest_bots extends module_base
|
||||
* Construct a latest bots object
|
||||
*
|
||||
* @param \phpbb\config\config $config phpBB config
|
||||
* @param \phpbb\db\driver $db phpBB db driver
|
||||
* @param \phpbb\template $template phpBB template
|
||||
* @param \phpbb\db\driver\driver_interface $db phpBB db driver
|
||||
* @param \phpbb\template\template $template phpBB template
|
||||
* @param \phpbb\user $user phpBB user object
|
||||
*/
|
||||
public function __construct($config, $db, $template, $user)
|
||||
@@ -85,7 +85,7 @@ class latest_bots extends module_base
|
||||
WHERE user_type = ' . USER_IGNORE . '
|
||||
AND user_lastvisit > 0
|
||||
ORDER BY user_lastvisit DESC';
|
||||
$result = $this->db->sql_query_limit($sql, $this->config['board3_last_visited_bots_number_' . $module_id]);
|
||||
$result = $this->db->sql_query_limit($sql, $this->config['board3_last_visited_bots_number_' . $module_id], 0, 600);
|
||||
|
||||
$show_module = false;
|
||||
|
||||
|
||||
@@ -44,10 +44,10 @@ class latest_members extends module_base
|
||||
/** @var \phpbb\config\config */
|
||||
protected $config;
|
||||
|
||||
/** @var \phpbb\db\driver */
|
||||
/** @var \phpbb\db\driver\driver_interface */
|
||||
protected $db;
|
||||
|
||||
/** @var \phpbb\template */
|
||||
/** @var \phpbb\template\template */
|
||||
protected $template;
|
||||
|
||||
/** @var \phpbb\user */
|
||||
@@ -57,8 +57,8 @@ class latest_members extends module_base
|
||||
* Construct a latest_members object
|
||||
*
|
||||
* @param \phpbb\config\config $config phpBB config
|
||||
* @param \phpbb\db\driver $db phpBB db driver
|
||||
* @param \phpbb\template $template phpBB template
|
||||
* @param \phpbb\db\driver\driver_interface $db phpBB db driver
|
||||
* @param \phpbb\template\template $template phpBB template
|
||||
* @param \phpbb\user $user phpBB user object
|
||||
*/
|
||||
public function __construct($config, $db, $template, $user)
|
||||
@@ -79,7 +79,7 @@ class latest_members extends module_base
|
||||
WHERE user_type <> ' . USER_IGNORE . '
|
||||
AND user_inactive_time = 0
|
||||
ORDER BY user_regdate DESC';
|
||||
$result = $this->db->sql_query_limit($sql, $this->config['board3_max_last_member_' . $module_id]);
|
||||
$result = $this->db->sql_query_limit($sql, $this->config['board3_max_last_member_' . $module_id], 0, 600);
|
||||
|
||||
while(($row = $this->db->sql_fetchrow($result)) && ($row['username']))
|
||||
{
|
||||
|
||||
@@ -91,6 +91,7 @@ class leaders extends module_base
|
||||
{
|
||||
// Display a listing of board admins, moderators
|
||||
$this->user->add_lang('groups');
|
||||
$order_legend = ($this->config['legend_sort_groupname']) ? 'group_name' : 'group_legend';
|
||||
|
||||
if($this->config['board3_leaders_ext_' . $module_id])
|
||||
{
|
||||
@@ -99,14 +100,14 @@ class leaders extends module_base
|
||||
|
||||
if ($this->auth->acl_gets('a_group', 'a_groupadd', 'a_groupdel'))
|
||||
{
|
||||
$sql = 'SELECT group_id, group_name, group_colour, group_type
|
||||
$sql = 'SELECT group_id, group_name, group_colour, group_type, group_legend
|
||||
FROM ' . GROUPS_TABLE . '
|
||||
WHERE group_legend >= 1
|
||||
ORDER BY group_name ASC';
|
||||
ORDER BY ' . $order_legend . ' ASC';
|
||||
}
|
||||
else
|
||||
{
|
||||
$sql = 'SELECT g.group_id, g.group_name, g.group_colour, g.group_type
|
||||
$sql = 'SELECT g.group_id, g.group_name, g.group_colour, g.group_type, g.group_legend
|
||||
FROM ' . GROUPS_TABLE . ' g
|
||||
LEFT JOIN ' . USER_GROUP_TABLE . ' ug
|
||||
ON (
|
||||
@@ -116,9 +117,9 @@ class leaders extends module_base
|
||||
)
|
||||
WHERE g.group_legend >= 1
|
||||
AND (g.group_type <> ' . GROUP_HIDDEN . ' OR ug.user_id = ' . $this->user->data['user_id'] . ')
|
||||
ORDER BY g.group_name ASC';
|
||||
ORDER BY g.' . $order_legend . ' ASC';
|
||||
}
|
||||
$result = $this->db->sql_query($sql);
|
||||
$result = $this->db->sql_query($sql, 600);
|
||||
|
||||
while ($row = $this->db->sql_fetchrow($result))
|
||||
{
|
||||
@@ -144,7 +145,7 @@ class leaders extends module_base
|
||||
ug.user_id = u.user_id
|
||||
AND '. $this->db->sql_in_set('ug.group_id', $legends) . '
|
||||
ORDER BY u.username_clean ASC';
|
||||
$result = $this->db->sql_query($sql);
|
||||
$result = $this->db->sql_query($sql, 600);
|
||||
|
||||
while ($row = $this->db->sql_fetchrow($result))
|
||||
{
|
||||
@@ -187,7 +188,7 @@ class leaders extends module_base
|
||||
else
|
||||
{
|
||||
$sql = $this->db->sql_build_query('SELECT', array(
|
||||
'SELECT' => 'u.user_id, u.group_id as default_group, u.username, u.user_colour, u.user_allow_pm, g.group_id, g.group_name, g.group_colour, g.group_type, ug.user_id as ug_user_id',
|
||||
'SELECT' => 'u.user_id, u.group_id as default_group, u.username, u.user_colour, u.user_allow_pm, g.group_id, g.group_name, g.group_colour, g.group_type, g.group_legend, ug.user_id as ug_user_id',
|
||||
'FROM' => array(
|
||||
USERS_TABLE => 'u',
|
||||
GROUPS_TABLE => 'g'
|
||||
@@ -198,10 +199,10 @@ class leaders extends module_base
|
||||
'ON' => 'ug.group_id = g.group_id AND ug.user_pending = 0 AND ug.user_id = ' . $this->user->data['user_id']
|
||||
)),
|
||||
'WHERE' => 'u.group_id = g.group_id AND ' . $this->db->sql_in_set('g.group_name', array('ADMINISTRATORS', 'GLOBAL_MODERATORS')),
|
||||
'ORDER_BY' => 'g.group_name ASC, u.username_clean ASC'
|
||||
'ORDER_BY' => 'g.' . $order_legend . ' ASC, u.username_clean ASC'
|
||||
));
|
||||
|
||||
$result = $this->db->sql_query($sql);
|
||||
$result = $this->db->sql_query($sql, 600);
|
||||
|
||||
while ($row = $this->db->sql_fetchrow($result))
|
||||
{
|
||||
|
||||
@@ -470,7 +470,9 @@ class links extends module_base
|
||||
*/
|
||||
private function utf_unserialize($serial_str)
|
||||
{
|
||||
$out = preg_replace('!s:(\d+):"(.*?)";!se', "'s:'.strlen('$2').':\"$2\";'", $serial_str);
|
||||
$out = preg_replace_callback('!s:(\d+):"(.*?)";!s', function ($result) {
|
||||
return 's:' . strlen($result[2]) . ":\"{$result[2]}\";";
|
||||
}, $serial_str);
|
||||
return unserialize($out);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -534,7 +534,9 @@ class main_menu extends module_base
|
||||
*/
|
||||
private function utf_unserialize($serial_str)
|
||||
{
|
||||
$out = preg_replace('!s:(\d+):"(.*?)";!se', "'s:'.strlen('$2').':\"$2\";'", $serial_str);
|
||||
$out = preg_replace_callback('!s:(\d+):"(.*?)";!s', function ($result) {
|
||||
return 's:' . strlen($result[2]) . ":\"{$result[2]}\";";
|
||||
}, $serial_str);
|
||||
return unserialize($out);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -125,7 +125,7 @@ class news extends module_base
|
||||
$total_news = 1;
|
||||
|
||||
// Fetch news from portal functions.php with check if "read full" is requested.
|
||||
$portal_news_length = ($news < 0) ? $this->config['board3_news_length_' . $module_id] : 0;
|
||||
$portal_news_length = ($news < 0 && !$this->config['board3_news_style_' . $module_id]) ? $this->config['board3_news_length_' . $module_id] : 0;
|
||||
$this->fetch_posts->set_module_id($module_id);
|
||||
$fetch_news = $this->fetch_posts->get_posts(
|
||||
$this->config['board3_news_forum_' . $module_id],
|
||||
@@ -218,7 +218,7 @@ class news extends module_base
|
||||
AND topic_visibility = ' . ITEM_APPROVED . '
|
||||
AND topic_moved_id = 0
|
||||
' . $str_where;
|
||||
$result = $this->db->sql_query($sql);
|
||||
$result = $this->db->sql_query($sql, 300);
|
||||
$total_news = (int) $this->db->sql_fetchfield('num_topics');
|
||||
$this->db->sql_freeresult($result);
|
||||
}
|
||||
@@ -398,7 +398,7 @@ class news extends module_base
|
||||
'S_HAS_ATTACHMENTS' => (!empty($fetch_news[$i]['attachments'])) ? true : false,
|
||||
));
|
||||
|
||||
$this->pagination->generate_template_pagination($view_topic_url, 'news_row.pagination', 'start', $fetch_news[$i]['topic_replies'] + 1, $this->config['posts_per_page'], 1, true, true);
|
||||
$this->pagination->generate_template_pagination($view_topic_url, 'news.news_row.pagination', 'start', $fetch_news[$i]['topic_replies'] + 1, $this->config['posts_per_page'], 1);
|
||||
|
||||
if(!empty($fetch_news[$i]['attachments']))
|
||||
{
|
||||
|
||||
@@ -121,7 +121,7 @@ class recent extends module_base
|
||||
$forum_sql = ' AND ' . $this->db->sql_in_set('t.forum_id', $forum_ary, true);
|
||||
}
|
||||
|
||||
$result = $this->db->sql_query_limit($sql, 1);
|
||||
$result = $this->db->sql_query_limit($sql, 1, 0, 600);
|
||||
$g_forum_id = (int) $this->db->sql_fetchfield('forum_id');
|
||||
$this->db->sql_freeresult($result);
|
||||
|
||||
@@ -134,9 +134,9 @@ class recent extends module_base
|
||||
AND topic_visibility = ' . ITEM_APPROVED . '
|
||||
AND (topic_type = ' . POST_ANNOUNCE . ' OR topic_type = ' . POST_GLOBAL . ')
|
||||
AND topic_moved_id = 0
|
||||
' . $sql_where . '' . $forum_sql . '
|
||||
' . $sql_where . $forum_sql . '
|
||||
ORDER BY topic_time DESC';
|
||||
$result = $this->db->sql_query_limit($sql, $this->config['board3_max_topics_' . $module_id]);
|
||||
$result = $this->db->sql_query_limit($sql, $this->config['board3_max_topics_' . $module_id], 0 , 600);
|
||||
|
||||
while(($row = $this->db->sql_fetchrow($result)) && ($row['topic_title']))
|
||||
{
|
||||
@@ -160,9 +160,9 @@ class recent extends module_base
|
||||
WHERE topic_visibility = ' . ITEM_APPROVED . '
|
||||
AND topic_posts_approved >' . $this->config['hot_threshold'] . '
|
||||
AND topic_moved_id = 0
|
||||
' . $sql_where . '' . $forum_sql . '
|
||||
' . $sql_where . $forum_sql . '
|
||||
ORDER BY topic_time DESC';
|
||||
$result = $this->db->sql_query_limit($sql, $this->config['board3_max_topics_' . $module_id]);
|
||||
$result = $this->db->sql_query_limit($sql, $this->config['board3_max_topics_' . $module_id], 0, 600);
|
||||
|
||||
while(($row = $this->db->sql_fetchrow($result)) && ($row['topic_title']))
|
||||
{
|
||||
@@ -187,9 +187,9 @@ class recent extends module_base
|
||||
AND topic_visibility = ' . ITEM_APPROVED . '
|
||||
AND topic_type = ' . POST_NORMAL . '
|
||||
AND topic_moved_id = 0
|
||||
' . $sql_where . '' . $forum_sql . '
|
||||
' . $sql_where . $forum_sql . '
|
||||
ORDER BY topic_time DESC';
|
||||
$result = $this->db->sql_query_limit($sql, $this->config['board3_max_topics_' . $module_id]);
|
||||
$result = $this->db->sql_query_limit($sql, $this->config['board3_max_topics_' . $module_id], 0, 600);
|
||||
|
||||
while(($row = $this->db->sql_fetchrow($result)) && ($row['topic_title']))
|
||||
{
|
||||
|
||||
@@ -75,8 +75,6 @@ class search extends module_base
|
||||
*/
|
||||
public function get_template_side($module_id)
|
||||
{
|
||||
$this->template->assign_var('S_SEARCH_ACTION', append_sid("{$this->phpbb_root_path}search.{$this->php_ext}"));
|
||||
|
||||
return 'search_side.html';
|
||||
}
|
||||
|
||||
|
||||
@@ -90,7 +90,7 @@ class stylechanger extends module_base
|
||||
FROM ' . STYLES_TABLE . '
|
||||
WHERE style_active = 1
|
||||
ORDER BY LOWER(style_name) ASC';
|
||||
$result = $this->db->sql_query($sql);
|
||||
$result = $this->db->sql_query($sql, 3600);
|
||||
while ($row = $this->db->sql_fetchrow($result))
|
||||
{
|
||||
$style = $this->request->variable('style', 0);
|
||||
@@ -113,7 +113,7 @@ class stylechanger extends module_base
|
||||
|
||||
// Assign specific vars
|
||||
$this->template->assign_vars(array(
|
||||
'S_STYLE_OPTIONS' => ($this->config['override_user_style'] || $style_count < 2) ? '' : style_select($this->user->data['user_style']),
|
||||
'S_STYLE_OPTIONS' => ($this->config['override_user_style'] || $style_count < 2) ? '' : $style_select,
|
||||
));
|
||||
|
||||
return 'stylechanger_side.html';
|
||||
|
||||
@@ -44,10 +44,10 @@ class topposters extends module_base
|
||||
/** @var \phpbb\config\config */
|
||||
protected $config;
|
||||
|
||||
/** @var \phpbb\db\driver */
|
||||
/** @var \phpbb\db\driver\driver_interface */
|
||||
protected $db;
|
||||
|
||||
/** @var \phpbb\template */
|
||||
/** @var \phpbb\template\template */
|
||||
protected $template;
|
||||
|
||||
/** @var string PHP file extension */
|
||||
@@ -60,8 +60,8 @@ class topposters extends module_base
|
||||
* Construct a topposers object
|
||||
*
|
||||
* @param \phpbb\config\config $config phpBB config
|
||||
* @param \phpbb\db\driver $db phpBB db driver
|
||||
* @param \phpbb\template $template phpBB template
|
||||
* @param \phpbb\db\driver\driver_interface $db phpBB db driver
|
||||
* @param \phpbb\template\template $template phpBB template
|
||||
* @param string $phpbb_root_path phpBB root path
|
||||
* @param string $phpEx php file extension
|
||||
*/
|
||||
@@ -85,7 +85,7 @@ class topposters extends module_base
|
||||
AND user_posts <> 0
|
||||
AND username <> ''
|
||||
ORDER BY user_posts DESC";
|
||||
$result = $this->db->sql_query_limit($sql, $this->config['board3_topposters_' . $module_id]);
|
||||
$result = $this->db->sql_query_limit($sql, $this->config['board3_topposters_' . $module_id], 0, 600);
|
||||
|
||||
while (($row = $this->db->sql_fetchrow($result)))
|
||||
{
|
||||
|
||||
@@ -125,13 +125,13 @@ class user_menu extends module_base
|
||||
$m_approve_fid_sql = ' AND p.post_visibility = 1';
|
||||
}
|
||||
|
||||
$sql = 'SELECT COUNT(distinct t.topic_id) as total
|
||||
$sql = 'SELECT COUNT(DISTINCT t.topic_id) as total
|
||||
FROM ' . TOPICS_TABLE . ' t
|
||||
WHERE t.topic_last_post_time > ' . $this->user->data['user_lastvisit'] . '
|
||||
AND t.topic_moved_id = 0
|
||||
' . str_replace(array('p.', 'post_'), array('t.', 'topic_'), $m_approve_fid_sql) . '
|
||||
' . ((sizeof($ex_fid_ary)) ? 'AND ' . $this->db->sql_in_set('t.forum_id', $ex_fid_ary, true) : '');
|
||||
$result = $this->db->sql_query($sql);
|
||||
$result = $this->db->sql_query($sql, 600);
|
||||
$new_posts_count = (int) $this->db->sql_fetchfield('total');
|
||||
$this->db->sql_freeresult($result);
|
||||
|
||||
|
||||
@@ -50,10 +50,13 @@ class whois_online extends module_base
|
||||
/** @var \phpbb\auth\auth */
|
||||
protected $auth;
|
||||
|
||||
/** @var \phpbb\db\driver */
|
||||
/** @var \phpbb\config\config */
|
||||
protected $config;
|
||||
|
||||
/** @var \phpbb\db\driver\driver_interface */
|
||||
protected $db;
|
||||
|
||||
/** @var \phpbb\template */
|
||||
/** @var \phpbb\template\template */
|
||||
protected $template;
|
||||
|
||||
/** @var \phpbb\user */
|
||||
@@ -69,15 +72,17 @@ class whois_online extends module_base
|
||||
* Construct a user menu object
|
||||
*
|
||||
* @param \phpbb\auth\auth $auth phpBB auth
|
||||
* @param \phpbb\db\driver $db phpBB db driver
|
||||
* @param \phpbb\template $template phpBB template
|
||||
* @param \phpbb\config\config $config phpBB config
|
||||
* @param \phpbb\db\driver\driver_interface $db phpBB db driver
|
||||
* @param \phpbb\template\template $template phpBB template
|
||||
* @param \phpbb\user $user phpBB user
|
||||
* @param string $phpbb_root_path phpBB root path
|
||||
* @param string $phpEx php file extension
|
||||
*/
|
||||
public function __construct($auth, $db, $template, $user, $phpbb_root_path, $phpEx)
|
||||
public function __construct($auth, $config, $db, $template, $user, $phpbb_root_path, $phpEx)
|
||||
{
|
||||
$this->auth = $auth;
|
||||
$this->config = $config;
|
||||
$this->db = $db;
|
||||
$this->template = $template;
|
||||
$this->user = $user;
|
||||
@@ -90,13 +95,15 @@ class whois_online extends module_base
|
||||
*/
|
||||
public function get_template_center($module_id)
|
||||
{
|
||||
$order_legend = ($this->config['legend_sort_groupname']) ? 'group_name' : 'group_legend';
|
||||
|
||||
// Grab group details for legend display
|
||||
if ($this->auth->acl_gets('a_group', 'a_groupadd', 'a_groupdel'))
|
||||
{
|
||||
$sql = 'SELECT group_id, group_name, group_colour, group_type
|
||||
FROM ' . GROUPS_TABLE . '
|
||||
WHERE group_legend > 0
|
||||
ORDER BY group_name ASC';
|
||||
ORDER BY ' . $order_legend . ' ASC';
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -110,7 +117,7 @@ class whois_online extends module_base
|
||||
)
|
||||
WHERE g.group_legend > 0
|
||||
AND (g.group_type <> ' . GROUP_HIDDEN . ' OR ug.user_id = ' . $this->user->data['user_id'] . ')
|
||||
ORDER BY g.group_name ASC';
|
||||
ORDER BY g.' . $order_legend . ' ASC';
|
||||
}
|
||||
$result = $this->db->sql_query($sql);
|
||||
|
||||
|
||||
@@ -19,7 +19,7 @@ class fetch_posts
|
||||
|
||||
/**
|
||||
* phpBB cache
|
||||
* @var \phpbb\cache\driver
|
||||
* @var \phpbb\cache\driver\driver_interface
|
||||
*/
|
||||
protected $cache;
|
||||
|
||||
@@ -31,7 +31,7 @@ class fetch_posts
|
||||
|
||||
/**
|
||||
* phpBB db driver
|
||||
* @var \phpbb\db\driver_interface
|
||||
* @var \phpbb\db\driver\driver_interface
|
||||
*/
|
||||
protected $db;
|
||||
|
||||
@@ -263,13 +263,14 @@ class fetch_posts
|
||||
$sql_array['SELECT'] .= ', tp.topic_posted';
|
||||
$sql = $this->db->sql_build_query('SELECT', $sql_array);
|
||||
|
||||
// Cache queries for 10 minutes
|
||||
if ($number_of_posts != 0)
|
||||
{
|
||||
$result = $this->db->sql_query_limit($sql, $number_of_posts, $start);
|
||||
$result = $this->db->sql_query_limit($sql, $number_of_posts, $start, 600);
|
||||
}
|
||||
else
|
||||
{
|
||||
$result = $this->db->sql_query($sql);
|
||||
$result = $this->db->sql_query($sql, 600);
|
||||
}
|
||||
|
||||
return $result;
|
||||
@@ -320,8 +321,8 @@ class fetch_posts
|
||||
'icon_id' => $row['icon_id'],
|
||||
'topic_status' => $row['topic_status'],
|
||||
'forum_id' => $row['forum_id'],
|
||||
'topic_replies' => $row['topic_posts_approved'] + $row['topic_posts_unapproved'] + $row['topic_posts_softdeleted'],
|
||||
'topic_replies_real' => $row['topic_posts_approved'],
|
||||
'topic_replies' => $row['topic_posts_approved'] + $row['topic_posts_unapproved'] + $row['topic_posts_softdeleted'] - 1,
|
||||
'topic_replies_real' => $row['topic_posts_approved'] - 1,
|
||||
'topic_time' => $this->user->format_date($row['post_time']),
|
||||
'topic_last_post_time' => $row['topic_last_post_time'],
|
||||
'topic_title' => $row['topic_title'],
|
||||
@@ -623,7 +624,7 @@ class fetch_posts
|
||||
*/
|
||||
protected function format_message($row, $text_length, &$posts_striped)
|
||||
{
|
||||
if (($text_length !== 0) && (strlen($row['post_text']) > $text_length))
|
||||
if ($text_length > 0 && (strlen($row['post_text']) > $text_length))
|
||||
{
|
||||
$message = str_replace(array("\n", "\r"), array('<br />', "\n"), $row['post_text']);
|
||||
$message = get_sub_taged_string($message, $row['bbcode_uid'], $text_length);
|
||||
|
||||
@@ -20,6 +20,9 @@ class manager
|
||||
/** @var \phpbb\cache\service */
|
||||
protected $cache;
|
||||
|
||||
/** @var \board3\portal\controller\helper */
|
||||
protected $controller_helper;
|
||||
|
||||
/** @var \board3\portal\portal\columns */
|
||||
protected $portal_columns;
|
||||
|
||||
@@ -55,6 +58,7 @@ class manager
|
||||
*
|
||||
* @param \phpbb\cache\service $cache phpBB cache
|
||||
* @param \phpbb\db\driver\driver_interface $db Database driver
|
||||
* @param \board3\portal\controller\helper $controller_helper Board3 Portal controller helper
|
||||
* @param \board3\portal\portal\columns $portal_columns Portal columns helper
|
||||
* @param \board3\portal\includes\helper $portal_helper Portal helper
|
||||
* @param \board3\portal\portal\modules\constraints_handler $constraints_handler Modules constraints handler
|
||||
@@ -62,10 +66,11 @@ class manager
|
||||
* @param \phpbb\request\request_interface $request phpBB request
|
||||
* @param \phpbb\user $user phpBB user
|
||||
*/
|
||||
public function __construct($cache, driver_interface $db, columns $portal_columns, helper $portal_helper, constraints_handler $constraints_handler, database_handler $database_handler, request_interface $request, $user)
|
||||
public function __construct($cache, driver_interface $db, \board3\portal\controller\helper $controller_helper, columns $portal_columns, helper $portal_helper, constraints_handler $constraints_handler, database_handler $database_handler, request_interface $request, $user)
|
||||
{
|
||||
$this->cache = $cache;
|
||||
$this->db = $db;
|
||||
$this->controller_helper = $controller_helper;
|
||||
$this->portal_columns = $portal_columns;
|
||||
$this->portal_helper = $portal_helper;
|
||||
$this->constraints_handler = $constraints_handler;
|
||||
@@ -215,7 +220,7 @@ class manager
|
||||
trigger_error($this->user->lang['UNABLE_TO_MOVE' . (($is_row) ? '_ROW' : '')] . adm_back_link($this->u_action));
|
||||
}
|
||||
|
||||
$this->cache->destroy('portal_modules');
|
||||
$this->cache->destroy('sql', PORTAL_MODULES_TABLE);
|
||||
|
||||
// Handle ajax requests
|
||||
$this->handle_ajax_request(array('success' => true));
|
||||
@@ -362,7 +367,7 @@ class manager
|
||||
{
|
||||
if ($this->module->get_language())
|
||||
{
|
||||
$this->user->add_lang_ext('board3/portal', 'modules/' . $this->module->get_language());
|
||||
$this->controller_helper->load_module_language($this->module);
|
||||
}
|
||||
$confirm_text = (isset($this->user->lang[$module_data['module_name']])) ? sprintf($this->user->lang['DELETE_MODULE_CONFIRM'], $this->user->lang[$module_data['module_name']]) : sprintf($this->user->lang['DELETE_MODULE_CONFIRM'], utf8_normalize_nfc($module_data['module_name']));
|
||||
confirm_box(false, $confirm_text, build_hidden_fields(array(
|
||||
@@ -375,7 +380,7 @@ class manager
|
||||
}
|
||||
}
|
||||
|
||||
$this->cache->destroy('portal_modules');
|
||||
$this->cache->destroy('sql', PORTAL_MODULES_TABLE);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
|
Before Width: | Height: | Size: 1003 B After Width: | Height: | Size: 1003 B |
|
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 1.1 KiB |
|
Before Width: | Height: | Size: 964 B After Width: | Height: | Size: 964 B |
|
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 1.1 KiB |
|
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 1.1 KiB |
|
Before Width: | Height: | Size: 9.5 KiB After Width: | Height: | Size: 9.5 KiB |
|
Before Width: | Height: | Size: 7.2 KiB After Width: | Height: | Size: 7.2 KiB |
|
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 1.1 KiB |
|
Before Width: | Height: | Size: 738 B After Width: | Height: | Size: 738 B |
|
Before Width: | Height: | Size: 696 B After Width: | Height: | Size: 696 B |
|
Before Width: | Height: | Size: 895 B After Width: | Height: | Size: 895 B |
|
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 1.1 KiB |
|
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 1.1 KiB |
|
Before Width: | Height: | Size: 855 B After Width: | Height: | Size: 855 B |
|
Before Width: | Height: | Size: 879 B After Width: | Height: | Size: 879 B |
|
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 1.1 KiB |
|
Before Width: | Height: | Size: 813 B After Width: | Height: | Size: 813 B |
|
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 1.1 KiB |
|
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 1.1 KiB |
|
Before Width: | Height: | Size: 1.0 KiB After Width: | Height: | Size: 1.0 KiB |
|
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 1.1 KiB |
|
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 1.1 KiB |
@@ -0,0 +1,40 @@
|
||||
<!-- IF S_PORTAL_ALL === true -->
|
||||
</div>
|
||||
</div>
|
||||
<!-- [+] left module area -->
|
||||
<!-- IF S_LEFT_COLUMN -->
|
||||
<div id="portal-left" style="width: {S_PORTAL_LEFT_COLUMN}px;">
|
||||
<!-- BEGIN modules_left -->
|
||||
<!-- DEFINE $TEMPLATE_FILE = '{modules_left.TEMPLATE_FILE}' -->
|
||||
<!-- DEFINE $IMAGE_SRC = '{modules_left.IMAGE_SRC}' -->
|
||||
<!-- DEFINE $IMAGE_WIDTH = '{modules_left.IMAGE_WIDTH}' -->
|
||||
<!-- DEFINE $IMAGE_HEIGHT = '{modules_left.IMAGE_HEIGHT}' -->
|
||||
<!-- DEFINE $CUSTOM_CODE = '{modules_left.CODE}' -->
|
||||
<!-- DEFINE $TITLE = '{modules_left.TITLE}' -->
|
||||
<!-- DEFINE $MODULE_ID = '{modules_left.MODULE_ID}' -->
|
||||
<!-- INCLUDE {$TEMPLATE_FILE} -->
|
||||
<!-- END modules_left -->
|
||||
</div>
|
||||
<!-- ENDIF -->
|
||||
<!-- [-] left module area -->
|
||||
|
||||
<!-- [+] right module area -->
|
||||
<!-- IF S_RIGHT_COLUMN -->
|
||||
<div id="portal-right" style="width: {S_PORTAL_RIGHT_COLUMN}px; margin-<!-- IF S_CONTENT_DIRECTION eq 'rtl' -->right<!-- ELSE -->left<!-- ENDIF -->: -{S_PORTAL_RIGHT_COLUMN}px;">
|
||||
<!-- BEGIN modules_right -->
|
||||
<!-- DEFINE $TEMPLATE_FILE = '{modules_right.TEMPLATE_FILE}' -->
|
||||
<!-- DEFINE $IMAGE_SRC = '{modules_right.IMAGE_SRC}' -->
|
||||
<!-- DEFINE $IMAGE_WIDTH = '{modules_right.IMAGE_WIDTH}' -->
|
||||
<!-- DEFINE $IMAGE_HEIGHT = '{modules_right.IMAGE_HEIGHT}' -->
|
||||
<!-- DEFINE $CUSTOM_CODE = '{modules_right.CODE}' -->
|
||||
<!-- DEFINE $TITLE = '{modules_right.TITLE}' -->
|
||||
<!-- DEFINE $MODULE_ID = '{modules_right.MODULE_ID}' -->
|
||||
<!-- INCLUDE {$TEMPLATE_FILE} -->
|
||||
<!-- END modules_right -->
|
||||
</div>
|
||||
<!-- ENDIF -->
|
||||
<!-- [-] right module area -->
|
||||
<br class="portal-clear" />
|
||||
</div>
|
||||
</div>
|
||||
<!-- ENDIF -->
|
||||
@@ -1,4 +1,9 @@
|
||||
<!-- IF T_EXT_THEME_PATH -->
|
||||
<!-- INCLUDECSS ../theme/portal.css -->
|
||||
<!-- IF S_PORTAL_ALL -->
|
||||
<!-- INCLUDECSS ../theme/portal_all.css -->
|
||||
<!-- INCLUDECSS ../theme/portal_all_responsive.css -->
|
||||
<!-- ELSE -->
|
||||
<!-- INCLUDECSS ../theme/portal_responsive.css -->
|
||||
<!-- ENDIF -->
|
||||
<!-- ENDIF -->
|
||||
|
||||
@@ -0,0 +1,7 @@
|
||||
<!-- IF S_PORTAL_ALL === true -->
|
||||
<div id="portal-page-body">
|
||||
<div id="portal-body">
|
||||
<div class="portal-body-wrapper">
|
||||
<!-- INCLUDE portal/_block_config.html -->
|
||||
<div class="portal-body-center" style="margin: 0 <!-- IF S_RIGHT_COLUMN -->{S_PORTAL_RIGHT_COLUMN}px<!-- ELSE -->-{$BLOCK_DISTANCE}<!-- ENDIF --> 0 <!-- IF S_LEFT_COLUMN -->{S_PORTAL_LEFT_COLUMN}px<!-- ELSE -->-{$BLOCK_DISTANCE}<!-- ENDIF -->; padding: 0 {$BLOCK_DISTANCE};">
|
||||
<!-- ENDIF -->
|
||||
@@ -1,18 +1,18 @@
|
||||
<!-- BEGIN portal_menu -->
|
||||
<!-- IF portal_menu.MODULE_ID eq $MODULE_ID -->
|
||||
{$LR_BLOCK_H_L}<!-- IF $S_BLOCK_ICON --><img src="{$IMAGE_SRC}" width="{$IMAGE_WIDTH}" height="{$IMAGE_HEIGHT}" alt="" /> <!-- ENDIF -->{$TITLE}{$LR_BLOCK_H_R}
|
||||
<div class="portal-navigation">
|
||||
<div class="portal-navigation" role="menu">
|
||||
<!-- BEGIN category -->
|
||||
<div class="menutitle">{portal_menu.category.CAT_TITLE}</div>
|
||||
<ul>
|
||||
<!-- BEGIN links -->
|
||||
<li><a href="{portal_menu.category.links.LINK_URL}" <!-- IF portal_menu.category.links.NEW_WINDOW -->onclick="window.open('{portal_menu.category.links.LINK_URL}'); return false;"<!-- ENDIF -->>{portal_menu.category.links.LINK_TITLE}</a></li>
|
||||
<li><a href="{portal_menu.category.links.LINK_URL}" role="menuitem" <!-- IF portal_menu.category.links.NEW_WINDOW -->onclick="window.open('{portal_menu.category.links.LINK_URL}'); return false;"<!-- ENDIF -->>{portal_menu.category.links.LINK_TITLE}</a></li>
|
||||
<!-- END links -->
|
||||
</ul>
|
||||
<hr class="dashed" />
|
||||
<!-- BEGINELSE -->
|
||||
<ul>
|
||||
<span class="portal-title-span gensmall"><strong>{L_MENU_NO_LINKS}</strong></span><br />
|
||||
<li><span class="portal-title-span gensmall"><strong>{L_MENU_NO_LINKS}</strong></span><br /></li>
|
||||
</ul>
|
||||
<!-- END category -->
|
||||
</div>
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<!-- IF S_STYLE_OPTIONS -->
|
||||
{$LR_BLOCK_H_L}<!-- IF $S_BLOCK_ICON --><img src="{$IMAGE_SRC}" width="{$IMAGE_WIDTH}" height="{$IMAGE_HEIGHT}" alt="" /> <!-- ENDIF -->{$TITLE}{$LR_BLOCK_H_R}
|
||||
<select class="portal-stylechanger-select" name="demo" id="demo" onchange="document.location.href = this.options[this.selectedIndex].value;">
|
||||
<select class="portal-stylechanger-select" name="demo" id="demo" role="listbox" onchange="document.location.href = this.options[this.selectedIndex].value;">
|
||||
{STYLE_SELECT}
|
||||
</select>
|
||||
<br />
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
<!-- DEFINE $S_IN_PORTAL = 1 -->
|
||||
<!-- INCLUDE overall_header.html -->
|
||||
<!-- INCLUDE portal/_block_config.html -->
|
||||
|
||||
@@ -10,9 +9,9 @@
|
||||
</div>
|
||||
<!-- ENDIF -->
|
||||
|
||||
<div id="portal-body">
|
||||
<div id="portal-body" role="grid">
|
||||
<!-- IF S_TOP_COLUMN -->
|
||||
<div id="portal-top">
|
||||
<div id="portal-top" role="gridcell">
|
||||
<!-- [+] top module area -->
|
||||
<ul>
|
||||
<li>
|
||||
@@ -34,7 +33,7 @@
|
||||
<!-- [+] center module area -->
|
||||
<!-- IF S_CENTER_COLUMN -->
|
||||
<div id="portal-center-wrapper">
|
||||
<div id="portal-center" style="margin: 0 <!-- IF S_RIGHT_COLUMN -->{S_PORTAL_RIGHT_COLUMN}px<!-- ELSE -->-{$BLOCK_DISTANCE}<!-- ENDIF --> 0 <!-- IF S_LEFT_COLUMN -->{S_PORTAL_LEFT_COLUMN}px<!-- ELSE -->-{$BLOCK_DISTANCE}<!-- ENDIF -->; padding: 0 {$BLOCK_DISTANCE};">
|
||||
<div id="portal-center" style="margin: 0 <!-- IF S_RIGHT_COLUMN -->{S_PORTAL_RIGHT_COLUMN}px<!-- ELSE -->-{$BLOCK_DISTANCE}<!-- ENDIF --> 0 <!-- IF S_LEFT_COLUMN -->{S_PORTAL_LEFT_COLUMN}px<!-- ELSE -->-{$BLOCK_DISTANCE}<!-- ENDIF -->; padding: 0 {$BLOCK_DISTANCE};" role="gridcell">
|
||||
<!-- BEGIN modules_center -->
|
||||
<!-- DEFINE $TEMPLATE_FILE = '{modules_center.TEMPLATE_FILE}' -->
|
||||
<!-- DEFINE $IMAGE_SRC = '{modules_center.IMAGE_SRC}' -->
|
||||
@@ -55,7 +54,7 @@
|
||||
<!-- [-] center module area -->
|
||||
<!-- [+] left module area -->
|
||||
<!-- IF S_LEFT_COLUMN -->
|
||||
<div id="portal-left" style="width: {S_PORTAL_LEFT_COLUMN}px;">
|
||||
<div id="portal-left" style="width: {S_PORTAL_LEFT_COLUMN}px;" role="gridcell">
|
||||
<!-- BEGIN modules_left -->
|
||||
<!-- DEFINE $TEMPLATE_FILE = '{modules_left.TEMPLATE_FILE}' -->
|
||||
<!-- DEFINE $IMAGE_SRC = '{modules_left.IMAGE_SRC}' -->
|
||||
@@ -72,7 +71,7 @@
|
||||
|
||||
<!-- [+] right module area -->
|
||||
<!-- IF S_RIGHT_COLUMN -->
|
||||
<div id="portal-right" style="width: {S_PORTAL_RIGHT_COLUMN}px; margin-<!-- IF S_CONTENT_DIRECTION eq 'rtl' -->right<!-- ELSE -->left<!-- ENDIF -->: -{S_PORTAL_RIGHT_COLUMN}px;">
|
||||
<div id="portal-right" style="width: {S_PORTAL_RIGHT_COLUMN}px; margin-<!-- IF S_CONTENT_DIRECTION eq 'rtl' -->right<!-- ELSE -->left<!-- ENDIF -->: -{S_PORTAL_RIGHT_COLUMN}px;" role="gridcell">
|
||||
<!-- BEGIN modules_right -->
|
||||
<!-- DEFINE $TEMPLATE_FILE = '{modules_right.TEMPLATE_FILE}' -->
|
||||
<!-- DEFINE $IMAGE_SRC = '{modules_right.IMAGE_SRC}' -->
|
||||
@@ -88,7 +87,7 @@
|
||||
<!-- [-] right module area -->
|
||||
<br class="portal-clear" />
|
||||
<!-- IF S_BOTTOM_COLUMN -->
|
||||
<div id="portal-bottom">
|
||||
<div id="portal-bottom" role="gridcell">
|
||||
<!-- [+] bottom module area -->
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
@@ -33,10 +33,8 @@
|
||||
text-decoration: underline;
|
||||
}
|
||||
|
||||
.portal-navigation tr.menutitle{
|
||||
font: bold 90% 'Trebuchet MS', 'Lucida Grande', Arial, sans-serif;
|
||||
font-size: 12px;
|
||||
text-decoration: underline;
|
||||
.portal-navigation hr.dashed:last-child {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.rtl .portal-navigation .menutitle {
|
||||
@@ -54,7 +52,7 @@
|
||||
}
|
||||
|
||||
.portal-user-icon {
|
||||
background-image: url("./images/portal/portal_user.png");
|
||||
background-image: url("../../all/theme/images/portal/portal_user.png");
|
||||
padding-left: 16px;
|
||||
padding-top: 16px;
|
||||
float: left;
|
||||
@@ -291,6 +289,10 @@ a.portal-forumtitle {
|
||||
display: block;
|
||||
}
|
||||
|
||||
#portal-center-wrapper .panel, #portal-center-wrapper .post {
|
||||
border-radius: 0;
|
||||
}
|
||||
|
||||
.rtl #portal-center-wrapper {
|
||||
float: right;
|
||||
}
|
||||
@@ -335,8 +337,10 @@ a.portal-forumtitle {
|
||||
* This is needed in order to have the same spacing between blocks
|
||||
* as we have between the top blocks and the headerbar
|
||||
*/
|
||||
#portal-body .forabg {
|
||||
margin-bottom: 0px;
|
||||
#portal-left .forabg, #portal-center .forabg,
|
||||
#portal-right .forabg, #portal-top .forabg,
|
||||
#portal-bottom .forabg {
|
||||
margin-bottom: 0;
|
||||
}
|
||||
|
||||
#portal-body td {
|
||||
@@ -351,7 +355,10 @@ a.portal-forumtitle {
|
||||
margin-left: 0px;
|
||||
margin-right: 0px;
|
||||
}
|
||||
#portal-body li {
|
||||
|
||||
#portal-left li, #portal-center li,
|
||||
#portal-right li, #portal-top li,
|
||||
#portal-bottom li {
|
||||
list-style-type: none;
|
||||
}
|
||||
|
||||
@@ -460,7 +467,7 @@ a.portal-forumtitle {
|
||||
width: 21px;
|
||||
height: 21px;
|
||||
background-position: 0 0;
|
||||
background: url(./images/portal/portal_clock_single.png) no-repeat;
|
||||
background: url("../../all/theme/images/portal/portal_clock_single.png") no-repeat;
|
||||
}
|
||||
|
||||
/* Minutes start
|
||||
@@ -552,7 +559,7 @@ a.portal-forumtitle {
|
||||
.portal-clock-back-hours-up, .portal-clock-front-hours-up {
|
||||
width: 42px;
|
||||
height: 21px;
|
||||
background: url(./images/portal/portal_clock_double.png) no-repeat;
|
||||
background: url("../../all/theme/images/portal/portal_clock_double.png") no-repeat;
|
||||
background-position: 0 0;
|
||||
vertical-align: bottom;
|
||||
display: inline-block;
|
||||
@@ -562,7 +569,7 @@ a.portal-forumtitle {
|
||||
.portal-clock-back-hours-down, .portal-clock-front-hours-down {
|
||||
width: 42px;
|
||||
height: 20px;
|
||||
background: url(./images/portal/portal_clock_double.png) no-repeat;
|
||||
background: url("../../all/theme/images/portal/portal_clock_double.png") no-repeat;
|
||||
background-position: 0 -44px;
|
||||
vertical-align: top;
|
||||
display: inline-block;
|
||||
|
||||
15
styles/prosilver/theme/portal_all.css
Normal file
@@ -0,0 +1,15 @@
|
||||
.portal-body-wrapper {
|
||||
width: 100%;
|
||||
float: left;
|
||||
display: block;
|
||||
}
|
||||
|
||||
#portal-page-body {
|
||||
clear: both;
|
||||
margin: 4px 0;
|
||||
}
|
||||
|
||||
#page-body {
|
||||
float: left;
|
||||
width: 100%;
|
||||
}
|
||||
29
styles/prosilver/theme/portal_all_responsive.css
Normal file
@@ -0,0 +1,29 @@
|
||||
@media only screen and (max-width: 870px), only screen and (max-device-width: 870px) {
|
||||
.portal-body-center dd.posts, .portal-body-center dd.views {
|
||||
display: none !important;
|
||||
}
|
||||
.portal-body-center dt { width: 130% !important; }
|
||||
.portal-body-center dd.lastpost { width: auto; }
|
||||
}
|
||||
|
||||
@media only screen and (max-width: 740px), only screen and (max-device-width: 740px) {
|
||||
#portal-left ul.topiclist dd, #portal-right ul.topiclist dd { display: block !important; }
|
||||
|
||||
#portal-right > .portal-clear, #portal-body > .portal-clear, #portal-left > .portal-clear,
|
||||
#portal-center > .portal-clear, #portal-login-box .portal-clear { display: none !important; }
|
||||
}
|
||||
|
||||
@media only screen and (max-width: 700px), only screen and (max-device-width: 700px) {
|
||||
.portal-body-center dt { width: 100% !important; }
|
||||
}
|
||||
|
||||
@media only screen and (max-width: 540px), only screen and (max-device-width: 540px) {
|
||||
#portal-left, #portal-right {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.portal-body-center {
|
||||
margin: 0 !important;
|
||||
padding: 0 !important;
|
||||
}
|
||||
}
|
||||
@@ -56,7 +56,7 @@
|
||||
#portal-left ul.topiclist dd, #portal-right ul.topiclist dd { display: block !important; }
|
||||
.portal-responsive-show { display: block !important; }
|
||||
.portal-responsive-hide { display: none !important; }
|
||||
#portal-body { padding-top: 0px !important; }
|
||||
#portal-body { padding-top: 0 !important; }
|
||||
#portal-right > .portal-clear, #portal-body > .portal-clear, #portal-left > .portal-clear,
|
||||
#portal-center > .portal-clear, #portal-login-box .portal-clear { display: none !important; }
|
||||
#portal-right { width: 50% !important; }
|
||||
|
||||
@@ -0,0 +1,21 @@
|
||||
<!-- IF S_PORTAL_ALL === true -->
|
||||
</td>
|
||||
<!-- [+] right module area -->
|
||||
<!-- IF S_RIGHT_COLUMN -->
|
||||
<td width="{S_PORTAL_RIGHT_COLUMN}px" valign="top" style="padding-<!-- IF S_CONTENT_DIRECTION eq 'rtl' -->right<!-- ELSE -->left<!-- ENDIF -->:{$BLOCK_DISTANCE};">
|
||||
<!-- BEGIN modules_right -->
|
||||
<!-- DEFINE $TEMPLATE_FILE = '{modules_right.TEMPLATE_FILE}' -->
|
||||
<!-- DEFINE $IMAGE_SRC = '{modules_right.IMAGE_SRC}' -->
|
||||
<!-- DEFINE $IMAGE_WIDTH = '{modules_right.IMAGE_WIDTH}' -->
|
||||
<!-- DEFINE $IMAGE_HEIGHT = '{modules_right.IMAGE_HEIGHT}' -->
|
||||
<!-- DEFINE $CUSTOM_CODE = '{modules_right.CODE}' -->
|
||||
<!-- DEFINE $TITLE = '{modules_right.TITLE}' -->
|
||||
<!-- DEFINE $MODULE_ID = '{modules_right.MODULE_ID}' -->
|
||||
<!-- INCLUDE {$TEMPLATE_FILE} -->
|
||||
<!-- END modules_right -->
|
||||
</td>
|
||||
<!-- ENDIF -->
|
||||
<!-- [-] right module area -->
|
||||
</tr>
|
||||
</table>
|
||||
<!-- ENDIF -->
|
||||
@@ -0,0 +1,22 @@
|
||||
<!-- IF S_PORTAL_ALL === true -->
|
||||
<!-- INCLUDE portal/_block_config.html -->
|
||||
<table cellpadding="0" cellspacing="0" border="0" width="100%" align="center">
|
||||
<tr>
|
||||
<!-- [+] left module area -->
|
||||
<!-- IF S_LEFT_COLUMN -->
|
||||
<td width="{S_PORTAL_LEFT_COLUMN}px" valign="top" style="padding-<!-- IF S_CONTENT_DIRECTION eq 'rtl' -->left<!-- ELSE -->right<!-- ENDIF -->:{$BLOCK_DISTANCE};">
|
||||
<!-- BEGIN modules_left -->
|
||||
<!-- DEFINE $TEMPLATE_FILE = '{modules_left.TEMPLATE_FILE}' -->
|
||||
<!-- DEFINE $IMAGE_SRC = '{modules_left.IMAGE_SRC}' -->
|
||||
<!-- DEFINE $IMAGE_WIDTH = '{modules_left.IMAGE_WIDTH}' -->
|
||||
<!-- DEFINE $IMAGE_HEIGHT = '{modules_left.IMAGE_HEIGHT}' -->
|
||||
<!-- DEFINE $CUSTOM_CODE = '{modules_left.CODE}' -->
|
||||
<!-- DEFINE $TITLE = '{modules_left.TITLE}' -->
|
||||
<!-- DEFINE $MODULE_ID = '{modules_left.MODULE_ID}' -->
|
||||
<!-- INCLUDE {$TEMPLATE_FILE} -->
|
||||
<!-- END modules_left -->
|
||||
</td>
|
||||
<!-- ENDIF -->
|
||||
<!-- [-] left module area -->
|
||||
<td valign="top">
|
||||
<!-- ENDIF -->
|
||||
@@ -5,7 +5,7 @@
|
||||
<!-- IF .attach_center -->
|
||||
<span style="float:<!-- IF S_CONTENT_DIRECTION eq 'rtl' -->right<!-- ELSE -->left<!-- ENDIF -->;"><strong>{L_FILENAME}</strong></span><br style="clear:both" />
|
||||
<!-- BEGIN attach_center -->
|
||||
<span style="float:<!-- IF S_CONTENT_DIRECTION eq 'rtl' -->right<!-- ELSE -->left<!-- ENDIF -->;" class="gensmall"><img src="{T_THEME_PATH}/images/portal/icon_topic_attach.gif" alt="" /> <a href="{attach_center.U_TOPIC}" title="{attach_center.REAL_FILENAME}"><strong>{attach_center.FILENAME}</strong></a></span><br style="clear:both" />
|
||||
<span class="imageset icon_topic_attach"></span> <a href="{attach_center.U_TOPIC}" title="{attach_center.REAL_FILENAME}"><strong>{attach_center.FILENAME}</strong></a><br style="clear:both" />
|
||||
<span style="float:<!-- IF S_CONTENT_DIRECTION eq 'rtl' -->right<!-- ELSE -->left<!-- ENDIF -->;">{L_FILESIZE}{L_COLON}</span><span style="float:<!-- IF S_CONTENT_DIRECTION eq 'rtl' -->left<!-- ELSE -->right<!-- ENDIF -->;" class="gensmall"><strong>{attach_center.FILESIZE}</strong></span><br style="clear:both" />
|
||||
<span style="float:<!-- IF S_CONTENT_DIRECTION eq 'rtl' -->right<!-- ELSE -->left<!-- ENDIF -->;">{L_DOWNLOADS}{L_COLON}</span><span style="float:<!-- IF S_CONTENT_DIRECTION eq 'rtl' -->left<!-- ELSE -->right<!-- ENDIF -->;" class="gensmall"><strong>{attach_center.DOWNLOAD_COUNT}</strong></span><br style="clear:both" />
|
||||
<!-- IF not attach_center.S_LAST_ROW --><hr /><!-- ENDIF -->
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
<!-- IF .attach_side -->
|
||||
<span style="float:<!-- IF S_CONTENT_DIRECTION eq 'rtl' -->right<!-- ELSE -->left<!-- ENDIF -->;"><strong>{L_FILENAME}</strong></span><br style="clear:both" />
|
||||
<!-- BEGIN attach_side -->
|
||||
<span style="float:<!-- IF S_CONTENT_DIRECTION eq 'rtl' -->right<!-- ELSE -->left<!-- ENDIF -->;" class="gensmall"><img src="{T_THEME_PATH}/images/portal/icon_topic_attach.gif" alt="" /> <a href="{attach_side.U_TOPIC}" title="{attach_side.REAL_FILENAME}"><strong>{attach_side.FILENAME}</strong></a></span><br style="clear:both" />
|
||||
<span class="imageset icon_topic_attach"></span> <a href="{attach_side.U_TOPIC}" title="{attach_side.REAL_FILENAME}"><strong>{attach_side.FILENAME}</strong></a><br style="clear:both" />
|
||||
<span style="float:<!-- IF S_CONTENT_DIRECTION eq 'rtl' -->right<!-- ELSE -->left<!-- ENDIF -->;">{L_FILESIZE}{L_COLON}</span><span style="float:<!-- IF S_CONTENT_DIRECTION eq 'rtl' -->left<!-- ELSE -->right<!-- ENDIF -->;" class="gensmall"><strong>{attach_side.FILESIZE}</strong></span><br style="clear:both" />
|
||||
<span style="float:<!-- IF S_CONTENT_DIRECTION eq 'rtl' -->right<!-- ELSE -->left<!-- ENDIF -->;">{L_DOWNLOADS}{L_COLON}</span><span style="float:<!-- IF S_CONTENT_DIRECTION eq 'rtl' -->left<!-- ELSE -->right<!-- ENDIF -->;" class="gensmall"><strong>{attach_side.DOWNLOAD_COUNT}</strong></span><br style="clear:both" />
|
||||
<!-- IF not attach_side.S_LAST_ROW --><hr /><!-- ENDIF -->
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<!-- BEGIN portal_menu -->
|
||||
<!-- IF portal_menu.MODULE_ID eq $MODULE_ID -->
|
||||
{$LR_BLOCK_H_L}<!-- IF $S_BLOCK_ICON --><img src="{$IMAGE_SRC}" width="{$IMAGE_WIDTH}" height="{$IMAGE_HEIGHT}" alt="" /> <!-- ENDIF -->{$TITLE}{$LR_BLOCK_H_R}
|
||||
<table class="tablebg" cellspacing="1" width="100%">
|
||||
<table class="tablebg" cellspacing="1" width="100%" role="menu">
|
||||
<!-- BEGIN category -->
|
||||
<tr class="row3">
|
||||
<td>
|
||||
@@ -11,7 +11,7 @@
|
||||
<!-- BEGIN links -->
|
||||
<tr class="row1">
|
||||
<td>
|
||||
<a class="portal-arrow-bullet" href="{portal_menu.category.links.LINK_URL}" title="{portal_menu.category.links.LINK_TITLE}" <!-- IF portal_menu.category.links.NEW_WINDOW -->onclick="window.open('{portal_menu.category.links.LINK_URL}'); return false;"<!-- ENDIF -->> {portal_menu.category.links.LINK_TITLE}</a>
|
||||
<a class="portal-arrow-bullet" href="{portal_menu.category.links.LINK_URL}" role="menuitem" title="{portal_menu.category.links.LINK_TITLE}" <!-- IF portal_menu.category.links.NEW_WINDOW -->onclick="window.open('{portal_menu.category.links.LINK_URL}'); return false;"<!-- ENDIF -->> {portal_menu.category.links.LINK_TITLE}</a>
|
||||
</td>
|
||||
</tr>
|
||||
<!-- END links -->
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
<table class="tablebg" cellspacing="1" width="100%">
|
||||
<tr class="row1">
|
||||
<td>
|
||||
<select style="width: 150px;" name="demo" id="demo" onchange="document.location.href = this.options[this.selectedIndex].value;">
|
||||
<select style="width: 150px;" name="demo" id="demo" role="listbox" onchange="document.location.href = this.options[this.selectedIndex].value;">
|
||||
{STYLE_SELECT}
|
||||
</select>
|
||||
</td>
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
<!-- DEFINE $S_IN_PORTAL = 1 -->
|
||||
<!-- INCLUDE overall_header.html -->
|
||||
<!-- INCLUDE portal/_block_config.html -->
|
||||
|
||||
@@ -16,11 +15,11 @@
|
||||
<br />
|
||||
<!-- ENDIF -->
|
||||
|
||||
<table cellpadding="0" cellspacing="0" border="0" width="100%" align="center">
|
||||
<table cellpadding="0" cellspacing="0" border="0" width="100%" align="center" role="grid">
|
||||
<!-- IF S_TOP_COLUMN -->
|
||||
<tr>
|
||||
<!-- [+] top module area -->
|
||||
<td colspan="3">
|
||||
<td colspan="3" role="gridcell">
|
||||
<!-- BEGIN modules_top -->
|
||||
<!-- DEFINE $TEMPLATE_FILE = '{modules_top.TEMPLATE_FILE}' -->
|
||||
<!-- DEFINE $IMAGE_SRC = '{modules_top.IMAGE_SRC}' -->
|
||||
@@ -38,7 +37,7 @@
|
||||
<tr>
|
||||
<!-- [+] left module area -->
|
||||
<!-- IF S_LEFT_COLUMN -->
|
||||
<td width="{S_PORTAL_LEFT_COLUMN}px" valign="top" style="padding-<!-- IF S_CONTENT_DIRECTION eq 'rtl' -->left<!-- ELSE -->right<!-- ENDIF -->:{$BLOCK_DISTANCE};">
|
||||
<td width="{S_PORTAL_LEFT_COLUMN}px" valign="top" style="padding-<!-- IF S_CONTENT_DIRECTION eq 'rtl' -->left<!-- ELSE -->right<!-- ENDIF -->:{$BLOCK_DISTANCE};" role="gridcell">
|
||||
<!-- BEGIN modules_left -->
|
||||
<!-- DEFINE $TEMPLATE_FILE = '{modules_left.TEMPLATE_FILE}' -->
|
||||
<!-- DEFINE $IMAGE_SRC = '{modules_left.IMAGE_SRC}' -->
|
||||
@@ -55,7 +54,7 @@
|
||||
|
||||
<!-- [+] center module area -->
|
||||
<!-- IF S_CENTER_COLUMN -->
|
||||
<td valign="top">
|
||||
<td valign="top" role="gridcell">
|
||||
<!-- BEGIN modules_center -->
|
||||
<!-- DEFINE $TEMPLATE_FILE = '{modules_center.TEMPLATE_FILE}' -->
|
||||
<!-- DEFINE $IMAGE_SRC = '{modules_center.IMAGE_SRC}' -->
|
||||
@@ -76,7 +75,7 @@
|
||||
|
||||
<!-- [+] right module area -->
|
||||
<!-- IF S_RIGHT_COLUMN -->
|
||||
<td width="{S_PORTAL_RIGHT_COLUMN}px" valign="top" style="padding-<!-- IF S_CONTENT_DIRECTION eq 'rtl' -->right<!-- ELSE -->left<!-- ENDIF -->:{$BLOCK_DISTANCE};">
|
||||
<td width="{S_PORTAL_RIGHT_COLUMN}px" valign="top" style="padding-<!-- IF S_CONTENT_DIRECTION eq 'rtl' -->right<!-- ELSE -->left<!-- ENDIF -->:{$BLOCK_DISTANCE};" role="gridcell">
|
||||
<!-- BEGIN modules_right -->
|
||||
<!-- DEFINE $TEMPLATE_FILE = '{modules_right.TEMPLATE_FILE}' -->
|
||||
<!-- DEFINE $IMAGE_SRC = '{modules_right.IMAGE_SRC}' -->
|
||||
@@ -94,7 +93,7 @@
|
||||
<!-- IF S_BOTTOM_COLUMN -->
|
||||
<tr>
|
||||
<!-- [+] bottom module area -->
|
||||
<td colspan="3">
|
||||
<td colspan="3" role="gridcell">
|
||||
<!-- BEGIN modules_bottom -->
|
||||
<!-- DEFINE $TEMPLATE_FILE = '{modules_bottom.TEMPLATE_FILE}' -->
|
||||
<!-- DEFINE $IMAGE_SRC = '{modules_bottom.IMAGE_SRC}' -->
|
||||
|
||||
|
Before Width: | Height: | Size: 1003 B |
|
Before Width: | Height: | Size: 1.1 KiB |
|
Before Width: | Height: | Size: 964 B |
|
Before Width: | Height: | Size: 1.1 KiB |
|
Before Width: | Height: | Size: 1.1 KiB |
|
Before Width: | Height: | Size: 9.5 KiB |
|
Before Width: | Height: | Size: 7.2 KiB |
|
Before Width: | Height: | Size: 1.1 KiB |
|
Before Width: | Height: | Size: 738 B |
|
Before Width: | Height: | Size: 696 B |