VRMLÓëJavascriptºÍVBscript½»»¥µÄʵÀý
ÏÖ½«´úÂëÌù³ö£¬¹²Ã㣡
HTML²¿·Ö£º=====================================================
<html>
<head>
<script language="VBscript">
<!--
function M_b()
set M_e=Scene.Engine
M_e.Nodes("MyScript").Fields("nodestring")="Shape {geometry Box{}}"
M_e.Nodes("MyScript").Fields("kk")=TRUE
end function
function M_s()
set M_e=Scene.Engine
M_e.Nodes("MyScript").Fields("nodestring")="Shape {geometry Extrusion{}}"
M_e.Nodes("MyScript").Fields("kk")=TRUE
end function
!-->
</script>
<script language="javascript">
function bd() {
var oo = Scene.Engine;
oo.Nodes("MyScript").Fields("nodestring")="Shape {geometry Box{}}";
oo.Nodes("MyScript").Fields("kk")=true;
}
function bx(){
var oo = Scene.Engine;
oo.Nodes("MyScript").Fields("nodestring")="Shape {geometry Extrusion{}}";
oo.Nodes("MyScript").Fields("kk")=true;
}
</script>
</head>
<body>
<OBJECT id="Scene"
CLASSID="CLSID:86A88967-7A20-11d2-8EDA-00600818EDB1" WIDTH="300" HEIGHT="300">
<PARAM NAME="Scene" value="box.wrl">
</OBJECT>
<input type=button value="±ä´ó" onClick="bd()">
<input type=button value="±äС" onClick="bx()"><br>
</body>
</html>
box.wrl²¿·Ö===========================================================
#VRML V2.0 utf8
DirectionalLight {
ambientIntensity .5
intensity .2
}
NavigationInfo {
type "EXAMINE"
}
DEF Transfm Transform {
translation -4 0 -4
children [
Shape {
geometry Box{}
}]
}
DEF MyScript Script {
directOutput TRUE
eventIn SFBool kk
field SFNode node USE Transfm
field SFString nodestring ""
url "VRMLSCRIPT:
function kk(){
if(nodestring=='')
{
nodestring='Shape {'
'geomet
Ïà¹ØÎĵµ£º
1. oncontextmenu="window.event.returnValue=false" ½«³¹µ×ÆÁ±ÎÊó±êÓÒ¼ü
<table border oncontextmenu=return(false)><td>no</table> ¿ÉÓÃÓÚTable
2. <body onselectstart="return false"> È¡Ïûѡȡ¡¢·ÀÖ¹¸´ÖÆ
3. onpaste="return false" ²»×¼Õ³Ìù
4. oncopy="return false;" oncut="re ......
ÎÒÃÇÀ´Ä£·ÂÒ»ÏÂ×îOOµÄmootoolsµÄ¼Ì³Ð»úÖÆ¡£ËüµÄÀà¶¼ÓÐÒ»¸ö½Ð×öinitialize¹¹Ôì·½·¨£¬ÕâÓëJavaµÄÀà¶¼ÓÐÒ»¸öÓëÀàÃûͬÃûµÄ¹¹Ôì·½·¨Ò»ÑùµÄµÀÀí¡£Ö»²»¹ý£¬ÕâЩ½Ðinitialize»òinit¶¼ÊÇ½è¼ø×ÔPrototype£¬¶øPrototypeÄǰïÈËÊÇRuby³öÉí¡£ÎªÁËÇø±ðmootoolsÄÇÖÖÎÛȾÔÉú·½·¨µÄ×ö·¨£¬ÎÒ°ÑÀàµÄ¹¹ÔìÆ÷ÃüÃûΪvariant£¬²¢ÇÒ½ûÖ¹²é¿´¹¹Ô ......
PHPµÄJSONÀà¿âÎÒʹÓõÄÊÇServices_JSON
£¬Ã»Ê²Ã´ÌرðµÄÓŵ㣬ҲûʲôÃ÷ÏÔµÄȱµã£¬¶Ô¸¶ÓÃ×ãÒÓ¡£
½¨Á¢Îļþdata.php
£º
<?php
include(
"JSON.php"
);
$data
= array(
array(
'name'
=>
mb_convert_encoding
(
'ÀÏÍõ'
,
'UTF-8'
,
'GBK'
), ......
javascript ֪ʶÕûÀí
1¡¢screen ÆÁÄ»¶ÔÏó
screen ÆÁÄ»¶ÔÏó ·´Ó³Á˵±Ç°Óû§µÄÆÁÄ»ÉèÖá£
width ·µ»ØÆÁÄ»µÄ¿í¶È£¨ÏñËØÊý£©¡£
height ·µ»ØÆÁÄ»µÄ¸ß¶È¡£
availWidth ·µ»ØÆÁÄ»µÄ¿ÉÓÿ ......