Go Back   vb.org Archive > vBulletin Modifications > vBulletin 3.8 Modifications > vBulletin 3.8 Template Modifications
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
Control signatures height per pixel with CSS Details »»
Control signatures height per pixel with CSS
Version: 1.00, by Mazinger Mazinger is offline
Developer Last Online: Feb 2019 Show Printable Version Email this Page

Category: Show Thread Enhancements - Version: 3.8.x Rating:
Released: 12-01-2008 Last Update: Never Installs: 83
Template Edits
 
No support by the author.

This mod will help you determine a fixed height for signatures in posts with CSS to prevent members from having a large annoying signature. (it will cut from the signature and hide the rest of it) - screenshot attached.

Long signatures and signatures with alot of images will not be an issuse anymore!


INSTALLATION


EDIT postbit OR postbit_legacy (which you use) and search for:

HTML Code:
$post[signature]
Replace it with

HTML Code:
<div class="fixedsig">$post[signature]</div>
Then go to the style option and add these lines in the CSS

HTML Code:
.fixedsig {
max-height:250px;
height:expression((document.documentElement.clientHeight) > 250? "250px" : "100%");
overflow:hidden;
}
You can change the 250 to the height you want (per pixels)

And you're done!


SUPPORT


Please click Mark as Installed if you want to get support for this mod.

Screenshots

File Type: jpg comp.jpg (130.1 KB, 0 views)

Show Your Support

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

Comments
  #22  
Old 03-01-2009, 06:35 PM
Mazinger's Avatar
Mazinger Mazinger is offline
 
Join Date: Nov 2006
Location: Egypt
Posts: 355
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I would recommend using an image resizer mod for this.
Reply With Quote
  #23  
Old 03-01-2009, 06:53 PM
trotskid trotskid is offline
 
Join Date: Feb 2009
Posts: 204
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

ImageResizer don?t works very well on my forum (3.8.1) :S. Instead of this I use Resize IMG tag with Highslide but only for images.

Thanks anyway, and thanks also for this hack
Reply With Quote
  #24  
Old 03-09-2009, 10:22 AM
HolyKiller HolyKiller is offline
 
Join Date: Dec 2006
Posts: 172
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Mazinger View Post
I would recommend using an image resizer mod for this.
This is 100% better cos this restriction crop (or scrool) EVERYTHING, not only IMG tags. Even texts, hyperlinks, quote/code bars ... everything. So the signature is strictly cut everything larger than XXX px.

Love this hack
Reply With Quote
  #25  
Old 03-09-2009, 09:11 PM
Mazinger's Avatar
Mazinger Mazinger is offline
 
Join Date: Nov 2006
Location: Egypt
Posts: 355
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Love your comment too.
Reply With Quote
  #26  
Old 03-28-2009, 09:59 PM
Pteppic Pteppic is offline
 
Join Date: May 2008
Posts: 2
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I'm getting different problems with IE and Firefox. In the former, the signatures that are within the limit are stretched to fit it. This is not a problem in Firefox, although youtube videos embedded in signatures (by specialised bbcode) bleed over into the post below (or whatever's there). I suppose the embedding html overrides the mod somehow, but as a complete CSS noob, I haven't a clue how to fix it, and the IE stretching thing I can't figure out at all. (Screenshots attatched)
Attached Images
File Type: jpg firefox.jpg (85.3 KB, 0 views)
File Type: jpg IE.jpg (81.0 KB, 0 views)
Reply With Quote
  #27  
Old 03-29-2009, 02:11 PM
Mazinger's Avatar
Mazinger Mazinger is offline
 
Join Date: Nov 2006
Location: Egypt
Posts: 355
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I think my mod have no control over flash objects in Firefox, may be there's something that can be done to solve it - I don't it now, sorry!
Reply With Quote
  #28  
Old 03-29-2009, 06:36 PM
Pteppic Pteppic is offline
 
Join Date: May 2008
Posts: 2
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Well, necessity is the mother of invention , and I managed to find some solutions on my own - I set the wmode parameter in the embedding code to opaque and used "this.scrollHeight" in the css instead of "(document.documentElement.clientHeight)".
Reply With Quote
  #29  
Old 04-12-2009, 09:23 PM
Mike08 Mike08 is offline
 
Join Date: Sep 2006
Posts: 47
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by trotskid View Post
Thank you Mazinger!

It?s posible to limit also the width?

Greetings
Quote:
Originally Posted by Mike08 View Post
Thanks!!! It works!

I needed a code to modify the width of the signature. So with your permission I have adapted to modify the code in height and width.

Here it is. Example with 800x300px.

HTML Code:
.fixedsig {
max-width:800px;
width:expression((document.documentElement.clientWidth) > 800? "800px" : "100%");
overflow:hidden;

max-height:300px;
height:expression((document.documentElement.clientHeight) > 300? "300px" : "100%"); }
Here it is

****IMPORTANT: Place this code at very top of CSS.
Reply With Quote
  #30  
Old 04-26-2009, 05:05 PM
EvilJohn's Avatar
EvilJohn EvilJohn is offline
 
Join Date: Apr 2006
Posts: 80
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thank you. Works very well. :up:
Reply With Quote
  #31  
Old 08-17-2009, 06:38 AM
HayleyP HayleyP is offline
 
Join Date: Jun 2007
Posts: 18
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I used the "scroll" instead of "hidden" but how do I make it so if the signature is the right size, you can't see the scroll bars?
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 01:10 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.06745 seconds
  • Memory Usage 2,333KB
  • Queries Executed 26 (?)
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
  • (4)bbcode_html
  • (3)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (4)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (3)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
  • (3)postbit_attachment
  • (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_attachment
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete