Skip to content

Commit

Permalink
v1.4.6
Browse files Browse the repository at this point in the history
  • Loading branch information
IMC-GER committed Oct 16, 2022
1 parent 1ee6424 commit 2d29979
Show file tree
Hide file tree
Showing 12 changed files with 76 additions and 11 deletions.
4 changes: 4 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ For more data security, he can convert insecurely transmitted images (http: conn
- Set the level of the internal domain
- Mark external links.
- Added an external image the URL as caption.
- Improved recognition of links to images
- Image dimensions for display image as an inline text link if image is larger

#### Permission
Expand Down Expand Up @@ -55,6 +56,9 @@ Go to "ACP" > "Extensions" > "External Links settings" and customize "External L

## Changelog

### v1.4.6 (16-10-2022)
- Added ACP setting for improved image recognition

### v1.4.5 (09-10-2022)
- Added title tag to caption

Expand Down
2 changes: 1 addition & 1 deletion externallinks_version.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"stable": {
"1.4": {
"current": "1.4.5",
"current": "1.4.6",
"announcement": "https://www.phpbb.de/community/viewtopic.php?t=245923",
"download": "https://github.com/IMC-GER/phpBB-External-Links/tags",
"eol": null,
Expand Down
4 changes: 4 additions & 0 deletions imcger/externallinks/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ For more data security, he can convert insecurely transmitted images (http: conn
- Set the level of the internal domain
- Mark external links.
- Added an external image the URL as caption.
- Improved recognition of links to images
- Image dimensions for display image as an inline text link if image is larger

#### Permission
Expand Down Expand Up @@ -55,6 +56,9 @@ Go to "ACP" > "Extensions" > "External Links settings" and customize "External L

## Changelog

### v1.4.6 (16-10-2022)
- Added ACP setting for improved image recognition

### v1.4.5 (09-10-2022)
- Added title tag to caption

Expand Down
11 changes: 11 additions & 0 deletions imcger/externallinks/adm/style/acp_ext_link_body.html
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,17 @@ <h1>{{ lang('EXT_LINK_TITLE') }}</h1>
</dl>
</fieldset>

<fieldset>
<legend>{{ lang('EXT_LINK_FIND') }}</legend>
<dl>
<dt><label for="imcger_ext_find_img">{{ lang('EXT_LINK_FIND_IMG') }} {{ lang('COLON') }}</label><br><span>{{ lang('EXT_LINK_FIND_IMG_DESC') }}</span></dt>
<dd>
<label><input type="radio" class="radio" id="imcger_ext_find_img" name="imcger_ext_find_img" value='1'{% if S_IMCGER_FIND_IMG %} checked="checked"{% endif %} /> {{ lang('YES') }}</label>
<label><input type="radio" class="radio" name="imcger_ext_find_img" value='0'{% if not S_IMCGER_FIND_IMG %} checked="checked"{% endif %} /> {{ lang('NO') }}</label>
</dd>
</dl>
</fieldset>

<fieldset>
<legend>{{ lang('EXT_LINK_IMAGE') }}</legend>
<dl>
Expand Down
4 changes: 2 additions & 2 deletions imcger/externallinks/composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@
"type": "phpbb-extension",
"description": "With this extension it is possible to influence the display of links and pictures. Some settings are available in the User Control Panel. This allows the user to decide for himself what is more important to him. Secure data transfer, comfortable display or fast loading times of the forum page. Open external links in a new tab/window.",
"homepage": "https://github.com/IMC-GER/phpBB-External-Links",
"version": "1.4.5",
"time": "2022-10-09",
"version": "1.4.6",
"time": "2022-10-16",
"license": "GPL-2.0-only",
"authors": [{
"name": "Thorsten Ahlers",
Expand Down
2 changes: 2 additions & 0 deletions imcger/externallinks/controller/admin_controller.php
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,7 @@ public function display_options()
'S_IMCGER_EXT_LINK_DOMAIN' => $this->config['imcger_ext_link_domain_level'],
'S_IMCGER_LINKS_TEXT' => $this->config['imcger_ext_link_links_text'],
'S_IMCGER_LINKS_IMG' => $this->config['imcger_ext_link_links_img'],
'S_IMCGER_FIND_IMG' => $this->config['imcger_ext_find_img'],
'S_IMCGER_SHOW_LINK' => $this->config['imcger_ext_link_show_link'],
'IMCGER_IMG_LINK_WIDTH' => $this->config['imcger_ext_img_show_link_width'],
'IMCGER_IMG_LINK_HEIGHT' => $this->config['imcger_ext_img_show_link_height'],
Expand All @@ -99,6 +100,7 @@ protected function set_variable()
$this->config->set('imcger_ext_link_domain_level', $this->request->variable('imcger_ext_link_domain_level', 0));
$this->config->set('imcger_ext_link_links_text', $this->request->variable('imcger_ext_link_links_text', 0));
$this->config->set('imcger_ext_link_links_img', $this->request->variable('imcger_ext_link_links_img', 0));
$this->config->set('imcger_ext_find_img', $this->request->variable('imcger_ext_find_img', 0));
$this->config->set('imcger_ext_link_show_link', $this->request->variable('imcger_ext_link_show_link', 0));
$this->config->set('imcger_ext_img_show_link_width', $this->request->variable('imcger_ext_img_show_link_width', 0));
$this->config->set('imcger_ext_img_show_link_height', $this->request->variable('imcger_ext_img_show_link_height', 0));
Expand Down
2 changes: 1 addition & 1 deletion imcger/externallinks/event/main_listener.php
Original file line number Diff line number Diff line change
Expand Up @@ -209,7 +209,7 @@ public function modify_text_for_display_after($event)
}
}
}
else
else if ($this->config['imcger_ext_find_img'])
{
/* Convert a link to an image, into an image */
if (($this->user->data['user_extlink_image'] && $this->user->optionget('viewimg')) || $this->is_fancybox)
Expand Down
6 changes: 5 additions & 1 deletion imcger/externallinks/language/de/common.php
Original file line number Diff line number Diff line change
Expand Up @@ -31,14 +31,18 @@
'EXT_LINK_LINKS_TEXT' => 'Textform:',
'EXT_LINK_LINKS_TEXT_DESC' => 'Dem Text von Links, die auf externe Websites führen, wird das Symbol <i class="fa fa-external-link" aria-hidden="true"></i> im Anschluss hinzugefügt.',
'EXT_LINK_LINKS_IMG' => 'Externes Bild:',
'EXT_LINK_LINKS_IMG_DESC' => 'Bildern von anderen Websites, werden die Quelle das Bildes als Bildunterschrift hinzugefügt.',
'EXT_LINK_LINKS_IMG_DESC' => 'Bildern von anderen Websites, werden die Quelle des Bildes als Bildunterschrift hinzugefügt.',

'EXT_LINK_SHOW' => 'Links verdecken',
'EXT_LINK_SHOW_LINK' => 'Nur externe Links:',
'EXT_LINK_SHOW_LINK_DESC' => 'Mit den Forenrechten können Links und Bilder verdeckt werden. Mit der Auswahl von "externe" werden nur externe Links und Bilder verdeckt. Mit "alle" werden alle verdeckt.',
'EXT_LINK_EXT' => 'externe',
'EXT_LINK_ALL' => 'alle',

'EXT_LINK_FIND' => 'Bilder erkennen',
'EXT_LINK_FIND_IMG' => 'Verbessertes erkennen von Links zu Bilder:',
'EXT_LINK_FIND_IMG_DESC' => 'Es werden auch Links zu Bilder erkannt wenn diese keine Dateinamenserweiterung für Bilder beinhalten.<br><strong>Achtung:</strong> Wenn sich in Beiträgen Tote Links befinden verlängert sich die Ladezeit der Forenseite.',

'EXT_LINK_IMAGE' => 'Externes Bild',
'EXT_LINK_IMAGE_LINK' => 'Abmessungen, ab denen externe Bilder verlinkt werden:',
'EXT_LINK_IMAGE_LINK_DESC' => 'Externe Bilder werden als Link dargestellt, wenn deren Größe diese Werte überschreitet. Bei der Verwendung von 0px &times; 0px wird dieses Verhalten abgeschaltet.',
Expand Down
6 changes: 5 additions & 1 deletion imcger/externallinks/language/de_x_sie/common.php
Original file line number Diff line number Diff line change
Expand Up @@ -31,14 +31,18 @@
'EXT_LINK_LINKS_TEXT' => 'Textform:',
'EXT_LINK_LINKS_TEXT_DESC' => 'Dem Text von Links, die auf externe Websites führen, wird das Symbol <i class="fa fa-external-link" aria-hidden="true"></i> im Anschluss hinzugefügt.',
'EXT_LINK_LINKS_IMG' => 'Externes Bild:',
'EXT_LINK_LINKS_IMG_DESC' => 'Bildern von anderen Websites, werden die Quelle das Bildes als Bildunterschrift hinzugefügt.',
'EXT_LINK_LINKS_IMG_DESC' => 'Bildern von anderen Websites, werden die Quelle des Bildes als Bildunterschrift hinzugefügt.',

'EXT_LINK_SHOW' => 'Links verdecken',
'EXT_LINK_SHOW_LINK' => 'Nur externe Links:',
'EXT_LINK_SHOW_LINK_DESC' => 'Mit den Forenrechten können Links und Bilder verdeckt werden. Mit der Auswahl von "externe" werden nur externe Links und Bilder verdeckt. Mit "alle" werden alle verdeckt.',
'EXT_LINK_EXT' => 'externe',
'EXT_LINK_ALL' => 'alle',

'EXT_LINK_FIND' => 'Bilder erkennen',
'EXT_LINK_FIND_IMG' => 'Verbessertes erkennen von Links zu Bilder:',
'EXT_LINK_FIND_IMG_DESC' => 'Es werden auch Links zu Bilder erkannt wenn diese keine Dateinamenserweiterung für Bilder beinhalten.<br><strong>Achtung:</strong> Wenn sich in Beiträgen Tote Links befinden verlängert sich die Ladezeit der Forenseite.',

'EXT_LINK_IMAGE' => 'Externes Bild',
'EXT_LINK_IMAGE_LINK' => 'Abmessungen, ab denen externe Bilder verlinkt werden:',
'EXT_LINK_IMAGE_LINK_DESC' => 'Externe Bilder werden als Link dargestellt, wenn deren Größe diese Werte überschreitet. Bei der Verwendung von 0px &times; 0px wird dieses Verhalten abgeschaltet.',
Expand Down
4 changes: 4 additions & 0 deletions imcger/externallinks/language/en/common.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,10 @@
'EXT_LINK_EXT' => 'external',
'EXT_LINK_ALL' => 'all',

'EXT_LINK_FIND' => 'Recognize images',
'EXT_LINK_FIND_IMG' => 'Improved recognition of links to images:',
'EXT_LINK_FIND_IMG_DESC' => 'Links to images are also recognized if they do not contain a file name extension for images.<br><strong>Attention:</strong> If there are dead links in posts, the loading time of the forum page will increase.',

'EXT_LINK_IMAGE' => 'Only external image',
'EXT_LINK_IMAGE_LINK' => 'Image link dimensions:',
'EXT_LINK_IMAGE_LINK_DESC' => 'Display image as an inline text link if image is larger than this. To disable this behaviour, set the values to 0px by 0px.',
Expand Down
10 changes: 5 additions & 5 deletions imcger/externallinks/migrations/up04_acp_module.php
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ class up04_acp_module extends \phpbb\db\migration\migration
{
public static function depends_on()
{
return array('\imcger\externallinks\migrations\up03_permission');
return ['\imcger\externallinks\migrations\up03_permission'];
}

public function effectively_installed()
Expand All @@ -25,9 +25,9 @@ public function effectively_installed()

public function update_data()
{
return array(
array('config.add', array('imcger_ext_img_show_link_width', 0)),
array('config.add', array('imcger_ext_img_show_link_height', 0)),
);
return [
['config.add', ['imcger_ext_img_show_link_width', $this->config['img_link_width']]],
['config.add', ['imcger_ext_img_show_link_height', $this->config['img_link_height']]],
];
}
}
32 changes: 32 additions & 0 deletions imcger/externallinks/migrations/up05_acp_module.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
<?php
/**
*
* External Links
* An extension for the phpBB Forum Software package.
*
* @copyright (c) 2022, Thorsten Ahlers
* @license GNU General Public License, version 2 (GPL-2.0)
*
*/

namespace imcger\externallinks\migrations;

class up05_acp_module extends \phpbb\db\migration\migration
{
public static function depends_on()
{
return ['\imcger\externallinks\migrations\up04_acp_module'];
}

public function effectively_installed()
{
return isset($this->config['imcger_ext_find_img']);
}

public function update_data()
{
return [
['config.add', ['imcger_ext_find_img', 0]],
];
}
}

0 comments on commit 2d29979

Please sign in to comment.