summaryrefslogtreecommitdiffstats
path: root/layout/reftests/forms/placeholder/placeholder-focus-pref.html
blob: cdfd92444c4c452d19750df819562c9c7ac37fc6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
<!DOCTYPE html>
<html class="reftest-wait">
  <link rel='stylesheet' type='text/css' href='placeholder-style.css'>
  <!-- Test: when focused, element should not placeholder when
       'dom.placeholder.show_on_focus' pref is false. -->
  <script type="text/javascript">
    function focusPlaceholder()
    {
      document.getElementById('p1').focus();
    }
    function disableReftestWait()
    {
      document.documentElement.className = '';
    }
  </script>

  <body onload="focusPlaceholder();">
    <input type="text" id="p1" value="" placeholder="my placeholder" onfocus="disableReftestWait();">
  </body>
</html>