MyBB Community Forums

Full Version: little help with banner css in header template
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
hi guys

im hoping i can get some help with something ive been having trouble with i know its an easy fix im just missing something somewhere, bear with me i am also new to this ive managed to figure out most of everything by myself but im a bit stumped on this one lol 

i am using the MyBB default theme and i am looking to place a image banner on the top right of the main page just left of the logo, seemed simple enough and all is well except my image shows as a small pic icon and no actual image, the link works however and my title works too as well the banner is in the area i can see its space for it....just no actual image...

i have figured out what to do but for some reason im having issue with my image path , ive looked to make sure my image is in its  correct place , and i copied and pasted the path from my ftp so i dont think its a spelling thing so im certain i have the css wrong or something worded wrong (?)

right now i want to place a image banner using css in the header template/header , the image banner  that is also a link to a website.

so i entered this css to the header template:

<a style="float: right; width: 400px;height: 60px;" href="http://www.polypzcanada.com/"><img src="/public_html/thereefforum/images/banner for thereefforum1.png" alt="" title="banner"></a>


i know the issue has to be with my image source , any leads to help me out ? 


MyBB 1.8.5

site: thereefforum.com 

test account user : " test account "
user password: " testaccount"


let me know if there's any more info needed, thanks everyone in advanceSmile


denny
thereefforum
If you're trying to get the logo and the banner on the same line, you cannot use CCS.

For example,

<div class="banner" style="float: right; width: 60%">
<a style="float: right; width: 400px;height: 60px;" href="http://www.polypzcanada.com/"><img src="/public_html/thereefforum/images/banner for thereefforum1.png" alt="" title="banner"></a>
</div>

Will display your banner to the right and,

<div class="logo" style="float: left; width: 30%;">
LOGO HERE
</div>

Would display your logo to the left on the same line with a 10% gap.

Regarding the issue however, you cannot have spaces in links. Try rename your file to something like, banner_for_thereefforum1.png

EDIT: Use the {$mybb->settings['bburl']} for links also, for example: put the file in your images folder which the mybb installation made and then do:

<img src="{$mybb->settings['bburl']}/images/banner_for_thereefforum1.png" />
thanks nineteh, issue seems to be the spaces in the file name i switched to an easier name like banner_1 and it loaded , tweaked the size a bit and looks great Smile i knew it was something simple lol

thanks again Smile