JavaScript fixed() 方法
定義和用法
fixed() 方法用于把字符串顯示為打字機(jī)字體。
語法
stringObject.fixed()
實(shí)例
在本例中,"Hello world!" 將被顯示為打字機(jī)文本:
<script type="text/javascript"> var str="Hello world!" document.write(str.fixed()) </script>
TIY
- fixed()
- 如何使用 fixed() 把字符串顯示為打字機(jī)字體。