Advanced search  

News:

cpg1.5.48 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.46 or older update to this latest version as soon as possible.
[more]

Pages: 1 [2] 3 4 5 6 ... 26   Go Down

Author Topic: Permanant watermark with undo possibility (GD2+IM working!) + better admin tools  (Read 350708 times)

0 Members and 1 Guest are viewing this topic.

Stramm

  • Dev Team member
  • Coppermine addict
  • ****
  • Country: 00
  • Offline Offline
  • Gender: Male
  • Posts: 6006
    • Bettis Wollwelt

don't chmod anything except albums folder and stuff in here
and these instructions. If you messed something up when applying the mod... bad luck
http://forum.coppermine-gallery.net/index.php?topic=29817.msg137994#msg137994

Jarvhix

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 38

Right, so I'm just going to remove the mod then. I've already noticed some strange things happening. I can't do anything with it if it's not working. Thanks. T/C
Logged

Jarvhix

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 38

I posted in a forum for support on the hits count/stats. After I applied your mod, somehow my hits stats changed from 127,000 to 0. How can I correct that?
Logged

Stramm

  • Dev Team member
  • Coppermine addict
  • ****
  • Country: 00
  • Offline Offline
  • Gender: Male
  • Posts: 6006
    • Bettis Wollwelt

This mod doesn't have anything to do with 'hit stats'. I have no clue at all what you've done. Even with messing up code while applying it, there's no obvious part where it may affect hit stats.

edit: You've written you ran the admin tools... by default 'Reset view counters' is set. If you've missed to click 'Update thumbs and/or resized photos' you can imagine what happened... -> you've reseted your view counts.

If you don't have a backup of your db nothing can be done to undo that. In general before applying mods it's advisable to make backups of everything (db and files). Before playing with the admin tools double check it's set to what you want
« Last Edit: April 29, 2006, 10:46:40 am by Stramm »
Logged

Stramm

  • Dev Team member
  • Coppermine addict
  • ****
  • Country: 00
  • Offline Offline
  • Gender: Male
  • Posts: 6006
    • Bettis Wollwelt

a mod for the mod...
Atm on all images (intermediate and fullsized) the same watermark gets applied. However it may look oversized on the intermediate. Now it's possible to let the watermark mod calculate a reduced watermark size for small images.

I just copy the description from my modpack.
Automatically downsizing of the watermark image when the uploaded picture is smaller than the width you set (Downsize watermark if width of an picture is smaller than entered value. That is the 100% reference point. Resizing of the watermark is linear (0 to disable)).
If you eg. enter here 1024 (like I did on my demo site), then the 100% reference is at images with a width of 1024px or bigger. If you upload pics > 1024px the watermark image won't get resized and attached with its full size. If you let coppermine create an intermediate image with a width of 400 pics, then the watermark will get downsized to 39% of it's original size. Is the fullsized eg. 512px, then the watermark will have 50% of it's orig size. Of course this sucks some CPU. And it's working excellent together with (example: http://stramm.st.funpic.org/displayimage.php?pos=-96 )
Files and thumbnails settings -> Auto resize images that are larger than max width or height (set it to the same as you used for the 100% reference... in the example 1024)
this way the watermark will always fit perfectly onto your images.

I assume you already applied the watermark mod in this thread and you have it working. That's the changes you have to do then.

sql/update.sql
at the end of this file add
Code: [Select]
INSERT INTO CPG_config (name, value) values ('reduce_watermark', '0');

lang/english.php
find
Code: [Select]
  array('Transparency 0-100 for entire image', 'watermark_transparency', 0),
below add
Code: [Select]
  array('Downsize watermark if width of an picture is smaller than entered value. That is the 100% reference point. Resizing of the watermark is linear (0 to disable)', 'reduce_watermark', 0),


now download the attached file, unpack it and upload it in your include folder replacing the existing file (include/picmgmnt.inc.php)
run update.php

have fun

PS: I've attached a test watermark png... feel free to experiment with it. The watermark file has a layer transparency of ~60-70% (have forgotten what value exactly) so you should see the image through it. Usually I have it in the images/ directory, if you do the same, then the path is images/watermark.png

an example: http://stramm.st.funpic.org/displayimage.php?album=7&pos=5


new attached file.... picmgmnt.inc.1.4.6.zip is the latest picmgmnt.inc.php file for CPG 1.4.6-1.4.8
« Last Edit: July 09, 2006, 06:41:11 pm by Stramm »
Logged

DarioDN

  • Coppermine newbie
  • Offline Offline
  • Posts: 12

i've replace the file attached, modify the files.
I've update the old images by Admin Tools, but the watermark doesn't appears on the old images.
« Last Edit: May 01, 2006, 05:48:05 pm by DarioDN »
Logged

Stramm

  • Dev Team member
  • Coppermine addict
  • ****
  • Country: 00
  • Offline Offline
  • Gender: Male
  • Posts: 6006
    • Bettis Wollwelt

you need to enable the watermark in config
you need check twice if you followed the instructions 100%
make sure albums folder and it's subfolders are chmod 777 or 755 (depending on your system) and the files at least 644

CanadianGuy

  • Coppermine newbie
  • Offline Offline
  • Posts: 1

Help, i have the new Coppermine 1.4.5 and i have it install and all, and i want to put watermark on the pics. can someone help me out please :(
it would be great help?
is there step by step i can follow to have watermark? please help, it would mean alot

ty
Joey from Canada
Logged

Stramm

  • Dev Team member
  • Coppermine addict
  • ****
  • Country: 00
  • Offline Offline
  • Gender: Male
  • Posts: 6006
    • Bettis Wollwelt

war59312

  • Coppermine newbie
  • Offline Offline
  • Gender: Male
  • Posts: 6
  • God Bless America
    • Will's Blog

Hey,

Awesome mod!  ;D

However, there is no "sql/sql.inc" . lol

Thanks a lot,

Will
Logged
God Bless America

Stramm

  • Dev Team member
  • Coppermine addict
  • ****
  • Country: 00
  • Offline Offline
  • Gender: Male
  • Posts: 6006
    • Bettis Wollwelt

Thanks ;)
but where do I talk about sql.inc?? Maybe you mean update.sql

war59312

  • Coppermine newbie
  • Offline Offline
  • Gender: Male
  • Posts: 6
  • God Bless America
    • Will's Blog

Hey,

And I quote:

sql/sql.inc
at the end of this file add
Code: [Select]
INSERT INTO CPG_config (name, value) values ('reduce_watermark', '0');

Right there, lol . A few posts up. That is reply 24.

Yeah I took it, as you meant update.sql. ;)

Take Care,

Will
Logged
God Bless America

Stramm

  • Dev Team member
  • Coppermine addict
  • ****
  • Country: 00
  • Offline Offline
  • Gender: Male
  • Posts: 6006
    • Bettis Wollwelt

ahh.. OK, the enhancement on this site. I've edited my post above ;)
But I guess it wasn't a problem to find the correct file (at least after applying the main hack)

Thanks

AmanM

  • Coppermine newbie
  • Offline Offline
  • Posts: 12

sorry not working on my gallery i only find some strange stuff.In english gb i dont find the watermark in it but in us and than i cant see the listbox whith bottom right an so on its in the page ive you open the config you will find the entries before general settings
Logged

Stramm

  • Dev Team member
  • Coppermine addict
  • ****
  • Country: 00
  • Offline Offline
  • Gender: Male
  • Posts: 6006
    • Bettis Wollwelt

lang/english.php = English US

If you can't see the watermark settings in config while your language is set to english US you probably made a mistake or two while applying the hack.

Solution:
-> replace your modified files with original ones and start again.
-> use a predone hack (like my modpack, the watermark hack is included there)

gerdo

  • Coppermine newbie
  • Offline Offline
  • Posts: 1

It works great on v1.4.6
thnx man!
Logged

ISBB

  • Coppermine regular visitor
  • **
  • Offline Offline
  • Gender: Male
  • Posts: 93
    • Northwest ZR2's

Strahm is there anything to worry about... I previously had 1.4.3 and upon upgrading to 1.4.6 i seem to have overwritten the files that were modded by this mod..   Is there any issue w/ me replacing the files that came w/ 1.4.6 w/ the ones i modded in 1.4.3??
Logged
Its gaurunteed.. until it breaks

Lifted trucks are like boob jobs, no matter what size shape or dimension they are always fun to look at.

Stramm

  • Dev Team member
  • Coppermine addict
  • ****
  • Country: 00
  • Offline Offline
  • Gender: Male
  • Posts: 6006
    • Bettis Wollwelt

as far as I remember there were small changes in editpics and searchnew. But nothing critical.
Also there was a little bugfix in picmgmnt.inc.php. Up to date is always the picmgmnt.inc.php from the modpack. I'll attach a new one to the downsize enhancement (within this thread)

CubaLibre

  • Coppermine newbie
  • Offline Offline
  • Posts: 2

Hi, i follow instruction, but can't see option in config, i run update.php it say me OK for the line added, in admin.php all is done.
What can i check?

Thank you
Logged

CubaLibre

  • Coppermine newbie
  • Offline Offline
  • Posts: 2

Ok resolved, language problem ;)
Logged
Pages: 1 [2] 3 4 5 6 ... 26   Go Up
 

Page created in 0.029 seconds with 21 queries.