|
|
| |
1. Generation error on first load |
|
Reply |
|
|
 Michael Hulet | 2005-02-17 13:38:45 |
Hi,
I'm using PThumb, wich is the only one I found not requering ImageMagick and using nice caching functions.
I got a problem, as first load of a thumbnail gives picture as data (hundreds of lines of characters). After reloading page, no problem: thumbnail generated.
I use default options and make the call as this:
[code]
<?php
include_once('class/PThumb.class.php');
// setup des options de génération des miniatures
class thumb extends PThumb
{
function thumb()
{
$this -> PThumb();
$this -> use_cache = true;
$this -> cache_dir = "cache/";
$this -> error_mode = 1;
}
}
$thumbnail = new thumb;
// thumbnail
$thumbnail_location = $thumbnail->fit_thumbnail('photo.jpg', 150, -1);
list($width, $height, $type, $attr) = getimagesize($thumbnail_location);
?>
<img src="<?php echo $thumbnail_location ?>" alt="" />
[/code]
Please can someone help me finding what's going wrong? |
| |
2. Re: Generation error on first load |
|
Reply |
|
|
 Lawliet | 2005-10-02 08:05:58 - In reply to message 1 from Michael Hulet |
o_o I am really sorry for seeing this only now.
I believe the problem is due to some HTTP headers not being sent. If you still have this problem with the newer version, please email me. |
|