Million Dollar Script

You can help!

Donations help improve software by giving developers more time to work on it. Every bit helps, no matter how small.

Amount: 

Welcome, Guest
Username Password: Remember me

Resize Automatically?
(1 viewing) (1) Guest
  • Page:
  • 1

TOPIC: Resize Automatically?

Resize Automatically? 6 months, 1 week ago #519

  • bplazar
  • OFFLINE
  • Fresh Boarder
  • Posts: 2
  • Karma: 0
I see a setting under Main Config that says "Resize uploaded pixels automatically?" which says if you select "Yes" then Uploaded pixels will be resized to fit in to the blocks. I just realized that will use as many blocks as necessary based on the size of the image.

Is there any way to crop the uploaded image to only fit in one block?

I'm not allowing users to select pixels and they can only purchase one block per order.

Re: Resize Automatically? 6 months, 1 week ago #520

  • Ryan
  • OFFLINE
  • Administrator
  • Posts: 208
  • Karma: 7
Hmm, I don't think theres a way to crop the image into one block. I think you would probably have to go into the code and modify it to do what you like in order to accomplish that. If you have any troubles I can probably check the code out and see if I can help find where to modify when I get a chance.

Re: Resize Automatically? 6 months, 1 week ago #524

  • bplazar
  • OFFLINE
  • Fresh Boarder
  • Posts: 2
  • Karma: 0
Thanks Ryan. Any insights you can provide pointing me in the right direction in the code would be HUGE!

Thanks!

Re: Resize Automatically? 5 months, 3 weeks ago #525

  • Ryan
  • OFFLINE
  • Administrator
  • Posts: 208
  • Karma: 7
Sorry for taking so long to check this out. I have been busy with things.

You probably want to mess with the function saveImage in /includes/functions.php. In particular the switch statement where it has all those imagecopyresampled lines.

You can find more info on that function here: php.net/manual/en/function.imagecopyresampled.php

You might also have to modify some other functions somewhere, but I am not really sure where. Maybe I can add that as a feature request for a future version if I ever get there.

Re: Resize Automatically? 1 month, 2 weeks ago #608

  • Ben
  • OFFLINE
  • Fresh Boarder
  • Posts: 2
  • Karma: 0
Hi bplazar,

Did you come right with this? I am also looking at similar feature and your assistance will be appreciated. Thanks
  • Page:
  • 1
Time to create page: 0.19 seconds