Reputation: 953
Href = "tel" is not working on ionic 3 and this is my code
<ion-item color="none" href="tel:(51) 9 9222 - 7607">
<ion-icon name="call" item-left></ion-icon>
Contato: {{ property.contato1 }}
</ion-item>
Upvotes: 4
Views: 1503
Reputation: 190
call this method from your html
<button ion-button (click)="callNumber(1236547890)">Call Number</button>
and in .ts write this
callNumber(phoneNumber){
window.open('tel:' + phoneNumber, '_system');
}
Must work in ios and android
Upvotes: -1
Reputation: 39434
I think href
is available on an a
, but not an ion-item
element. So you want either:
<a ion-item href="tel:..."><ion-icon>...</ion-icon></a>
or
<ion-item>
<a href="tel:..."><ion-icon>...</ion-icon></a>
</ion-item>
(In these examples, replace the ...
with the appropriate content.)
Upvotes: 6