Go Back   vb.org Archive > vBulletin 4 Discussion > vB4 Programming Discussions
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools Display Modes
  #11  
Old 12-28-2016, 08:56 PM
TrultToast's Avatar
TrultToast TrultToast is offline
 
Join Date: Aug 2013
Posts: 36
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Seven Skins View Post
I don't see that on your site.



You cannot insert table in ol or ul lists... as mentioned earlier warp the table in li tag or move the table out of ol tags.
Just moved the table out of the ol tags and placed it above them.
The problem still exists.

Apparently this problem also exists with the "nonthread" class on the forumdisplay template when there are no posts in the forum.
Ugh..
Reply With Quote
  #12  
Old 12-29-2016, 02:45 AM
TheLastSuperman's Avatar
TheLastSuperman TheLastSuperman is offline
Senior Member
 
Join Date: Sep 2008
Location: North Carolina
Posts: 5,844
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hey everyone, don't forget about the css calc ability .

Try changing the template code to this:
Code:
<ol id="forums" class="floatcontainer" style="max-width:calc(100% - 2px) !important;">
See if that does it. I hate using style= in any css call, I prefer to define any css changes in the actual definition but sometimes when you customize a style or theme from another software a direct inline edit is required else you'll pull your hair out trying to figure out where you went wrong along the way lol.

So by saying go 100% we will but then we tell it to remove the spare 2px we noticed it increased. By using max-width we told it not to be bigger than 100% but somewhere as you can all plainly see something else bumped it up, I'd imagine some additional padding added somewhere along the line while you were customizing your style.
Reply With Quote
2 благодарности(ей) от:
MarkFL, TrultToast
  #13  
Old 12-29-2016, 02:09 PM
MarkFL's Avatar
MarkFL MarkFL is offline
 
Join Date: Feb 2014
Location: St. Augustine, FL
Posts: 3,853
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by TrultToast View Post
Thanks for explaining. I was about to ask that question too, lol.
Any chance you could help me fix my forumhome template too? Sorry to be a bother... I tried using the code you supplied above in a few spots but I had no luck in fixing the borders in my statistics box.
Borrowing on Mike's suggestion, add this to your "additional.css" template:

HTML Code:
#info {
	width:calc(100% + 2px) !important;
}
This will make the statistics box 2px wider, rather than making the forums boxes 2px narrower. Either way will work though.
Reply With Quote
Благодарность от:
TheLastSuperman
  #14  
Old 12-30-2016, 03:36 AM
TrultToast's Avatar
TrultToast TrultToast is offline
 
Join Date: Aug 2013
Posts: 36
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thank you very much Mike and Mark!
When I tried Mikes suggestion. It sadly did nothing, but when I did what mark suggested and put Mikes code in my additional.css file under the class "#info", it did work.

Thank you both very much again!

edit:
Just out of curiosity, is there a reason why I need to keep adding this to some of my boxes? Like what did I do wrong to make 100% not work correctly without adding "width: calc(100% + 2px) !important;"??
Reply With Quote
  #15  
Old 12-30-2016, 11:38 AM
Seven Skins's Avatar
Seven Skins Seven Skins is offline
 
Join Date: Sep 2008
Location: London, UK
Posts: 1,481
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by TrultToast View Post
Just out of curiosity, is there a reason why I need to keep adding this to some of my boxes? Like what did I do wrong to make 100% not work correctly without adding "width: calc(100% + 2px) !important;"??
Because vBulletin did not use Box Sizing whilst developing the forums hence we have issue. When you add borders to an element it get added to the element e.g. if you have 100px square element and you add 1px border the resulting box size will be 102px x 102px.

More info here: .. https://css-tricks.com/box-sizing/
Reply With Quote
2 благодарности(ей) от:
TrultToast, z3r0
  #16  
Old 01-01-2017, 04:41 PM
TheLastSuperman's Avatar
TheLastSuperman TheLastSuperman is offline
Senior Member
 
Join Date: Sep 2008
Location: North Carolina
Posts: 5,844
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

^ Also to further elaborate on what Seven Skins was explaining in regards to adding borders... if you add a border to an element that did not have it prior, it can cause any sub-elements or those who "used to" share a similar css definition appear differently hence what SevenSkins was explaining with the now its 102px wide comment above but now similar areas will look smaller as they were not adjusted. In the past I've went so far as to trace down all the other elements and added in:

Code:
border: 1px solid transparent !important;
So the other elements would then line up properly, especially in drop-down style menus where on hover the menu item shifts slightly but I do not recommend that at all, only in "it must be done" scenarios. Remember to always try proper css first i.e. CSS Class/ID + CSS Definition instead of for example in my previous reply above style="codehereforcss" because doing something properly and especially in html/css can mean the difference between something looking right and more so acting right! Also don't forget to check in all major browsers when you're done "tweaking" because typically Internet Explorer just doesn't jive etc the point being attempt it proper first, only "make due" when you absolutely must .
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 11:29 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.07620 seconds
  • Memory Usage 2,234KB
  • Queries Executed 13 (?)
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
  • (2)bbcode_code
  • (1)bbcode_html
  • (3)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
  • (1)pagenav_pagelink
  • (6)post_thanks_box
  • (5)post_thanks_box_bit
  • (6)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (3)post_thanks_postbit
  • (6)post_thanks_postbit_info
  • (6)postbit
  • (6)postbit_onlinestatus
  • (6)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_postinfo_query
  • fetch_postinfo
  • 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
  • fetch_musername
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • post_thanks_function_fetch_thanks_bit_start
  • post_thanks_function_show_thanks_date_start
  • post_thanks_function_show_thanks_date_end
  • post_thanks_function_fetch_thanks_bit_end
  • post_thanks_function_fetch_post_thanks_template_start
  • post_thanks_function_fetch_post_thanks_template_end
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete