Go Back   vb.org Archive > Community Discussions > Modification Requests/Questions (Unpaid)
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools Display Modes
  #11  
Old 01-22-2006, 12:49 AM
sgtmaj sgtmaj is offline
 
Join Date: Jan 2004
Posts: 16
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

anyone plan to do this auto resize for attachments for 3.5.xxx??
Reply With Quote
  #12  
Old 01-22-2006, 09:13 AM
Snake's Avatar
Snake Snake is offline
 
Join Date: Mar 2005
Location: Cleveland, OH
Posts: 3,832
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Attachments can be resized already as it is a default feature in vBulletin 3.5.x.
Reply With Quote
  #13  
Old 02-07-2006, 08:35 PM
BillP BillP is offline
 
Join Date: Nov 2001
Posts: 38
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Aftermath-

Please explain how resize of attachments work. Because as far as I can tell, it does NOT.

It will make a thumbnail, but the original picture MUST be within the Attachments dimensions and byte size limits as set in the AdminCP.
Reply With Quote
  #14  
Old 02-07-2006, 09:46 PM
mvigod mvigod is offline
 
Join Date: Dec 2001
Location: Jersey
Posts: 159
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by BillP
Aftermath-

Please explain how resize of attachments work. Because as far as I can tell, it does NOT.

It will make a thumbnail, but the original picture MUST be within the Attachments dimensions and byte size limits as set in the AdminCP.

You are correct. It does not resize the image. This hack has yet to be ported to 3.5.

Looking at this I think the following steps would be required to implement this:

1) hack requires possibly increasing your max upload setting php.ini depending where it is set.
2) Next you would have to take the uploaded image (without size or dimension limits) and check to see if it exceeds your set large image size (i.e. 800x600) and if so resize it to the max horizontal/vertical depending on the originals aspect ratio.
3) Next you create the thumbnail.
4) Finally you delete the original oversized image to clean up when done.

Andreas mentioned this could possibly be written as plugin or product but I have not had a chance to figure out how. If anybody wants to take a crack at it then definitely have at it. I don't want to waste time hardcoding it in a file if it can be simplified for others to install as product.
Reply With Quote
  #15  
Old 02-07-2006, 10:45 PM
BillP BillP is offline
 
Join Date: Nov 2001
Posts: 38
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I have some additional needs....

I'd like the ability to resize existing attachments. Right now the user or the administrator or moderator must save it to their local computer, resize it there, and then upload it to the post.

I'd like the option of using the Attachments Management interface, and where you "edit" have an option to resize in place. I imported my site from Invisionboard, and am now implementing size restrictions, so it would be really valuable to have a "resize in place" function.

A "mass resize in place" script would be really cool. Maybe I'll end up writing that... since I store my attachments in the file system I can simply find a large image in the database, read it its file location, run it through "convert", and then update the database with the new size.

==========edited later==============
I was just looking at the database, VB also stores a filehash for the attachment. Anyone know what that is used for? Is it critical that I fix up that field if I resize the image via a script?
Reply With Quote
  #16  
Old 02-07-2006, 11:32 PM
mvigod mvigod is offline
 
Join Date: Dec 2001
Location: Jersey
Posts: 159
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

billp - check if there is any actual data in the filehash field. I think in my db it is empty.
Reply With Quote
  #17  
Old 02-08-2006, 02:26 AM
BillP BillP is offline
 
Join Date: Nov 2001
Posts: 38
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

There's data in mine.

I wonder if it's from moving the files in and out of the database. It could be a way to ensure that the binaries remain unaltered in the database.
Reply With Quote
  #18  
Old 04-09-2006, 01:21 PM
wrang wrang is offline
 
Join Date: Oct 2004
Location: Sweden
Posts: 161
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Yes i want this to.
If a member upload a image like 1200pix with and i haved set that max with is 900pix it should automatic resize the image to 900

is this possible
Reply With Quote
  #19  
Old 04-16-2006, 09:33 PM
toolblast's Avatar
toolblast toolblast is offline
 
Join Date: Mar 2004
Posts: 266
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hey all!

I was looking for a hack that would automatically resize all avatars to a certain dimention. So, for example, I want all avatars to be say... 25x25 in dimention. If the user tries to upload an image that is 26x30, instead of telling him "sorry, upload another one", it would instead automatically resize the image to fit perfectly.

Does the current vb 3.5 version do this? If so, where do I go to set up this setting?

Thanks.
Reply With Quote
  #20  
Old 04-17-2006, 04:00 AM
fneumeier fneumeier is offline
 
Join Date: Mar 2006
Posts: 16
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

>If a member upload a image like 1200pix with and
>i haved set that max with is 900pix it should automatic
>resize the image to 900

I'm looking for such a plugin or hack for vBulletin for quite a while and found a lot of postings here from people who want the same. But so far, no solution for this. It works for Avatars and Profile pics, but not for "normal" attachment pics.

My approach is: Make it as easy as possible to the user to upload pictures (which is: don't force them to understand pixel resolution, resizing pictures, etc. but just let them upload their digital camera images as they are and the software does the rest).
But the main stream here seams to be: Picture posting only for the tech geeks :-(
An other opinion is: Do resize with "width/height" tag in HTML (which from my point of view is a very silly idea when it comes to a 5- or 8-Megapixel picture ...

Using GDlib it's only a few lines of code to automatically resize a picture, really simple. But I just can't find the hook or position in the code of vBulletin to do it by myself.

***hint*** Maybe someone from the developers can let us know where in the code the image upload is handled and where the best place would be to add the resize code??? ***hint***

Franz
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 05:24 PM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.04609 seconds
  • Memory Usage 2,251KB
  • Queries Executed 11 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)ad_showthread_firstpost
  • (1)ad_showthread_firstpost_sig
  • (1)ad_showthread_firstpost_start
  • (1)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (2)pagenav_pagelink
  • (10)post_thanks_box
  • (10)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (10)post_thanks_postbit_info
  • (10)postbit
  • (10)postbit_onlinestatus
  • (10)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete