开发者

Place an image on top of another

开发者 https://www.devze.com 2023-01-17 05:29 出处:网络
Is there a way to place an image on the top of an other to produce one image?开发者_运维百科imagecopy() can do thatIf you can get away with overlaying the images in your HTML, then just use CSS to pos

Is there a way to place an image on the top of an other to produce one image?开发者_运维百科


imagecopy() can do that


If you can get away with overlaying the images in your HTML, then just use CSS to position two <img> tags on top of each other; the transparent (or semi-transparent) areas of the one on top will let the one behind show through. Easy.

However, if you actually want to output a single merged image (as your use of the 'gd' tag suggests), yes it can be done. You will need to write some code, of course!

Here is a link to pages which discusses how to do it. (there's quite a bit of discussion there, so it's easier to link to it than try to summarise it myself)

  • http://codingforums.com/showthread.php?t=72317
0

精彩评论

暂无评论...
验证码 换一张
取 消