aboutsummaryrefslogtreecommitdiff
path: root/files/it/web/css/background-repeat/index.html
blob: b8d0a25fd7d48a0ebece20d9a0a2b5ba99634ccd (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
---
title: background-repeat
slug: Web/CSS/background-repeat
translation_of: Web/CSS/background-repeat
---
<p> </p>

<div id="section_1">
<h3 class="editable" id="Sommario"><span>Sommario</span></h3>

<div class="editIcon"><a href="../../../../en/CSS/background-repeat#" style="" title="Edit section"><span class="icon"><img alt="Edit section" class="sectionedit" src="../../../../skins/common/icons/icon-trans.gif"></span></a></div>

<p><code>background-repeat</code> specifica se e come lo sfondo deve essere ripetuto.</p>

<ul>
 <li><span class="lang lang-en"><a href="../../../../en/CSS/initial_value" rel="internal">Valore iniziale</a> </span>: repeat</li>
 <li>Si applica a: tutti gli elementi</li>
 <li><span class="lang lang-en"><a href="../../../../en/CSS/inheritance" rel="internal">Ereditabile</a> </span>: no</li>
 <li>Percentuali: no</li>
 <li>Media: <span class="lang lang-en"><span class="lang lang-en"><code><a href="../../../../en/CSS/Media/Visual" rel="internal">visual</a></code></span> </span></li>
 <li><span class="lang lang-en"><a href="../../../../en/CSS/computed_value" rel="internal">Valore riconosciuto</a> </span>: come specificato</li>
</ul>
</div>

<div id="section_2">
<h3 class="editable" id="Sintassi"><span>Sintassi</span></h3>

<pre class="eval">background-repeat: repeat | repeat-x | repeat-y | no-repeat | inherit
</pre>
</div>

<div id="section_3">
<h3 class="editable" id="Valori"><span>Valori </span></h3>

<div class="editIcon"><a href="../../../../en/CSS/background-repeat#" style="" title="Edit section"><span class="icon"><img alt="Edit section" class="sectionedit" src="../../../../skins/common/icons/icon-trans.gif"></span></a></div>

<dl>
 <dt>repeat</dt>
 <dd>L'immagine viene ripetuta sia orizzontalmente che verticalmente</dd>
 <dt>repeat-x</dt>
 <dd>L'immagine viene ripetuta solo orizzontalmente</dd>
 <dt>repeat-y</dt>
 <dd>L'immagine viene ripetuta solo verticalmente</dd>
 <dt>no-repeat</dt>
 <dd>L'immagine non viene ripetuta: viene visualizzata una sola volta.</dd>
</dl>

<p> </p>
</div>
<h2 id="Esempi">Esempi</h2>

<h3 id="HTML">HTML</h3>

<pre class="brush: html">&lt;ol&gt;
    &lt;li&gt;no-repeat
        &lt;div class="one"&gt;&amp;nbsp;&lt;/div&gt;
    &lt;/li&gt;
    &lt;li&gt;repeat
        &lt;div class="two"&gt;&amp;nbsp;&lt;/div&gt;
    &lt;/li&gt;
    &lt;li&gt;repeat-x
        &lt;div class="three"&gt;&amp;nbsp;&lt;/div&gt;
    &lt;/li&gt;
    &lt;li&gt;repeat-y
        &lt;div class="four"&gt;&amp;nbsp;&lt;/div&gt;
    &lt;/li&gt;
    &lt;li&gt;repeat-x, repeat-y (multiple images)
        &lt;div class="five"&gt;&amp;nbsp;&lt;/div&gt;
    &lt;/li&gt;
&lt;/ol&gt;</pre>

<h3 id="CSS">CSS</h3>

<pre class="brush: css">/* Shared for all DIVS in example */
li {margin-bottom: 12px;}
div {
    background-image: url(https://mdn.mozillademos.org/files/12005/starsolid.gif);
    width: 144px;
    height: 84px;
}

/* background repeat CSS */
.one {
    background-repeat: no-repeat;
}
.two {
    background-repeat: repeat;
}
.three {
    background-repeat: repeat-x;
}
.four {
    background-repeat: repeat-y;
}

/* Multiple images */
.five {
    background-image:  url(https://mdn.mozillademos.org/files/12005/starsolid.gif),
                       url(https://developer.cdn.mozilla.net/media/redesign/img/favicon32.png);
    background-repeat: repeat-x,
                       repeat-y;
    height: 144px;
}</pre>

<h3 id="Result">Result</h3>

<p>In this example, each list item is matched with a different value of <code>background-repeat</code>.</p>

<p>{{EmbedLiveSample('Esempi', 240, 360)}}</p>
<div id="section_5">
<h3 class="editable" id="Specifiche"><span>Specifiche</span></h3>

<div class="editIcon"><a href="../../../../en/CSS/background-repeat#" style="" title="Edit section"><span class="icon"><img alt="Edit section" class="sectionedit" src="../../../../skins/common/icons/icon-trans.gif"></span></a></div>

<ul>
 <li><a class="external" href="http://www.w3.org/TR/CSS1#background-repeat" rel="external nofollow" title="http://www.w3.org/TR/CSS1#background-repeat">CSS 1</a></li>
 <li><a class="external" href="http://www.w3.org/TR/CSS21/colors.html#propdef-background-repeat" rel="external nofollow" title="http://www.w3.org/TR/CSS21/colors.html#propdef-background-repeat">CSS 2.1</a></li>
 <li><a class="external" href="http://www.w3.org/TR/2005/WD-css3-background-20050216/#background-repeat" rel="external nofollow" title="http://www.w3.org/TR/2005/WD-css3-background-20050216/#background-repeat">CSS 3</a></li>
</ul>
</div>

<div id="section_6">
<h3 class="editable" id="Compatibilità_tra_browser"><span>Compatibilità tra browser</span></h3>


<div class="editIcon"><a href="../../../../en/CSS/background-repeat#" style="" title="Edit section"><span class="icon"><img alt="Edit section" class="sectionedit" src="../../../../skins/common/icons/icon-trans.gif"></span></a></div>

<table class="standard-table">
 <tbody>
  <tr>
   <th>Browser</th>
   <th>
    <p>Versione più vecchia</p>
   </th>
  </tr>
  <tr>
   <td>Internet Explorer</td>
   <td>4</td>
  </tr>
  <tr>
   <td>Firefox</td>
   <td>1</td>
  </tr>
  <tr>
   <td>Netscape</td>
   <td>4</td>
  </tr>
  <tr>
   <td>Opera</td>
   <td>3.5</td>
  </tr>
 </tbody>
</table>
</div>

<div id="section_7">
<h3 class="editable" id="Vedere_anche"><span>Vedere anche</span></h3>


<div class="editIcon"><a href="../../../../en/CSS/background-repeat#" style="" title="Edit section"><span class="icon"><img alt="Edit section" class="sectionedit" src="../../../../skins/common/icons/icon-trans.gif"></span></a></div>

<p><span class="lang lang-en"><span class="lang lang-en"><code><a class="internal" href="/../../it/CSS/background" rel="internal" title="../../it/CSS/background">background</a></code></span> , <span class="lang lang-en"><code><a class="internal" href="/../../it/CSS/background-attachment" rel="internal" title="../../it/CSS/background-attachment">background-attachment</a></code></span> , <span class="lang lang-en"><code><a class="internal" href="/../../it/CSS/background-color" rel="internal" title="../../it/CSS/background-color">background-color</a></code></span> , <span class="lang lang-en"><code><a class="internal" href="/../../it/CSS/background-image" rel="internal" title="../../it/CSS/background-image">background-image</a></code></span> , <span class="lang lang-en"><code><a class="internal" href="/../../it/CSS/background-position" rel="internal" title="../../it/CSS/background-position">background-position</a></code></span> , <span class="lang lang-en"><code><strong>background-repeat</strong></code></span> </span></p>
</div>

<p> </p>