CSS et JavaScript sont deux éléments indispensables pour tout site Web, aussi pour tous les concepteurs Web et les développeurs web. Trucs et astuces pour résoudre les CSS, JavaScript problèmes rapidement. ici.
- Demo
- Agrandir
- Recharger
- New window
G�n�rez vos vid�os d'entreprise par l'IA avec la voix ou simplement du texte
Votre premi�re application vid�o AI GRATUITE ! Automatisez votre premi�re vid�o AI. Cr�ez votre vid�o professionnelle en 5 minutes gr�ce � l'IA. Aucun �quipement ni comp�tence en montage vid�o requis. Production vid�o sans effort pour les sp�cialistes du marketing de contenu.
CSS Lists
Create a Microsoft Word-Style Outline with CSS
As
you can see, the browser doesn't bother to vary the indentation style
much, or change the list type from roman numerals to alphabetical
characters and so on... all the things we're so used to seeing because
Microsoft Word and other writing programs do them by default. So let's
use a bit of CSS ingenuity to make a Microsoft Word-styled outline
using ordered lists!
Pure CSS Timeline
"I
wanted to build a CSS timeline for the "About" section of my site while
using some clean and simple markup. I wanted to avoid using images as
much as possible, so I spent a few minutes prototyping some options and
came up with a solution using unordered lists. The result is a simple
and clean looking timeline with some very straight forward markup. In
this article I'll share my approach to creating a timeline out of CSS
and HTML which results in a nice looking, simple timeline."
Automatic numbering with CSS Counters
When
writing documents, it is often useful to number sections and have a
table of contents. You can number these by hand, directly in the
markup, but this can be time consuming if the order changes and you
have to edit all the numbers. CSS2.1 gives us a automated way to
generate numbers using CSS counters, and this article will walk you
through how to use them. One word of note before we start is that CSS
counters are not yet implemented in IE, although they are on the
roadmap for IE8.
Elastic Calendar Styling with CSS
A
traditional calendar is a grid of numbered boxes on a page. As a web
designer, you might go right for a table, and I wouldn't fault you for
that. Tables, though, can sometimes be tough to muscle into shape. The
CSS purist in me gets pissed when I set the width of a table (or a
cell) and it decides it knows better and grows or shrinks as it sees
fit.
You can tackle calendar styling with pure CSS, and I feel it
makes just as much sense semantically as a table does. What is a
calender, if not an ordered list of days? By using CSS, we can even do
some cool things like do all our sizing with ems so our calendar layout
will be elastic. That is, grow in both width and height when text is
resized in browsers, while greatly increasing accessibility.
Style a List with One Pixel
A
one-pixel background image can be a pretty versatile thing. With
repeat-x it can be a horizontal line, repeat-y makes a vertical line,
and repeat makes it a fill color. Just as a little fun proof of
concept, we can use that to create a depth-chart looking unordered list.
Style Your Ordered List
By
default, most browsers display the ordered list numbers same font style
as the body text. Here is a quick CSS tutorial on how you can use the
ordered list (ol) and paragraph (p) element to design a stylish
numbered list.
Simulating a Table Using an Unordered List
Your
first question immediately might be, "why would I want to simulate a
table with a list, why not just use a table?" With the raise in
popularity of AJAX sortable list elements, using list items to
represent a multiple column data table can allow for easy sorting of
various more "tabley" information. So let's get started.
8 different ways to beautifully style your HTML lists with CSS
"The
use of HTML lists (<ol> for an ordered list, <ul> for an
unordered list) is very common these days. Today, we're going to look a
little bit further than creating regular lists, by showing 8 different
ways to beautifully style your HTML lists with CSS. We'll use some pure
CSS techniques to make a bored list look awesome (and even have some
extra functionality)."
Quick Tip - Simplify List Margins with CSS
Have
you ever set default margins for a layout, and then had to go back and
manually adjust all of your lists? By default, list item markers have a
negative positioning in relationship to the list item itself. This
means that zero-ing out margins automatically leads to an overflow if
the list is contained inside anything else. Wouldn't it be easier to
put the list item marker at the same starting point as other elements
instead? Lucky for us, there's a style to help do just that. Let's see
what can be done with the list-style-position
property.
Sexy HTML List Tricks
Behold
the ubiquitous list elements, <ul> and <ol>. These two sexy
elements help millions of websites display lists of information in
clean, semantic fashion. Without them, we'd be crawling around like
filthy cavemen, eating dirt and howling at the moon. But these list
elements aren't just sexy, they are also extremely flexible, enabling
us humble designers to create robust list configurations that are
semantically versatile and highly customizable.
Clickable <li>
I
originally coded the markup to be a table, but discovered a problem
when I tried to make the whole row clickable. I ended up with a list of
articles instead.
- Sent (0)
- Nouveau