stacking watermark and crop on a dynamic image |
[eluser]Unknown[/eluser]
i'm having a problem using the image manipulation library to create a dynamic logo. i have a text watermark and a crop function that won't run together. in a few forums it just says to re-initialize the library, which i did, and it didn't work. i attached the code. i also tweaked the image_lib a bit because it wasn't aligning the text watermark right properly(it was figuring my font incorrectly for distance, so instead of using the basic math, i used imagettfbbox to get the width and divided by the strlen to get the fontwidth properly) and so that i could create a value called $textwidth that would hold the width of the text. i would then add the textwidth together with the 210 pixels i used for the image on the right and i get my x_axis for cropping. but, the crop doesn't trigger unless i remove the watermark. i've turned on display_errors and got nothing. i have done unset($config) before i reconfigured the crop. nothing happened. I assume it's because it is calling imagejpeg() and essentially ending any more editing to that image... any help would be appreciated Code: $config['image_library'] = 'gd2';
[eluser]hebe_210[/eluser]
Thx ,Im now on this kind of stuff .and I 've found a watermarking guide through google .share with you all. |
Welcome Guest, Not a member yet? Register Sign In |