image-resizing

Tim Thumb for an External Host / CDN

I'm running a stock copy of tim thumb on a clients website. Works great but does not support external hosts for the pictures. My clients uses an amazon CDN / Flickr for all of their websites pictures which doesnt allow me to resize on the fly. Has anyone found a work around for this? http://code.google.com/p/timthumb/ ...

How to resize a image with jquery

I want to resize a img on a click function. Here is my code that is currently not working. I am not sure if I am doing this correctly at all, any help would be great. <script> $(document).ready(function(){ $("#viewLarge").click( function(){ $("#newsletter").width("950px"); }); }); </script> <a id="viewLarge" class="prepend-7" href=...

How to change picture file dimension in C#?

Hi, I am working a mvc web app. I upload a image to use it as system logo. Now if I select image and upload it, it can be replaced easily until image file is not of large dimesion. For file with large dimension i need to reduce its size to some smaller size to make it look like a system logo. Preferable size for my logo is 100x75. How ca...

Image resize PHP

Hi, Im trying to create a simple image resize feature, can you tell me where i'm going wrong: //resize image $imageSrc = imagecreatefromjpeg('http://www.katsmurals.com/cms/'.$target_path); $width = imagesx($imageSrc); $height = imagesy($imageSrc); echo $width; echo $height; //new dimensions $i = $width; $j = $height...

Imagecopyresampled Auto-Crop Image

I'm using imagecopyresampled to create thumbnails based on a certain width and height. The problem I'm having is that their height is being squished. What I want is for all thumbnail images to be 140x84 and if their aspect ratio does not match that the top and bottom extra portions of the image are cropped to center. Here is what I ha...

How is $_GET set in this image-resize code?

Hello, I am working with a script for resizing images. I seem to be getting an error: Error: no image was specified Probably because of this code in the script(image.php): if (!isset($_GET['image'])) { header('HTTP/1.1 400 Bad Request'); echo 'Error: no image was specified'; exit(); } Here is what I...

PHP image resizing not working. Is there a file size limit?

I'm using a simple image manager class, and the following code: <?php include('SimpleImage.php'); $image = new SimpleImage(); $image->load($target_path); if($image->getWidth() > 500) { $image->resizeToWidth(500); echo "<p>Image Resized</p>"; } else echo "<p>Image did not need to be resized.</p>"; $image->save($target_path); echo...

how to create proportional image height/width

So, I want to have an image resized to 30% of its original height/width. Pretend you don't know its height or width, how would you go about it using only CSS/HTML? ...

jQuery image resize gone wrong!

A few days ago, I was wondering why when I set the images' width and length attributes on my site to percentages, it wasn't scaling the image down the way I thought it should. The problem was that I wanted it to scale the image down, but it was actually scaling down the images' container. Anyway, I was actually fond of Pat's suggestion...

Using PHPThumb and Thickbox/Colorbox

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/...

$(doucment).ready(function(){}); and $(window).load(function() {}); confusion

Hello guys, My test product page over at http://www.marioplanet.com/product.htm has some odd behaviors which I could really use some help working out. Now, I had a problem previously with my image resizing, and someone here helped me out by saying that I should nest the image resize inside a $(window).load(function(){}); In order fo...

CSS image percentages behaving wildy

I hope it's not a conflict in my CSS styles somewhere, but on my page (http://www.marioplanet.com/product.htm) I'm trying to apply a CSS rule to all images with a class of FancyBox to shrink them from 25% of their original size. Now, I've heard that this may just be applying to the containing table cell, so please tell me if this is the...

Adjustment to jQuery resize of images to not make them appear large at first

Kind of an awkward title guys, sorry. Anyway, I'm trying to resize my images with the following snippet of jQuery: $(window).load(function(){ $('img.FancyBox').each(function(){ $(this).width($(this).width() * 0.25); }); }); Now, this works, but it would be really nice if I could find a way to specify the images to load 25% of their o...

resize picture c# for web

Goal: I have lots of pictures in many sizes (both dimensions and file size) I'd like to convert these files twice: thumbnail-size pictures pictures that will look OK on a web page and will be as close to a full screen as possible... and keeping the file size under 500KB. HTML Questions: A. What is the best file format to use (jpg,...

Resize and Save Image While Preserving Metadata

Hello All, I am attempting to resize and save an image, which is fairly easy (for instance, see this example). However, using this code strips the metadata information from the image. I can't quite seem to figure out how to preserve the metadata for a jpeg image. *EDIT: Example Code * public static void ResizeMethodThree(string ...

Has anyone used Smart Image Resizer on subdomain sites?

I'm using Smart Image Resizer for dispalying images. This works fine on single site WP. But it does not work for WPMU. Has anyone used Smart Image Resizer in WPMU using subdomains? Update I've found the solution. It's added below. ...

Simple image editing within browser on page (Java/Flash/Javascript)

I have a page that needs simple image editing within the page. It can be either in flash or Java. Are there any open source tools that you can recommend? I am looking for a flash or Java tool that can do the following: Cropping Resizing Nothing else required but simple features like this will be a plus If the above can be done in Jav...

How to resize dynamically loaded image into flash (as3)

Hi Am struggling to find the right as3 code to resize an image once it is dynamically called into the stage and placed in a MC. I am loading using: var myLoader :Loader = new Loader(); mc.addChild(myLoader); var url :URLRequest = new URLRequest("myimage.jpg"); myLoader .load(url ); The stage will eventually open up into fullscreen ...

jquery image resizing and performance

Hi, I have quite an odd problem here - I am using jquery for resizing my background image (png, width: 1793, height: 1200, size: 872kb). My function is here: bgInit = function(img, clbk) { var bgObj = $('#bgImg'); var bgHeight = bgWidth = 0; bgObj.attr('src',img).ready(function(){ var bgRatio = bgObj.height()/bgObj.width(); ...

What's the simplest way in Python to resize an image to a given bounded area?

I'd like to create a function, like: def generateThumbnail(self, width, height): """ Generates thumbnails for an image """ im = Image.open(self._file) im.thumbnail((width, height), Image.ANTIALIAS) im.save(self._path + str(width) + 'x' + str(height) + '-' + self._filename, "JPEG") Where a fi...