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

Pop up window

Expand Messages
  • cool_n_fresh_guy
    Hi, I have a data table made from XHR data. Now what I want is, 1. If some one click on any raw of the table, then I want a new pop up window to arrive and a
    Message 1 of 4 , Aug 7, 2008
      Hi,

      I have a data table made from XHR data. Now what I want is,

      1. If some one click on any raw of the table, then I want a new pop up window to arrive and a function will be called where the value of the clicked raw will be used as function parameter. Depending on the parameter, the called function will return some value which will be shown in the pop-up windows.

      2. If the table raw contains any URL and any one clicks on it, I still don't want to redirect to a new page rather a new pop-up window should arrive and a function call should be made with thee clicked URL as parameter.

      Does YUI support the thing that I'm trying to do?

      Cheers...
      P
    • Satyam
      ... Partially, yes, the rest is up to you. This is what you do on the DataTable side. myDataTable.on( cellClickEvent , function (oArgs) { var target =
      Message 2 of 4 , Aug 7, 2008
        cool_n_fresh_guy wrote:
        > Hi,
        >
        > I have a data table made from XHR data. Now what I want is,
        >
        > 1. If some one click on any raw of the table, then I want a new pop up
        > window to arrive and a function will be called where the value of the
        > clicked raw will be used as function parameter. Depending on the
        > parameter, the called function will return some value which will be
        > shown in the pop-up windows.
        >
        > 2. If the table raw contains any URL and any one clicks on it, I still
        > don't want to redirect to a new page rather a new pop-up window should
        > arrive and a function call should be made with thee clicked URL as
        > parameter.
        >
        > Does YUI support the thing that I'm trying to do?
        Partially, yes, the rest is up to you. This is what you do on the
        DataTable side.

        myDataTable.on('cellClickEvent', function (oArgs) {
        var target = oArgs.target;
        var column = this.getColumn(target);
        var record = this.getRecord(target);
        var clickedValue = record.getData(column.key);

        });

        So, from the cellClickEcent event you can get the column, the record and
        the cell where the click happened. From then on, you decide what to do
        with all that. From the column.key you can tell which column of the
        table was clicked and decide what to do with it. From the record, you
        read the value in the cell clicked or in any other field in the same
        record. Then you are free to do whatever you want with them.

        Satyam

        >
        > Cheers...
        > P
        >
        > No virus found in this incoming message.
        > Checked by AVG - http://www.avg.com
        > Version: 8.0.138 / Virus Database: 270.5.12/1597 - Release Date: 07/08/2008 5:54
        >
      • cool_n_fresh_guy
        Thanks for your reply with nice information. But, does YUI has any widget or anything for pop-up window? P
        Message 3 of 4 , Aug 7, 2008
          Thanks for your reply with nice information. But, does YUI has any widget or anything for
          pop-up window?

          P

          --- In ydn-javascript@yahoogroups.com, Satyam <satyam@...> wrote:
          >
          > cool_n_fresh_guy wrote:
          > > Hi,
          > >
          > > I have a data table made from XHR data. Now what I want is,
          > >
          > > 1. If some one click on any raw of the table, then I want a new pop up
          > > window to arrive and a function will be called where the value of the
          > > clicked raw will be used as function parameter. Depending on the
          > > parameter, the called function will return some value which will be
          > > shown in the pop-up windows.
          > >
          > > 2. If the table raw contains any URL and any one clicks on it, I still
          > > don't want to redirect to a new page rather a new pop-up window should
          > > arrive and a function call should be made with thee clicked URL as
          > > parameter.
          > >
          > > Does YUI support the thing that I'm trying to do?
          > Partially, yes, the rest is up to you. This is what you do on the
          > DataTable side.
          >
          > myDataTable.on('cellClickEvent', function (oArgs) {
          > var target = oArgs.target;
          > var column = this.getColumn(target);
          > var record = this.getRecord(target);
          > var clickedValue = record.getData(column.key);
          >
          > });
          >
          > So, from the cellClickEcent event you can get the column, the record and
          > the cell where the click happened. From then on, you decide what to do
          > with all that. From the column.key you can tell which column of the
          > table was clicked and decide what to do with it. From the record, you
          > read the value in the cell clicked or in any other field in the same
          > record. Then you are free to do whatever you want with them.
          >
          > Satyam
          >
          > >
          > > Cheers...
          > > P
          > >
          > > No virus found in this incoming message.
          > > Checked by AVG - http://www.avg.com
          > > Version: 8.0.138 / Virus Database: 270.5.12/1597 - Release Date: 07/08/2008 5:54
          > >
          >
        • Satyam
          The container family of components: http://developer.yahoo.com/yui/container/ There is a description of each of them, check which one suits you the best.
          Message 4 of 4 , Aug 7, 2008
            The container family of components:

            http://developer.yahoo.com/yui/container/

            There is a description of each of them, check which one suits you the best.

            Satyam


            cool_n_fresh_guy wrote:
            > Thanks for your reply with nice information. But, does YUI has any widget or anything for
            > pop-up window?
            >
            > P
            >
            > --- In ydn-javascript@yahoogroups.com, Satyam <satyam@...> wrote:
            >
            >> cool_n_fresh_guy wrote:
            >>
            >>> Hi,
            >>>
            >>> I have a data table made from XHR data. Now what I want is,
            >>>
            >>> 1. If some one click on any raw of the table, then I want a new pop up
            >>> window to arrive and a function will be called where the value of the
            >>> clicked raw will be used as function parameter. Depending on the
            >>> parameter, the called function will return some value which will be
            >>> shown in the pop-up windows.
            >>>
            >>> 2. If the table raw contains any URL and any one clicks on it, I still
            >>> don't want to redirect to a new page rather a new pop-up window should
            >>> arrive and a function call should be made with thee clicked URL as
            >>> parameter.
            >>>
            >>> Does YUI support the thing that I'm trying to do?
            >>>
            >> Partially, yes, the rest is up to you. This is what you do on the
            >> DataTable side.
            >>
            >> myDataTable.on('cellClickEvent', function (oArgs) {
            >> var target = oArgs.target;
            >> var column = this.getColumn(target);
            >> var record = this.getRecord(target);
            >> var clickedValue = record.getData(column.key);
            >>
            >> });
            >>
            >> So, from the cellClickEcent event you can get the column, the record and
            >> the cell where the click happened. From then on, you decide what to do
            >> with all that. From the column.key you can tell which column of the
            >> table was clicked and decide what to do with it. From the record, you
            >> read the value in the cell clicked or in any other field in the same
            >> record. Then you are free to do whatever you want with them.
            >>
            >> Satyam
            >>
            >>
            >>> Cheers...
            >>> P
            >>>
            >>> No virus found in this incoming message.
            >>> Checked by AVG - http://www.avg.com
            >>> Version: 8.0.138 / Virus Database: 270.5.12/1597 - Release Date: 07/08/2008 5:54
            >>>
            >>>
            >
            >
            >
            >
            > ------------------------------------
            >
            > Yahoo! Groups Links
            >
            >
            >
            >
            > No virus found in this incoming message.
            > Checked by AVG - http://www.avg.com
            > Version: 8.0.138 / Virus Database: 270.5.12/1597 - Release Date: 07/08/2008 5:54
            >
            >
            >
            >
          Your message has been successfully submitted and would be delivered to recipients shortly.