We use cookies to improve your experience. No personal information is gathered and we don't serve ads. Cookies Policy.

ExpressionEngine Logo ExpressionEngine
Features Pricing Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University
Log In or Sign Up
Log In Sign Up
ExpressionEngine Logo
Features Pro new Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University Blog
  • Home
  • Forums

plugin: Image Sizer

Development and Programming

evasion's avatar
evasion
58 posts
17 years ago
evasion's avatar evasion

If the problem is caching you may take a look at the folder’s permission. This folder should be writable, so you might do some ‘chmod’ (ie: chmod 777).

       
ropeadope's avatar
ropeadope
98 posts
17 years ago
ropeadope's avatar ropeadope

Damn you’re good. Thanks again

       
Danny T.'s avatar
Danny T.
426 posts
17 years ago
Danny T.'s avatar Danny T.

Has anyone else had issues resizing to a width of over 500 pixels and have had issues? If I only define one variable, it can only resize to 500 pixels and under. However, if I provide both a width and a height, I am able to go over 500 pixels of width.

More information about my issue can be found at reply #202 of this thread.

       
Joobs's avatar
Joobs
362 posts
17 years ago
Joobs's avatar Joobs

Is there anyway to get this working with the avatars in the EE forum?

I would prefere to use this rather than phpthumb

       
impdesigns's avatar
impdesigns
115 posts
17 years ago
impdesigns's avatar impdesigns

Our PHP/Programming guru has identified an issue in the pi.imgsizer.php file which prevented the plugin from working on our server.

According to him this code (lines 147-151) were giving the plugin the wrong path to the images.

if (array_key_exists('DOCUMENT_ROOT',$_ENV))
        {
            $img_rootstep = $_ENV['DOCUMENT_ROOT']."/".$img_base;
        }
        else

Removing these lines so that

{
            $img_rootstep = $_SERVER['DOCUMENT_ROOT']."/".$img_base;
        }

became the path allowed the plugin to work as advertised.

Our guy thinks it has to do with how cpanel is installed in certain hosting environments. With the code above in place, the plugin was trying to find the image directory inside the directory for cpanel instead of the accounts directory.

Hope this helps some folks….

       
johnm's avatar
johnm
43 posts
17 years ago
johnm's avatar johnm

No go here. I’ve placed cache directories where they should go with 777 permissions, I’ve tweaked all the variables, and I’ve even hard coded image urls rather than use EE tags for gallery entries. No matter what I do the Image Sizer plug in does not parse. Nothing is returned, just blank space? Any ideas? I’d love to use this rather than phpThumb.

       
Deborah Cross's avatar
Deborah Cross
113 posts
17 years ago
Deborah Cross's avatar Deborah Cross

I’ve been using this fabulous plugin with no problems, but today I built a new site and Image Sizer just refuses to work in it. I’ve created the cache folders and all that. I’ve had server admin double check all the settings.

At first I thought it might be because the website and the control panel are accessed via different URLs/folders, but then I realised I already have sites set up that way and working fine.

The only real difference I can see between this new site and the others is the structure of the URL. All the others are www.anu.edu.au/area, but this new site is www-area.anu.edu.au

I tried the suggestion a few posts back from impdesigns about removing the _ENV lines, but this didn’t have any effect.

Any suggestions?

       
Danny T.'s avatar
Danny T.
426 posts
17 years ago
Danny T.'s avatar Danny T.

Deborah,

Can you describe the behaviour of what you mean by it refusing to work? Do you see any cache folders being created in your default image directories?

       
Deborah Cross's avatar
Deborah Cross
113 posts
17 years ago
Deborah Cross's avatar Deborah Cross

Sorry, a bit vague wasn’t it?!

When I use a regular image tag, the image displays fine in the page. When I add the Image Sizer tag, no image displays.

No cache folders were/are being created. So I went into the server and created them myself. But there are still no images in it.

I’m thinking that maybe it can’t find the right path, since Image Sizer works fine on all my other sites. All my other sites have the same start to the URL, and the image path has the same start - www.anu.edu.au/area

This site has a different url: www-area.anu.edu.au, and the images are at www.anu.edu.au/area I’m thinking about getting the admin to change the url, just to see if it fixes the problem. Will report back if/when I get anywhere with this.

Thanks for your help. 😊

       
Danny T.'s avatar
Danny T.
426 posts
17 years ago
Danny T.'s avatar Danny T.

Deborah,

Have you made sure the cache folders have the proper permissions since you’ve created them? Since there all hosted on the same server, I don’t think there is an issue with the different url’s, as you’ve provided direct paths to the folders themselves on your host.

And one more thing.. Are you using single tag or the tag pairs? I’ve had more success with the tag pairs than otherwise.

       
Deborah Cross's avatar
Deborah Cross
113 posts
17 years ago
Deborah Cross's avatar Deborah Cross

Yup, checked those cache folders - open to the world!

Here’s the block of code where I have attempted to display the image. In the profile form I have a relationship field that links to a photo gallery.

The regular img tag works fine (1), but neither of the imgsizer ones (2 and 3) display anything (or create anything in the cache folders).



						
       
Danny T.'s avatar
Danny T.
426 posts
17 years ago
Danny T.'s avatar Danny T.

Code looks clean.. Looks like I won’t be of much help, but in any case you might be right about the absolute paths, etc. to the images on your box. Have you tried running Image Sizer on a more simple task, such as just resizing a weblog entry associated image rather than the related entries to try and isolate/determine the issue?

       
johnboat's avatar
johnboat
61 posts
17 years ago
johnboat's avatar johnboat

If I have a square image and I want to resize it to a rectangle by cropping off equal bits from the top and bottom can Image Sizer do that? In other words I don’t want it to resize the image proportionally, I just want it to crop off the excess. For example if it is a 500x500 image and I set the height to 250 I want a cropped image of 500x250

From reading through this post I think the answer is no, but I wanted to be sure I’m not missing something.

Fantastic plugin btw. I may not be able to use it on this project (need the above functionality) but I am sure it will come in handy in the future.

       
Deborah Cross's avatar
Deborah Cross
113 posts
17 years ago
Deborah Cross's avatar Deborah Cross

mr_dimsum, I tried something much simpler, like placing an image in a folder on the server and manually entering the URL. Again, normal IMG tag displays it fine, but Image Sizer doesn’t do anything with the image. Something strange going on here. Will hold off further testing until my admins change the URL for access and see what happens then I think.

       
Danny T.'s avatar
Danny T.
426 posts
17 years ago
Danny T.'s avatar Danny T.

johnboat.. You should read more carefully. 😊 I actually asked the exact same thing and was provided a clear answer. Back to your q!.. It works as to how you want it. 😊

       
First 13 14 15 16 17 Last

Reply

Sign In To Reply

ExpressionEngine Home Features Pro Contact Version Support
Learn Docs University Forums
Resources Support Add-Ons Partners Blog
Privacy Terms Trademark Use License

Packet Tide owns and develops ExpressionEngine. © Packet Tide, All Rights Reserved.