views:

81

answers:

1

I'm having a problem: I want to resize and watermark an image in CodeIgniter. But I need "dynamic_output" to be TRUE.

$this->image_lib->resize();
$this->image_lib->watermark();

But when resize function fires it returns the image directly.

I don't need to save the image to save temporary copy. Any help?

A: 

Because $config['source_image'] must be set to a relative or absolut server path it is impossible to achieve what you are trying to do with the image library.

I would recommend not doing this with dynamic output, but if you really have to, should look around for a PHP script which can either resize or watermark an image dynamically based on image URLs and use that in conjunction with either the resize/watermark function from Codeigniter's library. Or simply use an entirely different library which supports this.

Calle