读书人

这样也不行?解决方法

发布时间: 2012-02-15 12:09:44 作者: rapoo

这样也不行?
<html>
<head>
<title> test </title>
<script type= "text/javascript ">
function sayhello()
{
alert ( "say fuck ");
}
</script>
</head>
<body>
<script type= "text/javascript ">
sayhell();
</script>
</body>
</html>

我在head里定义sayhello函数,然后在body里将其执行,这样也不行?一定要
<script type= "text/javascript ">
function sayhello()
{alert( "you ");
}
sayhello();
</script>
这样写在一起才行?

[解决办法]
<script type= "text/javascript ">
sayhell();
</script>
???
sayhello()你少了个o....

读书人网 >JavaScript

热点推荐