diff options
Diffstat (limited to 'files/fi/web/api/navigator/cookieenabled/index.html')
| -rw-r--r-- | files/fi/web/api/navigator/cookieenabled/index.html | 99 |
1 files changed, 99 insertions, 0 deletions
diff --git a/files/fi/web/api/navigator/cookieenabled/index.html b/files/fi/web/api/navigator/cookieenabled/index.html new file mode 100644 index 0000000000..46a49e6eae --- /dev/null +++ b/files/fi/web/api/navigator/cookieenabled/index.html @@ -0,0 +1,99 @@ +--- +title: Navigator.cookieEnabled +slug: DOM/window.navigator.cookieEnabled +tags: + - API + - DOM + - Ominaisuus +translation_of: Web/API/Navigator/cookieEnabled +--- +<p>{{ ApiRef("HTML DOM") }}</p> + +<p>Palauttaa totuusarvon, joka osoittaa, ovatko evästeet käytössä vai eivät.</p> + +<h2 id="Syntaksi">Syntaksi</h2> + +<pre class="eval">var cookieEnabled = navigator.cookieEnabled; +</pre> + +<ul> + <li><code>cookieEnabled</code> on totuusarvo, <code>true</code> tai <code>false</code>.</li> +</ul> + +<h2 id="Esimerkki">Esimerkki</h2> + +<pre class="brush: js">if (!navigator.cookieEnabled) { + // kerrotaan käyttäjälle, että evästeiden käyttöönotto tekee sivusta paljon hyödyllisemmän +} +</pre> + +<h2 id="Määrittelyt">Määrittelyt</h2> + +<table class="standard-table"> + <thead> + <tr> + <th scope="col">Määrittely</th> + <th scope="col">Tila</th> + <th scope="col">Kommentti</th> + </tr> + </thead> + <tbody> + <tr> + <td>{{SpecName("HTML WHATWG", "webappapis.html#dom-navigator-cookieenabled", "Navigator.cookieEnabled")}}</td> + <td>{{Spec2("HTML WHATWG")}}</td> + <td>Alkuperäinen määrittely</td> + </tr> + </tbody> +</table> + +<h2 id="Selainyhteensopivuus">Selainyhteensopivuus</h2> + +<p>{{ CompatibilityTable() }}</p> + +<div id="compat-desktop"> +<table class="compat-table"> + <tbody> + <tr> + <th>Ominaisuus</th> + <th>Chrome</th> + <th>Firefox (Gecko)</th> + <th>Internet Explorer</th> + <th>Opera</th> + <th>Safari</th> + </tr> + <tr> + <td>Perustuki</td> + <td>{{ CompatVersionUnknown() }}</td> + <td>{{ CompatGeckoDesktop(1.0) }}</td> + <td>{{ CompatVersionUnknown() }}<sup>[1]</sup></td> + <td>{{ CompatVersionUnknown() }}</td> + <td>{{ CompatVersionUnknown() }}</td> + </tr> + </tbody> +</table> +</div> + +<div id="compat-mobile"> +<table class="compat-table"> + <tbody> + <tr> + <th>Ominaisuus</th> + <th>Android</th> + <th>Firefox Mobile (Gecko)</th> + <th>IE Mobile</th> + <th>Opera Mobile</th> + <th>Safari Mobile</th> + </tr> + <tr> + <td>Perustuki</td> + <td>{{ CompatUnknown() }}</td> + <td>{{ CompatGeckoMobile(1.0) }}<sup>[1]</sup></td> + <td>{{ CompatUnknown() }}</td> + <td>{{ CompatUnknown() }}</td> + <td>{{ CompatUnknown() }}</td> + </tr> + </tbody> +</table> +</div> + +<p>[1] Ennen Gecko 8.0:aa {{ geckoRelease("8.0") }}, <code>window.navigator.cookieEnabled</code> ilmoittaa väärän tuloksen, jos sivulle, jolle tarkistus suoritetaan, on asetettu sivustopoikkeus. Tämä on korjattu.</p> |
