Advanced search  

News:

CPG Release 1.6.26
Correct PHP8.2 issues with user and language managers.
Additional fixes for PHP 8.2
Correct PHP8 error with SMF 2.0 bridge.
Correct IPTC supplimental category parsing.
Download and info HERE

Pages: 1 ... 3 4 5 6 [7] 8 9 10   Go Down

Author Topic: Permanent Watermark with GD2  (Read 247429 times)

0 Members and 1 Guest are viewing this topic.

Nibbler

  • Guest
Re: Permanent Watermark with GD2
« Reply #120 on: March 10, 2005, 05:16:00 pm »

You should be able to use the is_image() function to check if the file is an image, and only apply the watermark if it is.
Logged

lanun

  • Coppermine newbie
  • Offline Offline
  • Posts: 1
Fatal error
« Reply #121 on: March 14, 2005, 02:51:46 am »

Hi. I've applied this hack to all of the instructions but I get the following error when I do the watermark action.

Fatal error: Unsupported operand types in /home/badak/public_html/mrbadak/include/picmgmt.inc.php on line 320

the line 320
$src_x = $srcWidth - ($logoW + 5);

is this problem with my server settings? how do i check?
Logged

melbcentral

  • Coppermine newbie
  • Offline Offline
  • Posts: 6
Re: problem
« Reply #122 on: March 17, 2005, 03:32:59 am »

Hey i tried it before and it worked very good on my site. And I have changed my hosting recently and they dont support file .png and i made the change it to .jpg and .gif but i showed some error

Warning: imagecreatefrompng(/home/httpd/vhosts/vietfanclub.com/httpdocs/gallery/images/newlogo.jpg): failed to open stream: No such file or directory in /home/fanclub/public_html/gallery/include/picmgmt.inc.php on line 304

Warning: imagesx(): supplied argument is not a valid Image resource in /home/fanclub/public_html/gallery/include/picmgmt.inc.php on line 305

Warning: imagesy(): supplied argument is not a valid Image resource in /home/fanclub/public_html/gallery/include/picmgmt.inc.php on line 306

Warning: imagecopy(): supplied argument is not a valid Image resource in /home/fanclub/public_html/gallery/include/picmgmt.inc.php on line 323


any ideas >???

Logged

foulu

  • Contributor
  • Coppermine frequent poster
  • ***
  • Offline Offline
  • Gender: Male
  • Posts: 236
  • uhm
Re: Permanent Watermark with GD2
« Reply #123 on: March 17, 2005, 03:45:11 am »

path of your server has changed, change it to right value

KlausH

  • Coppermine newbie
  • Offline Offline
  • Posts: 10
Re: Permanent Watermark with GD2
« Reply #124 on: March 18, 2005, 12:07:06 am »

I was unable to modify my original post and I do think that the top post should be the newest version. So I suggest you either split this post off or move it to the first somehow.

I decided to "modify" this mod so it'll work in CPG 1.3 and my brother helped me fix the "_normal" bug


Just installed and works perfectly in CPG 132!

Thanks for this nice stuff!

Greetings

Klaus
Logged

TheGamer1701

  • Coppermine regular visitor
  • **
  • Offline Offline
  • Posts: 52
    • PartyNation.tv - Always the newest Party Facs from North Germany
Re: Permanent Watermark with GD2
« Reply #125 on: March 22, 2005, 10:53:55 am »

Hey,


I applied the hack to my page http://www.partynation.tv/ in the gallery and it works great.
BUT, unfortunetly, I can't make it work to use a transparent image...
Even if I save my png file as a transparent, it won't use it as a transparent watermark...

see the examples (I tried a few different files) in this album:
http://www.partynation.tv/coppermine/thumbnails.php?album=52
(First 4 pictures)

I use IrfanView to modify my pictures... The png file IS transparent.. I tested it with a basic html file and it works.
I attached the picture...


I really hope that someone of you can help me.
I'm not a great graphic guy... :D

(nor is my english really good, sorry)


Thx,
André
Logged

TheGamer1701

  • Coppermine regular visitor
  • **
  • Offline Offline
  • Posts: 52
    • PartyNation.tv - Always the newest Party Facs from North Germany
Re: Permanent Watermark with GD2
« Reply #126 on: March 23, 2005, 06:50:32 pm »

plz... can anyone help me?
Logged

kegobeer

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 4637
  • Beer - it does a body good!
    • The Kazebeer Family Website
Re: Permanent Watermark with GD2
« Reply #127 on: March 24, 2005, 12:59:17 am »

If you are using Internet Explorer, you are out of luck.  IE doesn't display transparent PNG images correctly.  There's an IE PNG fix available on the web - http://koivi.com/ie-png-transparency/
Logged
Do not send me a private message unless I ask for one.  Make your post public so everyone can benefit.

There are no stupid questions
But there are a LOT of inquisitive idiots

TheGamer1701

  • Coppermine regular visitor
  • **
  • Offline Offline
  • Posts: 52
    • PartyNation.tv - Always the newest Party Facs from North Germany
Re: Permanent Watermark with GD2
« Reply #128 on: March 24, 2005, 08:36:39 am »

well, I'm using mozilla firefox...

and actually IE DOES display the transparent png ...
but when I try to watermark my pictures with this png, I don't get an transparent logo...
everything that's meant to be transparent appears white...


any solution?
Logged

Burpee

  • Contributor
  • Coppermine regular visitor
  • ***
  • Offline Offline
  • Gender: Male
  • Posts: 71
    • Vuurwerklook.com
Re: Permanent Watermark with GD2
« Reply #129 on: March 24, 2005, 10:42:54 pm »

Perhaps something is wrong with the way IrfanView processes transparency? I'll attach an image exported in PSP8, try it with that.

kegobeer

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 4637
  • Beer - it does a body good!
    • The Kazebeer Family Website
Re: Permanent Watermark with GD2
« Reply #130 on: March 24, 2005, 11:04:49 pm »

Something is up, because IE does not handle PNG-24 alpha transparency correctly.  Unless of course your images are PNG-8 with binary transparency, which IE does handle properly.

Go here and see how a PNG-24 image displays with and without the PHP fix.

This could be an issue with the type of PNG image you are trying to superimpose.  Try both PNG-8 and PNG-24 and see if either one of them displays correctly when applied as a watermark.
Logged
Do not send me a private message unless I ask for one.  Make your post public so everyone can benefit.

There are no stupid questions
But there are a LOT of inquisitive idiots

Burpee

  • Contributor
  • Coppermine regular visitor
  • ***
  • Offline Offline
  • Gender: Male
  • Posts: 71
    • Vuurwerklook.com
Re: Permanent Watermark with GD2
« Reply #131 on: March 25, 2005, 02:05:31 am »

Kegobeer, the images are applied on the server on upload. I don't think this is an issue with IE, I think it's an issue with GD2 not properly reading and applying the file.

kegobeer

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 4637
  • Beer - it does a body good!
    • The Kazebeer Family Website
Re: Permanent Watermark with GD2
« Reply #132 on: March 25, 2005, 02:48:54 am »

Yeah, I'm sure you're correct, Burpee.  Perhaps an older version?
Logged
Do not send me a private message unless I ask for one.  Make your post public so everyone can benefit.

There are no stupid questions
But there are a LOT of inquisitive idiots

Burpee

  • Contributor
  • Coppermine regular visitor
  • ***
  • Offline Offline
  • Gender: Male
  • Posts: 71
    • Vuurwerklook.com
Re: Permanent Watermark with GD2
« Reply #133 on: March 25, 2005, 03:03:26 pm »

I somewhat doubt it, GD2 doesn't change that much for as far as I know. However, the file that he attached was somewhat big in size for an image that small. If you look closely, you'll see that the image I attached is only half that size. Hopefully that will fix it for him.

Stramm

  • Dev Team member
  • Coppermine addict
  • ****
  • Country: 00
  • Offline Offline
  • Gender: Male
  • Posts: 6006
    • Bettis Wollwelt
Re: Permanent Watermark with GD2
« Reply #134 on: March 26, 2005, 05:13:38 pm »

hey, that's a great mod... however there are two things I didn't like
1. no transparency for the watermark
2. it's a final step... you can't undo the watermarking

so I made a mod of the mod. You can set transparency for the watermark and you can redo watermarking. Means you can totally get rid of it, or if you just want to have another watermark.. no problem at all. Other spot on the image... not a problem at all.

So if one of you guys is interested I'd put it up here... or is it wrong to put it in that thread???

Tranz

  • Dev Team member
  • Coppermine addict
  • ****
  • Country: 00
  • Offline Offline
  • Gender: Female
  • Posts: 6149
Re: Permanent Watermark with GD2
« Reply #135 on: March 26, 2005, 05:38:57 pm »

Please create a new thread in a board that you can post. A moderator will move accordingly.
Logged

Stramm

  • Dev Team member
  • Coppermine addict
  • ****
  • Country: 00
  • Offline Offline
  • Gender: Male
  • Posts: 6006
    • Bettis Wollwelt
Re: Permanent Watermark with GD2
« Reply #136 on: March 26, 2005, 06:14:45 pm »

OK, it's in support-1.3-misc
hope you like it

TheGamer1701

  • Coppermine regular visitor
  • **
  • Offline Offline
  • Posts: 52
    • PartyNation.tv - Always the newest Party Facs from North Germany
Re: Permanent Watermark with GD2
« Reply #137 on: March 26, 2005, 07:49:43 pm »

Hey Burpee, I just fell in Love with you :-)


That image works perfectly, thank you very much.

Do you know where the error was?
thx
Logged

Burpee

  • Contributor
  • Coppermine regular visitor
  • ***
  • Offline Offline
  • Gender: Male
  • Posts: 71
    • Vuurwerklook.com
Re: Permanent Watermark with GD2
« Reply #138 on: April 03, 2005, 03:17:31 am »

No problem :)

I think the error was that IrfanView was not producing the right kind of PNG, messing up the alpha layer.

mr_summoner

  • Coppermine newbie
  • Offline Offline
  • Posts: 1
Re: Permanent Watermark with GD2
« Reply #139 on: April 06, 2005, 01:19:39 pm »

Code: [Select]
Warning: imagecreatefrompng(): open_basedir restriction in effect. File(/PG/watermark.png) is not within the allowed path(s):
hi..
this is my  first post here. i got the above error...i think it is about "Which file to use for watermark "..
i just dont know how to insert the correct path for my watermark image.
this is my link to my watermark image... http://ftsmania.com/PG/watermark.png
my coppermine is in the PG folder.... anyone please help me...
Logged
Pages: 1 ... 3 4 5 6 [7] 8 9 10   Go Up
 

Page created in 0.034 seconds with 20 queries.