在应用程序中创建快捷方式 [英] Creating shortcuts in application

查看:91
本文介绍了在应用程序中创建快捷方式的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述




您知道我们如何打开微软Word文档。在其中键入内容。然后保存(在本例中为桌面)。桌面上会出现一个图标。下次我们要做的就是双击图标,它将打开我们保存的文件。


所以我的问题是,我们可以编写javascript / dhtml这样的方式来执行像上面描述的函数一样?


谢谢



You know like how we open a microsoft word document.Type something in it.Then save it (in this case on the desktop). An icon will appear on the desktop. The next time all we have to do is double click on the icon and it will open our saved document.

So my question is, can we code javascript/dhtml such a way to perform a function like i described above?

Thanks

推荐答案

嗨...


你使用javascript做的所有事情都严格地绑定到浏览器......你可以创建一个浏览器 - 桌面......这意味着你创建一个看起来像桌面的网络应用程序,你可以做任何你想做的事......但是你不能在浏览器之外做任何事情......除了写cookie你不能访问客户端的文件系统......所以你不能读/写它的东西。 ..


亲切的问候
hi ...

all things that you do with javascript are strictly bound to the browser ... you may create a ''browser''-desktop ... that means you create a web-app that looks like a desktop and there you may do whatever you want ... but you cannot do things outside of the browser ... except of writing cookies you don''t have access to the client''s filessystem ... so you cannot read/write things to it ...

kind regards


hi

你是什么意思

" ;这意味着你创建一个看起来像桌面的网络应用程序,你可以做任何你想做的事情。 ...


目前,我有一个index.php文件,当点击文件的链接时会生成小部件。这个index.php文件可以被认为是我的桌面吗?

我如何创建函数来创建桌面快捷方式后获得网址?


谢谢
hi
what do u mean by
"that means you create a web-app that looks like a desktop and there you may do whatever you want" ...

Currently, i have a index.php file where widgets are generated when clicked on links of the files. Can this index.php file be considered my desktop?
and how do i create functions to create desktop shortcuts after being given a url?

Thanks



hi

你是什么意思

"这意味着你创造了一个看起来像桌面的网络应用程序,你可以做任何你想做的事情。 ...


目前,我有一个index.php文件,当点击文件的链接时会生成小部件。这个index.php文件可以被认为是我的桌面吗?

我如何在给出网址后创建创建桌面快捷方式的功能?


谢谢
hi
what do u mean by
"that means your create a web-app that looks like a desktop and there you may do whatever you want" ...

Currently, i have a index.php file where widgets are generated when clicked on links of the files. Can this index.php file be considered my desktop?
and how do i create functions to create desktop shortcuts after being given a url?

Thanks



是......确切地说......你的网页加载到浏览器后,就是你的桌面......以及你的准运行时环境 ''对于所有的javascript-actions ...根本没有......实际上......它是浏览器窗口,你的文档提供了可以执行的js代码......但正如我所说的...... js不能在这里突破浏览器。


a''short-cut''正如你现在所说的那样......只是网页中的一个链接......你可以分配链接到你想要的一切...使用一个图标(图像)...把它放在你的网页上...分配一个onclick处理程序,加载你想要的网址,或者只是创建一个简单的链接 - 在需要时列出。我假设您可以在页面上执行某些操作...这会导致创建网址...现在您想在页面上放置直接链接? ...所以你可以使用dom-methods(createElement(''tag_name''),setAttribute(''attr_name'',''attr_value'')等)来实现...

i希望我让自己明白......如果你需要一个例子或类似的东西,请求更多。


亲切的问候

yes ... exactly ... your webpage, when loaded to the browser, is your ''desktop'' ... and your ''quasi-runtime-environment'' for all javascript-actions ... not at all ... in reality ... it is the browser-window, and your document provides the js-code that may be executed ... but as i said ... js cannot break out of the browser here.

a ''short-cut'' as you call it now ... is simply a link in a webpage ... and you may assign that link to everything you want ... use an icon (image) ... place it an your webpage ... assign an onclick-handler that loads the url you want whereever you want ... or simply create a simple link-list when you need it. i assume you may do something at the page ... that results in creating an url ... and now you want to place a direct link at the page? ... so you may use dom-methods (createElement(''tag_name''), setAttribute(''attr_name'', ''attr_value'') etc.) to achieve that ...

i hope i made myself clear ... ask for more in case you need an example or something like that.

kind regards


这篇关于在应用程序中创建快捷方式的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆