![]() |
watermarking text - and having it CENTERED? - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20) +--- Forum: Archived Libraries & Helpers (https://forum.codeigniter.com/forumdisplay.php?fid=22) +--- Thread: watermarking text - and having it CENTERED? (/showthread.php?tid=57098) |
watermarking text - and having it CENTERED? - El Forum - 02-14-2013 [eluser]dootzky[/eluser] hi guys, I love our CI library for watermarking. It works perfectly with images, and with text. However, I ran into this problem - - when I want to watermark a text, which has 4 lines - and I want to center it - there is no way to center it in CI $config when using image library Please see attached. That will explaing what I am trying to accomplish, and what I'm getting as a result. Is there anyway to tell our CI library to "center" text (so not "justify", or keep it to the "left" side, but CENTER it)? Thanks for any help or insight you can give me! ![]() Dusan Loving CI member for over 4 years! ![]() watermarking text - and having it CENTERED? - El Forum - 02-14-2013 [eluser]Aken[/eluser] Unfortunately that's not possible out of the box. You'll need to modify the library to suit your needs. The way to center text is to write each line of text to the image separately, aligning them as centered as you go depending on their widths. There's a handful of PHP snippets out there that should help. watermarking text - and having it CENTERED? - El Forum - 02-15-2013 [eluser]dootzky[/eluser] alright, I'll try to do something like that and share the code here if I make it work. ![]() thanks for your quick reply man! ![]() d |