MyBB Community Forums

Full Version: CSS?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
(2013-07-25, 11:37 PM)Jambuster Wrote: [ -> ]Your button is something like this isnt it ?

<a href="link here">Alerts</a>

Im assuming the "0" is the amount of alerts you have ? Therefore it must be a variable in your template.

Do this in your template:

<a href="link here">Alerts {$alerts variable here}</a>

I dont know the exact variable name but replace "{$alerts variable here}" with the variable that is displaying the "0"


Looks like this..

<span class="myalerts_popup_wrapper{$newAlertsIndicator}">
	<a href="{$mybb->settings['bburl']}/usercp.php?action=alerts" class="unreadAlerts myalerts_popup_hook" id="unreadAlerts_menu"><img src="images/glowing/menubuttons/alerts.png" alt=""> {$mybb->user['unreadAlerts']}</a>
	<div id="unreadAlerts_menu_popup" class="myalerts_popup" style="display:none;">
		<div class="popupTitle">{$lang->myalerts_page_title}</div>
		<ol>
		{$alerts}
		</ol>
		<div class="popupFooter"><a href="usercp.php?action=alerts">{$lang->myalerts_usercp_nav_alerts}</a></div>
	</div>
</span>

Sorry it's almost 1am here, I'm tired.
Oh its an image. Thats a different issue. Your going to have to add a class to {$mybb->user['unreadAlerts']}

Something like this:

<span class="unreadalerts">{$mybb->user['unreadAlerts']}</span>


Set the position to absolute and adjust the margins to position it. I cant do it without access to the templates so you'll just need to play with it. This will get you started.

Provided you added the "span" tags around the variable, add the following css:

Quote:.unreadalerts {
position: absolute;
margin-top: -10px
margin-left: -20px
z-index: 999;
}
.unreadalerts a {
color: #ffffff;
}

Ive no idea what the "margins" will be in terms of position, but that will give you a general idea, play around with the margins.
Pages: 1 2