java中有Updatepanel控件(如ASp.net)

发布于 2024-07-19 00:23:26 字数 258 浏览 4 评论 0原文

我基本上是一个.net开发人员,我现在正在开发一个java web项目,

在这里我基本上需要从后端获取值(比如生成一个随机数)并在前端每秒更新该随机数,我想为此使用 jquery,

在 ASP.net 中,我知道我可以有一个 updatepanel 并使用 _doPostBack 来更新面板而不刷新整个页面。

这可能是一个愚蠢的问题,但我是一个java新手。

任何具有相同功能的帮助/示例将不胜感激。

谢谢。

Im basically a .net developer, I am now working on a java web project,

here i need to basically get values from the back end (say generating a random number) and update that random number every second on the front end, i want to use jquery for this,

in ASP.net, i know that I can have an updatepanel and use _doPostBack to update the panel without refreshing the whole page.

It might be a stupid question but im a java newbie.

Any help/examples of something that does the same would be greatly appreciated.

Thanks.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

给不了的爱 2024-07-26 00:23:26

在 Java 中,您可以使用 JSF 和诸如 MyFacesIceFaces。 .NET 开发人员需要大量时间来学习这些技术。

如果您打算同时使用 .NET 和 Java,我建议您花一些时间来很好地学习 jQuery 和客户端编程。 这些知识可以在两个世界中为您服务。 使用 jQuery 实现 UpdatePanel 功能是一项简单的任务。 只需创建一个返回内容的服务并使用 $.load() 加载它即可。

In Java you would do something like this with JSF and a rendering kit like MyFaces or IceFaces. A .NET developer would need considerable time to learn these technologies.

If you are going to use both .NET and Java, I recommend to invest some time to learn jQuery and client programming really well. This knowledge can serve you in both worlds. It is a trivial task to implement UpdatePanel functionality with jQuery. Just create a service that returns the content and load it with $.load().

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文