Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 3.5 > vBulletin 3.5 Add-ons
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
Minimum Picture Size Details »»
Minimum Picture Size
Version: 1.00, by Marco van Herwaarden Marco van Herwaarden is offline
Developer Last Online: Dec 2010 Show Printable Version Email this Page

Version: 3.5.1 Rating:
Released: 11-24-2005 Last Update: Never Installs: 7
DB Changes Template Edits
Code Changes  
No support by the author.

<font size="4">Minimum Picture Size - Version 1.00</font>

Hack: Minimum Picture Size
Version: v1.00
Author: MarcoH64

Description
With this modification installed you can set minimum dimensions (width & height) for image attachments.
There are some file edits needed to make this work.
Some of the edits are optional, read the Install.txt

Notes
Copyright ©2005 MarcoH64
This Modification may not be redistributed in whole or significant part or changed without prior agreement of author.
Please don't forget to click Install.
If you like this work and would like to support the author, donations are always welcome at Paypal: Marcoh64 AT gmail.com

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #12  
Old 12-31-2005, 06:25 AM
dcpaq2xx dcpaq2xx is offline
 
Join Date: Nov 2004
Location: Merrillville, Indiana
Posts: 362
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by MarcoH64
Yes, and i am sure (most) coders are fully aware of that, and will do whatever is possible/practical to write modifications that don't require file editing. Sometimes however there is just no other solution.

Just to asure you, even if you overwrite the files, it will not make your baord crash, it will just stop checking for minimum sizes.
Marco,

I do know that, I really didn't need to be told that.

I was just trying to explain why I like plugins over hacks. Thats all.

A reply to this really wasn't needed.

Also if it stops checking for minimum sizes then it's done exactly what I DON'T want it to do, which was what I was trying to tell you as to why I like plugins versus modifying code.

Anyway I guess I shouldnt have said anything.

Doug
Reply With Quote
  #13  
Old 01-05-2006, 07:05 AM
dcpaq2xx dcpaq2xx is offline
 
Join Date: Nov 2004
Location: Merrillville, Indiana
Posts: 362
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Marco,

I noticed some text in the error message that Id like to change to my own wording.

One is in the error message for the minimum image size.

What phrase or template would I change this in?

Copy of DSC05823.JPG:
The Minimum Dimension limits for this filetype are 640 x 480. We were unable to resize your file so you will need to do so manually and upload it again. Your file is currently 320 x 200.

Thanks

Doug
Reply With Quote
  #14  
Old 01-14-2006, 04:00 AM
dcpaq2xx dcpaq2xx is offline
 
Join Date: Nov 2004
Location: Merrillville, Indiana
Posts: 362
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by dcpaq2
Marco,

I noticed some text in the error message that Id like to change to my own wording.

One is in the error message for the minimum image size.

What phrase or template would I change this in?

Copy of DSC05823.JPG:
The Minimum Dimension limits for this filetype are 640 x 480. We were unable to resize your file so you will need to do so manually and upload it again. Your file is currently 320 x 200.

Thanks

Doug
Can anyone help me with this question?

Doug
Reply With Quote
  #15  
Old 01-19-2006, 06:28 PM
Marco van Herwaarden Marco van Herwaarden is offline
 
Join Date: Jul 2004
Posts: 25,415
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by dcpaq2
Can anyone help me with this question?

Doug
I am not a PC where i have my files right now. But search Phrases for 'mh_' in the variable name.
Reply With Quote
  #16  
Old 06-07-2006, 06:03 PM
dcpaq2xx dcpaq2xx is offline
 
Join Date: Nov 2004
Location: Merrillville, Indiana
Posts: 362
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Marco,

Its been awhile now and havent heard anything new on this...

Where or how can I edit the text within the error message?

Thanks

Doug
Reply With Quote
  #17  
Old 06-21-2006, 10:00 AM
dcpaq2xx dcpaq2xx is offline
 
Join Date: Nov 2004
Location: Merrillville, Indiana
Posts: 362
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

When I did my last upgrade of Vbulletin it appears to have wiped out all my code changes and I am now going around trying to figure out what got wiped out, as the hack no longer works because of this.

I noticed a change that VB made in the admincp/attachment.php file, line one is not there anymore. And if I put that line one back in as indicated in the "replace by" will this effect anything? Im not sure what changes have been made between the two versions regarding this line.

Oh how I like plugins, so much easier.

Doug
------------------------------------------------------------------------
Code:
Find:

1.) $types = $vbulletin->db->query("
2.) SELECT extension, size, height, width, enabled, thumbnail, newwindow
3.) FROM " . TABLE_PREFIX . "attachmenttype
4.) ORDER BY extension");
.......................................................................................................
REPLACE BY:

// Hack: Minimum Picture Size (MarcoH64)
//	$types = $vbulletin->db->query("
//		SELECT extension, size, height, width, enabled, thumbnail, newwindow
//		FROM " . TABLE_PREFIX . "attachmenttype
//		ORDER BY extension
//	");
	$types = $vbulletin->db->query("
		SELECT extension, size, height, width, enabled, thumbnail, newwindow, mh_mps_minwidth, mh_mps_minheight
		FROM " . TABLE_PREFIX . "attachmenttype
		ORDER BY extension
	");
	// / Hack: Minimum Picture Size (MarcoH64)
Reply With Quote
  #18  
Old 06-21-2006, 10:48 AM
dcpaq2xx dcpaq2xx is offline
 
Join Date: Nov 2004
Location: Merrillville, Indiana
Posts: 362
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Update...

From what I can see it appears that the "newattachment.php" file at root, and the "attachment.php" file in the admincp folder were the main files that got replaced by Vbulletin during an upgrade; or possibly another hack install?

The theme style templates "new attachment" and "new attachment key bits" were not effected at all.

Also it appears that having $types = $vbulletin->db->query(" put back in doesnt seem to have any effect on Vbulletin or the hack from what I can see.

Doug
Reply With Quote
  #19  
Old 06-21-2006, 01:33 PM
aLReeMi aLReeMi is offline
 
Join Date: Jun 2006
Posts: 24
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

thanks alot
Reply With Quote
  #20  
Old 06-21-2006, 01:37 PM
dcpaq2xx dcpaq2xx is offline
 
Join Date: Nov 2004
Location: Merrillville, Indiana
Posts: 362
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by aLReeMi
thanks alot
Huh? Thanks alot for what aLReeM ?

Doug
Reply With Quote
  #21  
Old 06-21-2006, 03:59 PM
Marco van Herwaarden Marco van Herwaarden is offline
 
Join Date: Jul 2004
Posts: 25,415
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by dcpaq2
When I did my last upgrade of Vbulletin it appears to have wiped out all my code changes and I am now going around trying to figure out what got wiped out, as the hack no longer works because of this.

I noticed a change that VB made in the admincp/attachment.php file, line one is not there anymore. And if I put that line one back in as indicated in the "replace by" will this effect anything? Im not sure what changes have been made between the two versions regarding this line.

Oh how I like plugins, so much easier.

Doug
------------------------------------------------------------------------
Code:
Find:
 
1.) $types = $vbulletin->db->query("
2.) SELECT extension, size, height, width, enabled, thumbnail, newwindow
3.) FROM " . TABLE_PREFIX . "attachmenttype
4.) ORDER BY extension");
.......................................................................................................
REPLACE BY:
 
// Hack: Minimum Picture Size (MarcoH64)
//    $types = $vbulletin->db->query("
//        SELECT extension, size, height, width, enabled, thumbnail, newwindow
//        FROM " . TABLE_PREFIX . "attachmenttype
//        ORDER BY extension
//    ");
    $types = $vbulletin->db->query("
        SELECT extension, size, height, width, enabled, thumbnail, newwindow, mh_mps_minwidth, mh_mps_minheight
        FROM " . TABLE_PREFIX . "attachmenttype
        ORDER BY extension
    ");
    // / Hack: Minimum Picture Size (MarcoH64)
It would be very helpfull if you stated the vB version you are trying to install it on.

PS Since this is a code edit hack, chances are always there that it will not work on a new version, or only modified.
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 06:13 PM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.05901 seconds
  • Memory Usage 2,316KB
  • Queries Executed 25 (?)
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
  • (2)bbcode_code
  • (5)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (2)pagenav_pagelink
  • (11)post_thanks_box
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (11)post_thanks_postbit_info
  • (10)postbit
  • (11)postbit_onlinestatus
  • (11)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