qTip,draggable

时间:2012-03-04 23:17:49

标签: jquery jquery-ui-draggable qtip

我正在尝试获取qtip示例:

http://craigsworks.com/projects/qtip/demos/position/fixed

这样当猫头鹰的图像被移动时,qtip随之移动(并保持在右上角)。

谢谢!

奖金问题..我也试图在猫头鹰周围出现悬停边框以及鼠标悬停。

以下是实现这种qtip风格的代码:

<script type="text/javascript">
// Only create tooltips when document is ready
$(document).ready(function()
{
   // Use the each() method to gain access to each of the elements attributes
   $('#content img').each(function()
   {
      $(this).qtip(
      {
         content: '<a href="#">Edit</a> | <a href="#">Delete</a>', // Give it some content
         position: 'topRight', // Set its position
         hide: {
            fixed: true // Make it fixed so it can be hovered over
         },
         style: {
            padding: '5px 15px', // Give it some extra padding
            name: 'dark' // And style it with the preset dark theme
         }
      });
   });
});
</script>

我不知道为什么文档没有尖叫回答我!

1 个答案:

答案 0 :(得分:3)

以下是qtip弹出窗口可拖动的示例。

http://jsfiddle.net/cagura/VunSW/

相关问题