Home arrow Style Sheets arrow Page 2 - Using BlueTrip`s Success, Notice and Error CSS Classes
STYLE SHEETS

Using BlueTrip`s Success, Notice and Error CSS Classes


Welcome to the final installment of a series on the BlueTrip CSS framework. Made up of seven comprehensive tutorials, this series shows you how to master the main CSS classes that come bundled with BlueTrip through a decent variety of code samples.

Author Info:
By: Alejandro Gervasio
Rating: 3 stars3 stars3 stars3 stars3 stars / 4
November 19, 2009
TABLE OF CONTENTS:
  1. · Using BlueTrip`s Success, Notice and Error CSS Classes
  2. · Displaying successful messages with BlueTrip
  3. · Showing notices and warnings with BlueTrip
  4. · Displaying errors

print this article
SEARCH DEVARTICLES

TOOLS YOU CAN USE

advertisement
Using BlueTrip`s Success, Notice and Error CSS Classes - Displaying successful messages with BlueTrip
(Page 2 of 4 )

As I expressed in the beginning, BlueTrip provides three predefined CSS classes that can be utilized for displaying errors, notices and successful messages with ease. First, I'm going to create a simple example that will demonstrate how to work with the "success" CSS class. In this particular case, the class will be assigned to a paragraph; the code sample that does that is the following:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">

<head>

<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />

<title>Basic example on using BlueTrip (using success class)</title>

<link rel="stylesheet" href="css/screen.css" type="text/css" media="screen, projection">

<link rel="stylesheet" href="css/print.css" type="text/css" media="print">

<!--[if IE]>

<link rel="stylesheet" href="css/ie.css" type="text/css" media="screen, projection">

<![endif]-->

</head>

<body>

<div class="container">

<div class="span-24">

<h1 class="caps">BlueTrip CSS Grid example using success class</h1>

</div>

<div class="span-8">

<h2 class="caps">Level 2 heading</h2>

<h3 class="caps">Level 3 heading</h3>

<p class="success">Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.</p>

</div>

<div class="span-8">

<h2 class="caps">Level 2 heading</h2>

<h3 class="caps">Level 3 heading</h3>

<p class="success">Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.</p>

</div>

<div class="span-8 last">

<h2 class="caps">Level 2 heading</h2>

<h3 class="caps">Level 3 heading</h3>

<p class="success">Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.</p>

</div>

<div class="span-16">

<h2 class="caps">Level 2 heading</h2>

<h3 class="caps">Level 3 heading</h3>

<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.</p>

</div>

<div class="span-8 last">

<h2 class="caps">Level 2 heading</h2>

<h3 class="caps">Level 3 heading</h3>

<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.</p>

</div>

</div>

</body>

</html>

As seen in the above example, the "success" CSS class has been assigned to some paragraphs, which admittedly is nothing spectacular. Nevertheless, if you take a look at the following image, you'll get a better idea of how this class can be used for displaying all sorts of confirmation messages:

As you can see, the "success" CSS class assigns a soft green background color to the selected paragraphs, thus indicating to users that any action taken by them has been accomplished successfully. Most likely you'll want to use other styles to display this kind of message to your visitors, but the default "success " CSS class might be worth a look.

Now that you hopefully learned how to work with this handy BlueTrip's CSS class, it's time to take a close look at another one, intended to be used for displaying notices and warnings in general. This class is called, not surprisingly, "notice," and it'll be analyzed in detail in the following section.


blog comments powered by Disqus
STYLE SHEETS ARTICLES

- CSS Combinators: Working with Child Combinat...
- CSS Combinators: Using General Siblings
- Intro to CSS Combinators
- CSS Semicircles and Web Page Headers
- Drawing Circular Shapes with CSS3 and Border...
- More CSS Pagination Link Templates
- CSS Pagination Links
- Animated CSS3 Image Gallery: Advanced Transi...
- CSS3 Animated Image Gallery: Transitions
- CSS3 Properties: Fixed Heights with box-sizi...
- CSS3 Properties: Altering Strokes and 3D Eff...
- CSS3 Properties: Text-Stroke
- CSS3 Transitions: Width and Height Properties
- Creating a Drop Down Menu in CSS3
- Intro to CSS Transitions

Dev Articles Forums 
 RSS  Articles
 RSS  Forums
 RSS  All Feeds
Weekly Newsletter
 
Developer Updates  
Free Website Content 
Contact Us 
Site Map 
Privacy Policy 
Support 



© 2003-2012 by Developer Shed. All rights reserved. DS Cluster 5 - Follow our Sitemap
Popular Web Development Topics
All Web Development Tutorials