殷浩
2017-07-28 18:05
<!DOCTYPE HTML>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>string对象</title>
<script type="text/javascript">
var mystr="Hello World!"
document.write(mystr.substring(mychar.indexOf("W"),mystr.length)+ "<br />");
document.write(mystr.substring(0,mychar.indexOf(" ")) );
</script>
</head>
<body>
</body>
</html>
已解决,字符打错了
JavaScript进阶篇
468061 学习 · 21891 问题
相似问题