如何使用 javascript 获取更新的innerHTML
我这个页面包含 3 个可拖动的 div。
我正在使用 JQuery 将这些 div 拖动到页面上。
现在当我将它们拖到不同的位置时。
他们的属性值应更改为新位置。
例如,当页面加载第一个 div 值时:
<div style='position:absolute;left:1px;top:1px;'>
拖动框后,它应该更改为新位置。应该显示更新的innerHTML,但它似乎不起作用。
不,我不想使用 findposition 函数,因为这只是一个示例,我有广泛的属性/对象。
所以我需要的是获取更新后的innerHTML。 有什么方法可以用javascript做到这一点吗?
谢谢
I have this page contains 3 draggable divs.
I'm using JQuery to drag these divs on the page.
Now when I drag them to different positions.
their attributes values should be changed to the new positions.
for example when the page loads the first div value:
<div style='position:absolute;left:1px;top:1px;'>
after I drag the box it should be changed to new position. the should show updated innerHTML but it seems not to be working.
and no I dont wanna use the findposition function because this is only a sample and I have wide range of attributes/objects.
so what I need is to get the updated innerHTML of .
is there any way to do this with javascript?
thanks
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我使用的是
$.get('page.html', function(response){});
。我刚刚将其更改为:
现在一切都很顺利。
I was using
$.get('page.html', function(response){});
.I just changed it to:
Now everything is workin like charm.