Difference between revisions of "Watermark"
Line 253: | Line 253: | ||
| [[User:NLapierre|Normand Lapierre]] | | [[User:NLapierre|Normand Lapierre]] | ||
| Private | | Private | ||
− | | v12.2.0. | + | | v12.2.0.1f |
| v12.3.0 | | v12.3.0 | ||
| FR/EN | | FR/EN |
Revision as of 12:04, 1 February 2021
Downloads of Watermark are restricted to logged in users. If you do not have a user account on the TNG Wiki use the Request Account link to request a user account | ||
If you have trouble downloading with Google Chrome, Vivaldi, Brave or other Chromium based browser, try using a right-click and select Open in new Window, then F5, or use another browser such as Firefox
|
The latest version of this mod uses the guidelines for TNG v12+ cust_text.php files. If you are using TNGv12+, and any cust_text.php file in this mod is marked with a Bad Target error, you need to update your cust_text.php files before you can install this mod. [Show instructions]
If you upgraded to TNGv12+, and did not update your cust_text.php files as instructed in the upgrade readme script, then you must use the TNG Mod Manager to update them. To do so:
[See details in the TNGv12 Change Impacts Article][Hide the instructions] |
|
Watermark | |||
---|---|---|---|
Summary | Shows a watermarked image instead the original image. | ||
Validation | |||
Mod Updated | 30 jan 2021 | ||
Download link | v12.2.0.1f
| ||
Download stats | Montrer les statistiques | ||
Author(s) | Michel Kirsch | ||
Homepage | Racines luxo-hennuyeres | ||
Mod Support | TNG Community Forums | ||
Contact Developer | |||
Latest Mod | v12.2.0.1f for TNG v12 & 13 | ||
Min TNG V | n.c | ||
Max TNG V | v12+ | ||
Files modified | admin_users.php albumlib.php browsemedia.php functions.php genlib.php globallib.php headstones.php img_viewer.php languages/English-UTF8/cust_text.php languages/English/cust_text.php languages/French-UTF8/cust_text.php languages/French/cust_text.php mostwanted.php personlib.php randomphoto.php showalbum.php showmap.php showmedialib.php templates/template10/index.php | ||
Related Mods | |||
Notes |
Prior to install the version 12.2.0.1f, you must manually delete, rename or complete your extensions/watermark_mod_vars.php file
Purpose of the Mod
This Mod watermarks your images on the fly and hides their names to prevent image theft. Your original images are not altered.
The watermark is customizable: text, color, tilt, transparency, repetition and font.
[Optional] : Your users can request an unwatermarked copy of the media they are viewing
You can designate some of your users (via Administration/Users) so they can view the media without watermark
Thanks to
Ron, Philippe, Jean-Louis, Pascal and Alain Evrard for their tests, ideas and comments to realize this first version !
DeepL.com for some translations...
Mod Developer
Written by : Michel Kirsch from Charleroi - Hainaut - Belgium
Requirements
A TNG V12.2.0 installation in working order.
Users of the Mod Add cousins button will update their version with the version 1b to standardize the appearance of the table of users.
IMPORTANT : Before installing
- Before installing, it is judicious to make a backup copy of the files that will be modified by this mod.
TNG Modules Impacted
The following TNG Modules are modified, and should be backed up prior to installing this mod:
admin_users.php
albumlib.php
browsemedia.php
functions.php
genlib.php
globallib.php
headstones.php
img_viewer.php
languages/English-UTF8/cust_text.php
languages/English/cust_text.php
languages/French-UTF8/cust_text.php
languages/French/cust_text.php
mostwanted.php
personlib.php
randomphoto.php
showalbum.php
showmap.php
showmedialib.php
templates/template10/index.php
Files created/copied by this Mod
Source | Destination |
---|---|
watermark_1/watermark_no.gif | TNG root/img/watermark_no.gif |
watermark_1/watermark_yes.gif | TNG root/img/watermark_yes.gif |
watermark_1/watermodfont.ttf | TNG root/font/watermodfont.ttf |
(protected)watermark_1/watermark_mod_allowedusers.txt | TNG root/$extspath/watermark_mod_allowedusers.txt |
(protected)watermark_1/watermark_mod_vars.php | TNG root/$extspath/watermark_mod_vars.php |
INSTALLATION
- Unzip the received file directly in the "mods" subdirectory of your TNG installation.
- Via Mod Manager, install the Mod.
Upgrade
- Uninstall and eventually Delete the current Mod.
- Proceed as for an installation with the new Mod.
- Your files watermark_mod_vars.php and watermark_mod_allowedusers.txt are copy protected and will not crushed by the new installation.
- VERSION 12.2.0.1f : You MUST manually delete, rename or complete your TNGRoot/extensions/watermark_mod_vars.php before installing this version !!
Known Problems
This Mod is NOT compatible with the Admin_Users_Menu Mod. Contact me for a solution.
With some too large files, you may receive a message "Fatal error: Allowed memory size of ...". Refresh your browser (F5). If the probllem persists, you can then reduce the number of results during queries ( via the menu Administration/Setup/General Settings/Miscellaneous/Max Search Results:). Try to reduce this number...
In the event of a problem
- Try using the Mod Manager Remove capability
- Copy the backup of the affected files back to your TNG directory
- Retry. If the problem persists, open an issue in the TNG Community Forums or on the page of Michel Kirsch. At worst, send a mail to
Parameters
Text: You can use 2 lines for the watermark. These two lines are separated in the Text parameter by " -x- " (space dash x space dash)
In addition to the common options text, color, transparency, font, owner and proportionality,
If you use the option Angle = "45"
version 1f: A new option allows you to display two lines of watermarks diagonally. The result is NOT guaranteed!
You can determine whether the watermark will be repeated 2 or 3 times on the image.Only the first line of text appears.
If you use the option Angle = "0"
You can use the vpos option to "top" or "bottom". The Repeat option must be imperatively set to "1".
These are the only cases where both lines of the watermark appear.
Repeat on "2" or "3" deletes the second line.
version 1f : you can suppress the possibility of ordering the media without a watermark.
Historic of modifications
Version | Release Date | Contents |
---|---|---|
V12.2.0.1f | 30 jan 2021 | Adds 2 new parameters : Display 2 lines of watermark diagonally and Show or not the "command without watermark" line. Modify some calculations |
V12.2.0.1e | 11 jan 2021 | Internal modifications to avoid Mods conflicts, warnings and notices. Secure the allowed users list |
V12.2.0.1c | 28 jul 2020 | New option to NOT watermark the pictures from one or more folders. Your file RootTNG/extensions/watermark_mod_vars.php is protected against overwriting. You MUST delete or rename it manually before installing this version ! |
V12.2.0.1b | 10 Jun 2020 | Doesn't try to watermark if file's MIME type is not 'image'. |
V12.2.0.1a | 06 apr 2020 | Fix problems with the mysqli_fetch_all() function, replaced with mysqli_fetch_array() |
V12.2.0.1 | 04 mar 2020 | First online version. |
Sites using this mod
If you download and install this mod, please add your TNG site to the table below:
If you have any problem to do it, send me a mail...
Visualization
This image shows different styles of watermarks. From L to R:
(1) Angle 45 - Repeat 1 - Transparency 80 - (2) Angle 45 - Repeat 2 - Transparency 20 - (3) Angle 0 - vpos bottom - Repeat 1 - 2 lines - Proportioned
(4) Idem - vpos top - NOT proportioned - (5) Angle 0 - Repeat 3 - Proportioned
The bottom of showmedia.php page. Remark the filename unrelevant, the owner field and the possibility for user to command a not watermarked image. (version 1 f : these possibility can be disabled)
The user table with the new column Wmk?. A green icon means that this user will view the photos WITHOUT watermark.
- Mods for TNG v12
- Mods for TNG v13
- Admin users.php mods
- Albumlib.php mods
- Browsemedia.php mods
- Functions.php mods
- Genlib.php mods
- Globallib.php mods
- Headstones.php mods
- Img viewer.php mods
- Cust text.php English-UTF8 mods
- Cust text.php English mods
- Cust text.php French-UTF8 mods
- Cust text.php French mods
- Mostwanted.php mods
- Personlib.php mods
- Randomphoto.php mods
- Showalbum.php mods
- Showmap.php mods
- Showmedialib.php mods
- Templates/template10/index.php mods