Welcome Guest, Not a member yet? Register   Sign In
Image manipulation not working on localhost
#12

[eluser]dsheetz[/eluser]
This is curious... the following code:

---

Code:
$filename = "photo1.jpg";
$config['image_library'] = 'gd';
$config['source_image']    = PHOTOS_DIR . $filename;
$config['create_thumb'] = TRUE;
$config['maintain_ratio'] = TRUE;
$config['width'] = 75;
$config['height'] = 50;
$config['dynamic_output'] = TRUE;

$this->load->library('image_lib', $config);

echo "<pre>";
print_r($config);
echo "</pre>";

echo "<pre>";
print_r($this->image_lib);
echo "</pre>";

if (!$this->image_lib->resize())
{
    echo $this->image_lib->display_errors();
}

Generates the following output:

Code:
Array
(
    [image_library] => gd
    [source_image] => /home/mattturl/stock_library/photo1.jpg
    [create_thumb] => 1
    [maintain_ratio] => 1
    [width] => 75
    [height] => 50
    [dynamic_output] => 1
)

ci_image_lib Object
(
    [image_library] => gd2
    [library_path] =>
    [dynamic_output] =>
    [source_image] =>
    [new_image] =>
    [width] =>
    [height] =>
    [quality] => 90
    [create_thumb] =>
    [thumb_marker] => _thumb
    [maintain_ratio] => 1
    [master_dim] => auto
    [rotation_angle] =>
    [x_axis] =>
    [y_axis] =>
    [wm_text] =>
    [wm_type] => text
    [wm_x_transp] => 4
    [wm_y_transp] => 4
    [wm_overlay_path] =>
    [wm_font_path] =>
    [wm_font_size] => 17
    [wm_vrt_alignment] => B
    [wm_hor_alignment] => C
    [wm_padding] => 0
    [wm_hor_offset] => 0
    [wm_vrt_offset] => 0
    [wm_font_color] => #ffffff
    [wm_shadow_color] =>
    [wm_shadow_distance] => 2
    [wm_opacity] => 50
    [source_folder] =>
    [dest_folder] =>
    [mime_type] =>
    [orig_width] =>
    [orig_height] =>
    [image_type] =>
    [size_str] =>
    [full_src_path] =>
    [full_dst_path] =>
    [create_fnc] => imagecreatetruecolor
    [copy_fnc] => imagecopyresampled
    [error_msg] => Array
        (
        )

    [wm_use_drop_shadow] =>
    [wm_use_truetype] =>
)

Notice how the image library is different for the $config array vs. the image_lib object... could this be indicative of a configuration error?


Messages In This Thread
Image manipulation not working on localhost - by El Forum - 12-31-2008, 11:28 AM
Image manipulation not working on localhost - by El Forum - 12-31-2008, 02:22 PM
Image manipulation not working on localhost - by El Forum - 12-31-2008, 05:06 PM
Image manipulation not working on localhost - by El Forum - 01-27-2009, 03:08 AM
Image manipulation not working on localhost - by El Forum - 01-27-2009, 10:43 AM
Image manipulation not working on localhost - by El Forum - 01-27-2009, 11:18 AM
Image manipulation not working on localhost - by El Forum - 01-27-2009, 11:50 AM
Image manipulation not working on localhost - by El Forum - 01-27-2009, 03:19 PM
Image manipulation not working on localhost - by El Forum - 01-28-2009, 10:36 AM
Image manipulation not working on localhost - by El Forum - 01-28-2009, 10:56 AM
Image manipulation not working on localhost - by El Forum - 01-29-2009, 03:58 PM
Image manipulation not working on localhost - by El Forum - 01-29-2009, 04:11 PM
Image manipulation not working on localhost - by El Forum - 01-29-2009, 04:13 PM
Image manipulation not working on localhost - by El Forum - 01-30-2009, 02:27 AM
Image manipulation not working on localhost - by El Forum - 01-30-2009, 02:33 AM
Image manipulation not working on localhost - by El Forum - 03-28-2009, 07:53 PM
Image manipulation not working on localhost - by El Forum - 12-02-2009, 06:13 AM
Image manipulation not working on localhost - by El Forum - 12-03-2009, 02:10 AM
Image manipulation not working on localhost - by El Forum - 12-03-2009, 08:14 AM



Theme © iAndrew 2016 - Forum software by © MyBB