Keyword

Turn Off Auo-Resizing

  • Zach Schnackel
  • Zach Schnackel's Avatar Topic Author
  • Offline
  • New Member
More
14 years 6 months ago #79764 by Zach Schnackel
Turn Off Auo-Resizing was created by Zach Schnackel
Hi, I know the 'auto-resizing' feature (with the XSmall, Small, Medium, etc sizes) are built into K2 to make things easier, but for what I'm trying to do with it is causing this to be a nightmare.I am using K2 to build a moulding catalog. The moulding profiles are always going to be different sizes and the graphics will always be cut exactly to size (as transparent gifs) and this is an important feature so customers know exactly how big these profiles are. So, for K2 to auto-resize these images it is not exactly what we are looking for. I know there is the option to basically place a whole bunch of whitespace around each image, but honestly... a terrible solution.I was looking in the template files (when I created my own) and saw near the top:K2HelperUtilities::setDefaultImage($this->item, 'itemlist', $this->params);I took that out, and I also tried taking out every instance of <img src="<?php echo $this->item->image; ?>" alt="<?php if(!empty($this->item->image_caption)) echo $this->item->image_caption; else echo $this->item->title; ?>" style="width:<?php echo $this->item->imageWidth; ?>px; height:auto;" />to just be:<img src="<?php echo $this->item->image; ?>" alt="<?php if(!empty($this->item->image_caption)) echo $this->item->image_caption; else echo $this->item->title; ?>" />but it looks like the actual resizing is being done in the administrator portion of the site. Is there anyway to stop this from occurring?Thanks for the help in advance!

Please Log in or Create an account to join the conversation.

  • Zach Schnackel
  • Zach Schnackel's Avatar Topic Author
  • Offline
  • New Member
More
14 years 6 months ago #79765 by Zach Schnackel
Replied by Zach Schnackel on topic Turn Off Auo-Resizing
Also, another reason is so I could basically control the image sizes (if I needed to) with something like timThumb instead (for other parts of the site that may need it still and are not dependent on proportions - like the moulding catalog is). Thanks!

Please Log in or Create an account to join the conversation.

More
14 years 6 months ago #79766 by Marty Peet
Replied by Marty Peet on topic Turn Off Auo-Resizing
have a look at this discussion

community.getk2.org/xn/detail/3536014:Topic:12708

Please Log in or Create an account to join the conversation.

  • Zach Schnackel
  • Zach Schnackel's Avatar Topic Author
  • Offline
  • New Member
More
14 years 6 months ago #79767 by Zach Schnackel
Replied by Zach Schnackel on topic Turn Off Auo-Resizing
Marty,
Thanks for the link... it sounds like it's more of a 'manual' process which kinda sucks, but I'll see what I can do with it. Thanks again!

Please Log in or Create an account to join the conversation.

More
13 years 7 months ago #79768 by Marco Profumo
Replied by Marco Profumo on topic Turn Off Auo-Resizing
Noticed that is a common problem in user of K2, hope there will be in next releases an "original image" instead of only the resized ones...

for now I found a solution putting in the templates this code:

<img src="<?php echo JURI::root().'media/k2/items/src/'.md5("Image".$item->id).'.jpg'; ?>" alt="<?php echo $item->title; ?>"/>

 

 

Please Log in or Create an account to join the conversation.


Powered by Kunena Forum