Jan 20th, 2005, 20:59 | #1 |
刁游民
注册日期: Jul 2004
帖子: 636
精华:2
|
请教Java, JS, HTML 高手
可以在 HTML / Java Script / Java code 里 embed an OS kernel call 吗?例如,settup box 运行 linux, 它有browser, 能否在这 settop box 里的 HTML/JS/Java page里包含 a kernel call function, 或PERL Script, shell script? 谢谢高手!
|
|
Jan 21st, 2005, 00:18 | 只看该作者 #3 |
Senior Member
注册日期: Jul 2004
帖子: 545
积分:1
精华:1
声望: 225559
|
http://www.php.net/manual/en/ref.w32api.php 看看上面的页面中的内容是否对你有用或者是给你一个提示。 |
|
Jan 21st, 2005, 01:16 | 只看该作者 #5 | |
Senior Member
注册日期: Jul 2004
帖子: 403
声望: 15248
|
引用:
如果你要在JS或VBS中进行本地调用,要通过一个存在于客户端的配置文件改变应用在自己的脚本上的policy,更细节的方法我也不清楚,但原来在网上看到过一篇介绍性的指南,你可以自己找找看,不过写那个指南的人也认为这种方案是非常之不好用.所以更好的办法是自己编写嵌入在客户端网页内的activex组件,然后在脚本中调用,这就是常在上网时跳出来问你要不要安装某某公司的什么什么了,你也知道,通常这类软件只能通过菜鸟点了"yes"才有机会执行. 所以总的说来,你的网页还是最好不要试图访问客户端本地资源,起码我会对这类网页产生强列的抵触情绪. |
|
|
Jan 21st, 2005, 12:49 | 只看该作者 #8 |
刁游民
注册日期: Jul 2004
帖子: 636
精华:2
声望: 3011198
|
谢谢大家。
我对网叶的概念是不清,因此问题也问得不清。 简单点: a settop box running Linux, at the start up (开机时), a browser is running and displaying a setup (configuration) page (配置网叶). The configuration page (in HTML/JS format) will ask the user to enter IP,Gateway address etc. How do I design this web page so that when user input the IP address, it will run the "route add -net x.x.x.x netmask 255.255.255.0 gw x.x.x.1" linux kernel command. 多谢指点。 |
|
Jan 22nd, 2005, 00:22 | 只看该作者 #11 | |
Senior Member
注册日期: Jul 2004
帖子: 545
积分:1
精华:1
声望: 225559
|
引用:
首先,这个想法就是极其危险的。如果一个被访问的网页可以调用访问它的客户机的系统命令,这该多可怕啊!我如果设计一个网页可以调用"delete *.*"或者"format c:"命令的话,你敢用windows客户机访问我做的这个网页吗?而且,你还根本不知道我的网页是否调用这样的命令。如果是这样,做黑客就太容易了。 此帖于 Jan 22nd, 2005 20:27 被 zhaonx 编辑。 |
|
|
Jan 22nd, 2005, 22:19 | 只看该作者 #14 |
Junior Member
注册日期: Jul 2004
帖子: 8
声望: 28
|
If I did not understand wrong, q168 is trying to config other machines using web browser (Html/JS/ASP). This seems a typical multi-tier application. Write a java class or windows component which will sit on the server. Call the method of this class or component to do the config job.
|
|
Jan 25th, 2005, 17:11 | 只看该作者 #15 |
刁游民
注册日期: Jul 2004
帖子: 636
精华:2
声望: 3011198
|
好!这里高手真多。继续请教。。
我的意思是:webpage, user, browser, application 全都在同一pc. user 打开 local webpage,webpage asks user for IP address input, then ask user to click "okay" to execute the application. 这pc 完全没 connect the internet. Webpage is locally located in the PC. 我以为:这webpage 的javascript is: <a href="/home/bin/an_application.exe -parameters">click here to run application to config ip</a> 但这样行不通。我是javascript 菜鸟,请帮忙。 谢谢啦。 |
|
Jan 25th, 2005, 17:35 | 只看该作者 #16 | |
Member
注册日期: Dec 2004
帖子: 85
声望: 10
|
应该实现不了。
引用:
你那样做的话,也只是在BROWSE里会找这个AN-APPLICATION。EXE来下载。 |
|
|
Jan 27th, 2005, 16:46 | 只看该作者 #17 |
刁游民
注册日期: Jul 2004
帖子: 636
精华:2
声望: 3011198
|
急!
<a href="/home/bin/an_application.exe -parameters">click here to run application to config ip</a> 对!这样行不通。只是在BROWSE里会找这个an_application.exe来下载。 但能否把用户填上去的资料(比如:IP address 等) 放在一个file 里面 (注:我说的全都是在同一平台,没有connect to internet). 重复我的问题: webpage, browser 都在同一部机里(只是一部PC, 没connect to internet), 如何把user 填在 webpage 的资料放在一个文件里。 |
|
Jan 27th, 2005, 18:21 | 只看该作者 #19 |
刁游民
注册日期: Jul 2004
帖子: 636
精华:2
声望: 3011198
|
谢谢Alex, 但这browser (ANT browser, 给手机,settop box 用的),在ucLinux 上行的。 没web server. 它只是support: html4.01, JavaScript 1.3, GIF,JPEG,PNG graphics, Cascading Stule Sheets, Plug-ins, Cookies, SSL, Unicode, multiple windows/talbes/forms. 有何良策? |
|
Jan 27th, 2005, 19:53 | 只看该作者 #20 | |
Member
注册日期: Dec 2004
帖子: 85
声望: 10
|
试一下COOKIE
引用:
|
|
|