English 中文(简体)
在本项删除后再界定可减少面积
原标题:Redefining droppable area after current item is removed

我拥有一个标志网。 你可以两次点击 log原,以清除原木,或者可以把它拖到一个特定的广场,我想在那里透露有关该标志的一些细节。

Here is the tool in question:

rel=“nofollow” Drag or Hide alogo

我有两个问题,请你协助我:

  1. 当我把一个标志拖到可投放的广场时,我会如何收集有关该具体标志的信息,并透露在可投放地区后面的信息?

  2. 当我两次点击一个沉降到可耕地的标志时,该标志将消失。 在消失之后,我如何重新界定这一可缩小面积,并将其用于其他标志?

如果你看到任何其他信息,请让我知道更好的执行方式。 谢谢你!

www.un.org/spanish/ecosoc 页: 1

<script>

$(document).ready(function() {

$( .imageShowing ).dblclick (function() {

  $(this).stop().animate({
    zIndex:  1 ,
    height:  100 ,
    width:  140 ,
  }, 100, function() {

        $(this).rotate({ angle:0,animateTo:90,easing: $.easing.easeInOutExpo })

    $(this).stop().animate({
    zIndex:  1 ,
    top:  500 ,
    opacity:  0 
  }, 700, function() {   
  $(this).hide("fast");  
    // Animation complete.
  });
  });
});

}); //end document.ready


$(init);

function init(){
    $( .imageShowing ).draggable( { 
    containment:  #wrapper ,
    cursor:  move ,
    snap:  #droppable ,
    stop: cardDropped,
    start: objectGrabbed,
    revert: true,
    }); 

    $( #droppable ).droppable( {
        drop: handleCardDrop,
        hoverClass:  droppableHover ,
        accept:  .imageShowing 
    });

}

function objectGrabbed(event, ui) {
    $(this).stop().animate({
    zIndex:  100 ,
  },0,function() { 
    $(this).stop().animate({
    opacity:  .5 
  }, 500);

  });
}

function cardDropped() {
    $(this).stop().animate({
    opacity:  1 ,
    zIndex:  12 
  }, 500);
 }


function handleCardDrop( event, ui ) {
    ui.draggable.draggable(  disable  );
    $(this).droppable(  disable  );
    ui.draggable.position( { of: $(this), my:  left top , at:  left top  } );
    ui.draggable.draggable(  option ,  revert , false );
    }

</script>

www.un.org/spanish/ecosoc 如果需要的话,社会保障局:

#wrapper { width: 1000px; margin: 0 auto; height: 1000px; position: relative;}
#grid {width: 935px; height: 536px; margin: auto; background: url(images/gridLine.png) repeat-y top; padding:0; position: relative; z-index: 5;} /* height equals 134 X 4. Each horizontal grid is 134 in height and 950px in width */

#logoWrapper {position: absolute; top: 2px; left: 36px }

#logoWrapper ul {text-decoration: none; list-style-type: none; margin:0; padding:0; }
#logoWrapper ul li {list-style-type: none; float: left; position: relative; padding: 0 6px 6px 0; height: 128px; width: 180px; margin: 0;}
#logoWrapper ul li img { margin:0; position: absolute; z-index: 6;}

#bottom { height: 500px; width: 950px; background: #fff; margin: 0 auto; position: relative; z-index: 10;}
#droppableWrapper {border: dashed 5px #666; width: 180px; margin:0 auto; }
#droppable {height: 128px; width: 180px; background: #CCC;};
.droppableHover {background: #333; }
最佳回答

第一个问题。 对我来说,这取决于:

a) 你将展示多少信息,

b) 储存该胎(在html? 标识数据属性? ajax?

对我来说,这比任何东西都更像是一个设计问题,但一旦我知道数据在哪里,数据在哪里进行,我就只是为检索数据、把它放在模板上以及在网页上展示功能。 然后看看一下你们的退步。

您的第二个问题...... 它希望你能够再次 drop落。 也许有些东西,例如$(#drable ).droppable(able ),在你进行 d布式 an升后进行,但我想看一下 j子的docs子。

问题回答

暂无回答




相关问题
selected text in iframe

How to get a selected text inside a iframe. I my page i m having a iframe which is editable true. So how can i get the selected text in that iframe.

How to fire event handlers on the link using javascript

I would like to click a link in my page using javascript. I would like to Fire event handlers on the link without navigating. How can this be done? This has to work both in firefox and Internet ...

How to Add script codes before the </body> tag ASP.NET

Heres the problem, In Masterpage, the google analytics code were pasted before the end of body tag. In ASPX page, I need to generate a script (google addItem tracker) using codebehind ClientScript ...

Clipboard access using Javascript - sans Flash?

Is there a reliable way to access the client machine s clipboard using Javascript? I continue to run into permissions issues when attempting to do this. How does Google Docs do this? Do they use ...

javascript debugging question

I have a large javascript which I didn t write but I need to use it and I m slowely going trough it trying to figure out what does it do and how, I m using alert to print out what it does but now I ...

Parsing date like twitter

I ve made a little forum and I want parse the date on newest posts like twitter, you know "posted 40 minutes ago ","posted 1 hour ago"... What s the best way ? Thanx.