Results 1 to 1 of 1

Thread: [VB4]: How to create custom styled notifications

  1. #1
    Experienced vBulletin User
    Join Date
    Aug 2006
    Location
    Va
    Posts
    115

    [VB4]: How to create custom styled notifications

    With vB4 and it's new CSS driven layout system it's super easy to highly customize the same aspects of the site in different ways. For this tutorial I'm showing you how to use vBulletin 4 CSS on the notifications to give a different and unique look to each notification by only adding CSS and no template changes.

    When a new notification is created it is given an ID number(1), when another new one is created it's increased by one and given another new ID number (2). In a stroke of genius (either intentional or not) the vBulletin style team gave the notifications a ID tag that will allow overriding of the standard styling because of the way CSS works, an ID will override a class.

    For my example I'm using the standard Guest Notice with the ID of 1. Just add the following lines to your vbulletin-chrome.css file (A better way is to use Lynnes Additional CSS Mod).

    Code:
    #notifications a:link { color: black; }
    #nonotifications a { color: black; }
    
    #navbar_notice_1 {
    border: 1px solid;
    margin: 10px 0px;
    padding:15px 10px 15px 75px;
    background-repeat: no-repeat;
    background-position: 10px center;
    }
    
    #navbar_notice_1 {
    color: #9F6000;
    background-color: #FEEFB3;
    background-image: url('images/misc/info.png');
    
    }
    Then upload the attached attention.png file to 'images/misc/'

    The end result is a new and better looking notification that makes for a good "Warning" rather than the default one. You can find tons of free icons all over the web that will be suitable replacements for these ones. The ones I used you can find for free at http://www.jankoatwarpspeed.com/file...atus_icons.zip

    You can get more vBulletin 4 Optimization & Customization tips at my blog: David McHenry vBulletin 4 Optimize

    Full notification CSS code used:
    Code:
    #navbar_notice_1 {
    border: 1px solid;
    margin: 10px 0px;
    padding:15px 10px 15px 75px;
    background-repeat: no-repeat;
    background-position: 10px center;
    }
    
    #navbar_notice_1 {
    color: #9F6000;
    background-color: #FEEFB3;
    background-image: url('images/misc/info.png');
    }
    
    
    #navbar_notice_3 {
    border: 1px solid;
    margin: 10px 0px;
    padding:15px 10px 15px 75px;
    background-repeat: no-repeat;
    background-position: 10px center;
    }
    
    #navbar_notice_3 {
    color: #4F8A10;
    background-color: #DFF2BF;
    background-image: url('images/misc/good.png');
    
    }
    
    #navbar_notice_4 {
    border: 1px solid;
    margin: 10px 0px;
    padding:15px 10px 15px 75px;
    background-repeat: no-repeat;
    background-position: 10px center;
    }
    
    #navbar_notice_4 {
    color: #00529B;
    background-color: #BDE5F8;
    background-image: url('images/misc/help.png');
    }
    
    #navbar_notice_5 {
    border: 1px solid;
    margin: 10px 0px;
    padding:15px 10px 15px 75px;
    background-repeat: no-repeat;
    background-position: 10px center;
    }
    
    #navbar_notice_5 {
    color: #D8000C;
    background-color: #FFBABA;
    background-image: url('images/misc/error.png');
    }
    Attached Images Attached Images  

Similar Threads

  1. Replies: 9
    Last Post: 09-19-2010, 06:20 PM
  2. Shiny Beige - a professional-styled theme with a splash of red
    By Peggy in forum vBulletin Skins & Styles - 3.8
    Replies: 5
    Last Post: 02-07-2009, 09:04 PM
  3. Help Create a Custom Profile Field and Add It To Your Postbit
    By ellyssian in forum vBulletin Discussion and Questions
    Replies: 1
    Last Post: 11-17-2008, 01:16 PM
  4. Email Notifications
    By laura66a in forum vBulletin Discussion and Questions
    Replies: 8
    Last Post: 11-13-2006, 12:20 AM
  5. Email notifications
    By minstrel in forum General Internet Discussions
    Replies: 11
    Last Post: 08-24-2006, 06:55 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •