MyBB Community Forums

Full Version: How do I add rounded corners?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
I agree with Labrocca. Wink

The .css and html code by itself would be useless... It needs to "worked" into the existing html of what you are trying to add it to; and there are possibly many ways of doing that to different locations.. But NONE are just straight forward Slap-Bang add the code supplied.

Best you download that theme and at least have a look at the .xml file to gauge some idea of what you are trying to do.

Or install another MyBB-Worksite and play with the theme there; if you are so reluctant to upload it to your existing MyBB forum. Smile
labrocca Wrote:lol...just give the code? It's not that simple. You can use techforum.us as an example of HOW it's done.

Don't advertise your site in here, there is a forum for that, and why refer him to a forum with a single post? How will he learn?
xScopex Wrote:Can anyone just give the code??? please because I want this too but I'm not changing the theme....

This is the html for adding the top graphics in a straight line. It doesn't suit every location. Sad
And as you can see by the strings, there are three graphics: left, center and right.

You should be able to use this to add the left-round-corner, the center which is usually only about 10px wide and the right-round-corner. You may also need to play with the width and height to get it to position YOUR graphics properly.


<table width="100%" align="center" border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="40" align="right" valign="bottom"><img src="{$theme['imgdir']}/topb_left.gif" width="40" 
height="31" border="0" alt="" /></td>
<td width="100%" align="center" valign="middle" background="{$theme['imgdir']}/topb_center.gif">
</td>
<td width="40" align="left" valign="bottom"><img src="{$theme['imgdir']}/topb_right.gif" width="40" 
height="31" border="0" alt="" /></td>
</tr>
</table>


Here is another format that uses the .css to in-line the graphics, and uses a 1px transparent spacer to populate the class= function:

You would use this to add (re-named) upside-down round corners, center etc, to the bottom of wherever you want to place it; using the transparent 1px spacer as a virtual anchor... Wink

<table border="0" cellpadding="0" cellspacing="0" class="tbl"><tr><td class="tbll"><img src="{$theme['imgdir']}/spacer.gif" alt="" width="40" height="26" /></td><td class="tblbot"><img src="{$theme['imgdir']}/spacer.gif" alt="" width="8" height="26" /></td><td class="tblr"><img src="{$theme['imgdir']}/spacer.gif" alt="" width="40" height="26" /></td></tr></table>


And here is the .css for it:

/* Background images for tables */
.tbl{border-collapse:collapse; height:4px; width:100%;}
.tbll{background: url(templates/A_Char_Brown/images/tb4_l.gif) no-repeat;width:40px}
.tblbot{background: url(templates/A_Char_Brown/images/tb4_m.gif) repeat-x;width:100%}
.tblr{background: url(templates/A_Char_Brown/images/tb4_r.gif) no-repeat;width:40px}

I also don't want to go on with this tutorial here..... There are other places that specialise in theming MyBB Wink

There's Labrocca's site if you want to go there, MyBBThemes and aus-themes... And I'm sure there are others that I don't know about.. Sad

You need to pick the one that has the time to answer your questions.

Catcha! Have fun playing with the above... Toungue
dudeness3 Wrote:
labrocca Wrote:lol...just give the code?  It's not that simple. You can use techforum.us as an example of HOW it's done.

Don't advertise your site in here, there is a forum for that, and why refer him to a forum with a single post? How will he learn?

I guess you don't understand what an EXAMPLE is. Techforum wasn't being "advertised"...and it doesn't matter how many posts are there for a template example. techforum is mainly setup at this point as an example of my template not to gain members.
It would be much simpler to download my theme or Labrocca's, and edit them with your own images.
However, I've written a tutorial on how I did my rounded corners. You may find it here --> http://mybbthemes.8ez.com/showthread.php?tid=232

Hope it helps! Smile
Pages: 1 2