Quantcast
Channel: Ionic Framework - Ionic Forum
Viewing all articles
Browse latest Browse all 48979

From Ionic Select tag get two attributes

$
0
0

I want to get and store ID & Name of the selected value in dropdown when I select an option.

My HTML form

         <ion-select
          [(ngModel)]="id"
          name="id"
          ngDefaultControl
          interface="popover">

            <ion-select-option
               value="{{data.id}}"
                name="id"
                *ngFor="let data of datas;">
                     {{data.name}}
          </ion-select-option>

        </ion-select>

Thanks :slight_smile:

1 post - 1 participant

Read full topic


Viewing all articles
Browse latest Browse all 48979

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>