Loading ...
Sorry, an error occurred while loading the content.

Re: [ydn-javascript] Need urgent reply

Expand Messages
  • Adam Platti
    Put a element inside of the and register the s as draggable, not the s. If you set the size of the TDs properly, then you should not see
    Message 1 of 2 , May 21 10:15 AM
    • 0 Attachment
      Put a <div> element inside of the <td> and register the <div>s as draggable, not the <td>s.  If you set the size of the TDs properly, then you should not see any movement.

      It should be okay for you to register the <td>s as targets.

      Adam



      On 5/21/07, SHIVA KUMAR <shiv_indian@...> wrote:

      Hi ,
       
        This is Siva Kumar.I have started to develope UI using YUI.I am beginner.In my application I have to drag lables/images with displaying no . from one table to another table.(Suppose if I drag <td> from one table to another table the sizes of the tables must readjust) I have tried a lot to do this.But I failed to reach my goal.So anybody please help me in this.I will be greatful to all.
       
      Thanks & Regards,
      Siva Kumar


      Office firewalls, cyber cafes, college labs, don't allow you to download CHAT? Here's a solution!


    • Adam Moore
      ... Some general hint for working with tables: * Dragging the actual td is almost never what you want to do as this will cause problems with the table layout.
      Message 2 of 2 , May 21 11:23 AM
      • 0 Attachment
        On Mon, May 21, 2007 at 10:15:28AM -0700, Adam Platti wrote:
        > Put a <div> element inside of the <td> and register the <div>s as draggable,
        > not the <td>s. If you set the size of the TDs properly, then you should not
        > see any movement.
        >
        > It should be okay for you to register the <td>s as targets.
        >
        > On 5/21/07, SHIVA KUMAR <shiv_indian@...> wrote:
        > >
        > > Hi ,
        > >
        > > This is Siva Kumar.I have started to develope UI using YUI.I am
        > >beginner.In my application I have to drag lables/images with displaying no
        > >. from one table to another table.(Suppose if I drag <td> from one table to
        > >another table the sizes of the tables must readjust) I have tried a lot to
        > >do this.But I failed to reach my goal.So anybody please help me in
        > >this.Iwill be greatful to all.

        Some general hint for working with tables:

        * Dragging the actual td is almost never what you want to do as this will
        cause problems with the table layout. Use YAHOO.util.DDProxy rather than
        YAHOO.util.DD.

        * Unless you intend to swap the two cells when you drop, you are probably
        concerned with the cell contents, not the cell itself. If this is the
        case, follow Adam's advice and place a div inside of the td and use that
        as the source element.

        * Make sure the source element (whether a td or a div) has a css position
        attribute applied (probably position:relative).

        * Post/link your code for additional help.


        -Adam
      Your message has been successfully submitted and would be delivered to recipients shortly.