From a225738797ebfa565b7380c313a0670a863cbc49 Mon Sep 17 00:00:00 2001 From: Derek Jones Date: Fri, 9 May 2008 17:34:38 +0000 Subject: changed code sample for image library to be gd2 so cut-n-pasters don't accidentally use the gd library --- user_guide/libraries/image_lib.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'user_guide') diff --git a/user_guide/libraries/image_lib.html b/user_guide/libraries/image_lib.html index 77f85ec6d..2b239e8f0 100644 --- a/user_guide/libraries/image_lib.html +++ b/user_guide/libraries/image_lib.html @@ -91,7 +91,7 @@ using the $this->load->library function:

identical. You will set some preferences corresponding to the action you intend to perform, then call one of four available processing functions. For example, to create an image thumbnail you'll do this:

-$config['image_library'] = 'GD';
+$config['image_library'] = 'gd2';
$config['source_image'] = '/path/to/image/mypic.jpg';
$config['create_thumb'] = TRUE;
$config['maintain_ratio'] = TRUE;
@@ -104,7 +104,7 @@ $this->load->library('image_lib', $config); $this->image_lib->resize();

The above code tells the image_resize function to look for an image called mypic.jpg -located in the source_image folder, then create a thumbnail that is 75 X 50 pixels using the GD image_library. +located in the source_image folder, then create a thumbnail that is 75 X 50 pixels using the GD2 image_library. Since the maintain_ratio option is enabled, the thumb will be as close to the target width and height as possible while preserving the original aspect ratio. The thumbnail will be called mypic_thumb.jpg

-- cgit v1.2.3-24-g4f1b