```rust use wild_doc::*;
let dir="./wd-test/"; if std::path::Path::new(dir).exists(){ std::fs::removedirall(dir).unwrap(); } std::fs::createdirall(dir).unwrap();
let mut wd=WildDoc::new( dir ,IncludeLocal::new("./include/") ).unwrap();
//update data.
/wd.run(br#"
let updatexml=br#"
//select data.
let r=wd.run(br#"
//seaech data
let r=wd.run(br#"
//use javascript
let r=wd.run(br#"
options['test']="OK";
?>
//search in update section.
wd.run(br#"
//use WebAPI let r=wd.run(br#"
wd.general.a="OK";
wd.stack.push({
hoge:{
hoge:"A"
}
,a:1
});
console.log(crypto.randomUUID());
wd.result_options.test="TEST";
wd.result_options.test2=crypto.randomUUID();
?>
a:<wd:print wd:value="wd.general.a" />
v:<wd:print wd:value="wd.v('a')" />
input:<wd:print wd:value="wd.input.name" />
<?typescript
wd.stack.pop();
wd.general.a="OK2";
wd.general.b=1>2;
?>
a:<wd:print wd:value="wd.general.a" />
v:<wd:print wd:value="wd.general.b" />
"#,br#"{ "name":"Ken" ,"from":"US" }"#).unwrap(); println!("{} : {}",std::str::fromutf8(r.body()).unwrap(),r.optionsjson()); ```
xml
<html>
<head>
<title>HTML include test</title>
</head>
<body>
<wd:include wd:src="wd.v('body_path')" />
</body>
</html>
xml
BODY
rust
let r=wd.run(br#"<wd:stack var="body_path:'body.xml'">
<wd:include src="layout.xml" />
<wd:stack>"#,b"");
println!("{}",r);
html
<html>
<head>
<title>HTML include test</title>
</head>
<body>
BODY
</body>
</html>