tags:

views:

103

answers:

3

I have a website where users may upload images...

I need to add my logo (watermark) to the images once they are uploaded.

How can I do so?

And it is important that the watermark is in a corner where it will be visible, for example I have seen websites which generates a watermark on the fly, and puts the mark wherever the background of the main image is "the same color" so the watermark sticks out if you know what I mean.

Anybody have a good tutorial or article about this? Or know of any function in php which I would need to find the position of the watermark?

Thanks

+2  A: 

A good example in the PHP manual:

http://www.php.net/manual/en/image.examples-watermark.php

XUE Can
+1  A: 

This can be done using an image manipulation library such as GD or ImageMagick. Here is a tutorial that explains a way to do it using GD:

http://articles.sitepoint.com/article/watermark-images-php

Jimmy Cuadra
+1  A: 

ImageMagick works well for that. I've done it before. The whole business is a bit of a pain, though. Especially if you want fancy blending modes and the like.

Gabriel Hurley