views:

63

answers:

1

When linking to a resized image by PHPThumb to popup in a lightbox using either thickbox or colorbox, I am getting a lightbox come up with data and characters. I am guessing because thickbox does not see my image as a real image because it is outputted with the php extension:

includes/phpThumb/phpThumb.php?src=includes/kcfinder/upload/files/1209679628284.jpg&w=800&h=600&zc=1

Anybody know a solution?

Also, is using PHPThumb for a content management system a good idea? Would just resizing the image to multiple sizes work better on more setups/server configs?

LINK: http://jeffkilroy.com/hosted/ImageIssue/test.php

+1  A: 

Fixed it.

Thickbox (and I'm sure colorbox as well) gets the file extension:

 var urlString = /\.jpg$|\.php$|\.jpeg$|\.png$|\.gif$|\.bmp$/;

added .php in there as well as the following if statement:

if(urlType == '.php' ||urlType == '.jpg' || urlType == '.jpeg' || urlType == '.png' || urlType == '.gif' || urlType == '.bmp'){

And it works!

kilrizzy