css question for vbulletin forum - html

I'm trying to move the "likes" gray bar right above the signature, to the left of the "like" link found on top right w/ tiny icon.
Example:
http://www.talkjesus.com/bible-study-hall/44722-antimonianism.html#post220422
The css code now
.vbseo_buttons .vbseo_liked {
background: rgba(46, 53, 57, .8);
color: #fff;
border: 0;
-moz-border-radius: 3px;
-webkit-border-radius: 3px;
border-radius: 3px;
clear: both;
display: block;
padding: 12px;
margin: 5px 30px;
<vb:if condition="$stylevar['textdirection'] == 'rtl'">
background-position: right;
</vb:if>
}
If I change display: block to display: inline, it'll move it to the same row, like this:
http://i49.tinypic.com/348lonc.png
However, it loses the margin property and width property. I tried fixing the width by adding width: 50%; but that changed nothing. How can I keep it inline while fixing margin and width?

Do you mean your want the gray bar at the far top right where it shows the quantity of likes the thread has with the heart? To keep the margin you should just float the gray box
Floated left
.vbseo_buttons .vbseo_liked {
background: rgba(46,53,57,.8);
color: #fff;
border: 0;
-moz-border-radius: 3px;
-webkit-border-radius: 3px;
border-radius: 3px;
clear: both;
padding: 12px;
margin: 5px 30px;
float: left;
}
To move this all the way to the top right you would need to modify the template and it would end up looking something like this but you need to move the entire after_content div or restyle it as needed if only moving the vbseo_liked container. And also remove the clear:both style.

Related

contents of cell overflowing with margin, padding and border

I think the main problem is that I'm confused about the padding, border and margin interactions.
I have read about each of these style attributes on their own but I'm having trouble combining all of them successfully inside of a table.
For one, I'm setting attributes on the contents in the cell, and then on the cell themselves. I'm not sure when to do which.
For two, I can use percent or pixels. For my needs I think percent would work well, since the text in the orange box is going to be of variable lengths (as will the header text).
Now, the part of the code that I can't get to work correctly is that the display: inline-block element (including padding, border, and margin) overflows the cell. Obviously I want the first header to be centered over the contents below, and I want each of the orange buttons to be visually centered with a small margin between them and the cells to the right.
I see there's a box-sizing style solution, but I need this to be compatible with IE6.
http://codepen.io/kokeefe/pen/dMmPMp
a.TableButtonStyle:link {
display: inline-block;
border-style: solid;
border-width: 3px;
border-color:rgb(240,80,40);
border-radius: 10px;
vertical-align: middle;
margin-top: 5px;
margin-bottom: 5px;
margin-left: auto;
margin-right: auto;
color: white;
text-decoration:none;
background-color: rgb(240,80,40);
font-weight: bold;
width: 100%;
padding: 5%;
font-size:14pt;
}
a.TableButtonStyle:hover {
background-color: white;
color: rgb(240,80,40);
}
a.TableButtonStyle:active {
background-color: rgb(213, 57, 15);
color: white;
border-style: solid;
border-width: 3px;
border-color: rgb(213, 57, 15);
}
a.TableButtonStyle:visited {
background-color: rgb(213, 57, 15);
color: white;
border-style: solid;
border-width: 3px;
border-color: rgb(213, 57, 15);
}
.FontFormat{
text-align:center;
vertical-align:middle;
font-size: 13pt;
margin: 5px;
}
.Bold
{
font-weight: bold;
}
Updated CodePen
What you need is:
box-sizing: border-box;
Apply this to a.TableButtonStyle.
Quoting from MDN docs:
border-box:
The width and height properties include the padding and border, but not the margin. This is the box model used by Internet Explorer when the document is in Quirks mode. Note that padding and border will be inside of the box e.g. .box {width: 350px; border: 10px solid black;} leads to a box rendered in the browser of width: 350px. The content box can't be negative and is floored to 0, making it impossible to use border-box to make the element disappear.
CSS box-sizing property MDN docs

Chrome Border-radius Scaling?

Never come across this issue before, and I cant see any other references to it. Basically, I have a website with rounded corners on the top and bottom containers. Now, these were working perfectly but have suddenly stopped since I started having issues with IMG DECODING FAILED. I've since resolved these (I think) but now, my rounded corners aren't working properly on the bottom of the container.
My CSS is as follows:
.sub_footer {
background: url(/uploads/images/blue_footer_bg.jpg)repeat-x;
color: #fff;
border-bottom-left-radius: 15px;
border-bottom-right-radius: 15px;
text-shadow: 0px 1px 10px rgba(1, 1, 1, 1);
overflow: hidden;
}
I've used the css to make the rounded corner rather than images as I feel its a more dynamic technique.
This css is identical to the top container (except its top right and top left corners that are being rounded).
You can view the website here if you want to see it in action: http://1074796728.1071867011.temp.prositehosting.co.uk/ (this site wont let me post images)
The bottom corners are slightly rounded but to a different degree than the top, eventhough both declarations are for 15px.
Can someone help?
Hi now remove padded class you define in your sub_footer child and now
define your .sub_footer height: 30px; padding-top: 15px;
as like this
.sub_footer
{height: 30px;
padding-top: 15px;
}
Than Result is this
There is nothing wrong with the CSS You shold change the height of the Footer Div See
Thanks
Udit Bhardwaj
Try changing this one:
.sub_footer {
background: url(/uploads/images/blue_footer_bg.jpg)repeat-x;
color: #fff;
border-bottom-left-radius: 15px;
border-bottom-right-radius: 15px;
text-shadow: 0px 1px 10px rgba(1, 1, 1, 1);
overflow: hidden;
}
To this one:
.sub_footer {
background: url(/uploads/images/blue_footer_bg.jpg)repeat;
color: #fff;
border-bottom-left-radius: 15px;
border-bottom-right-radius: 15px;
text-shadow: 0px 1px 10px rgba(1, 1, 1, 1);
overflow: hidden;
}
Simpler solution is to
Just add padding:15px; to class col12 under sub_footer class
.sub_footer .col12{
padding:15px;
}
put webkit's on your border radius statements.
-webkit-border-radius:
-moz-border-radius:

How to make the popup window overlay the article

I'm having trouble figure out about this Facebook Like button when I press like it suppose to popup overlay the article but mine it just goes behind the text and the user can't press or do anything at all
Unlike the other website which I found to give an example from Theverge
their popup overlay the article and there won't be any problem to continue to send to facebook wall
This is the CSS for the share button that I have right now
/* Share */
.share-post {
clear: both;
margin: 10px -20px -20px;
padding: 10px 0 10px 10px;
background: #F7F7F7;
border-top: 1px solid #EAEAEA;
height: 20px;
}
.mini-share-post {
clear: both;
margin: 10px -20px -20px;
padding: 10px 10px 10px 25px;
height: 20px;
}
.recent-box .mini-share-post {
margin-bottom: -5px;
}
.share-post li, .mini-share-post li {
float: left;
width: 120px;
}
.share-post span.share-text {
background: #FF8500;
margin: -10px 10px -10px -10px;
display: block;
float: left;
color: #FFF;
padding: 9px;
font-family: BebasNeueRegular, arial, Georgia, serif;
font-size: 14pt;
}
Check z-index of the div (or something else, depends on what you use) that your posts are wrapped in and set a higher one for the Facebook widget.
Usually setting z-index: 1001; works for me in such situations, but such a high value is considered as rather dirty fix.
EDIT
Okay, I know what is wrong now (I assume it's the site from your profile).
There is a span inside a div with class fb-like fb_edge_widget_with_comment fb_iframe_widget. Change the span width to about 500px.
So you don't have to change the z-index, but next time, please provide some code. Not everthing can be guessed from images.

Border radius not showing

http://thc-cup.ucoz.com/forum/2-1-1
After you can see, the left has a radius at content background and border, but the left one does not! I managed to get it like the one in the left after adding to the div style: display:inline-block; but that messes the box and moves it under the left block.
Since this is a forum (my link) I can't edit html, but I can edit the CSS of the forum.
Here is the style of those blocks:
.postTdInfo { //Left block
display: inline-block;
margin: 0px 0px 0px 35px;
padding: 1px;
border: 1px solid #cfcfcf;
background: #e0e0e0;
border-radius: 5px;
}
.posttdMessage { //Right block
margin: 0px 0px 0px 0px;
padding: 25px;
border: 1px solid #cfcfcf;
background: #e0e0e0;
border-radius: 25px;
I searched all the day for a solution but can't seem to find one.
Is there any way of changing CSS so that the block accepts border radius?
Edit: my first answer didn't solve the problem.
The problem is that you're working on a td element, which has the display property by default set to table. Either add display: block; to .posttdMessage, or, if this causes problems, add another <div> element directly inside the table cell and style that with rounded borders instead.

CSS Inputfield & -button position for questionsystem

I have a problem positioning an inputfield with variable size and a post button with fixed size inside of a div with fixed "outer-margin".
I've provided a jfiddle example where you can see the wrong version.
Here you can see my problem:
Wrong version: Actual website
"Should-be" version: This is what it should look like
Textual description:
As you can see in the 2nd picture, it's important for me that the bottom-part always sits on the bottom...
.submitform {
display: block;
position: fixed;
bottom: 0;
...more on jfiddle...
}
... and the post-button always on the right. The bottom-part should have the same gap on the left and right as the upper-part. The difficult thing is, that the inputfield should have flexible size but should take all the space between left gap and post-button.
I hope you can help me because hours of trying and searching on the web didn't brought me the right solution.
Try this: http://jsfiddle.net/jgHAA/1/
.submitform {
background: white;
display: block;
position: fixed;
/* Instead of applying margin and width, simply set the bottom, left,
and right properties to 13px */
bottom: 13px;
left: 13px;
right: 13px;
/*box-shadow: 0 2px 7px rgba(0, 0, 0, 0.1);*/
box-shadow: 0 1px 4px rgba(0, 0, 0, 0.3);
padding: 7px;
overflow:hidden;
box-sizing:border-box;
}
to have the textbox fill the width, you can use the same technique: http://jsfiddle.net/jgHAA/2/
.submitform #post_input {
display: block;
font-size: 18px;
border: none;
outline: none;
padding: 3px;
/* set left and right, and z-index to make it appear behind the button.*/
left:7px;
right:7px;
position:absolute;
z-index:-1;
}