how to make a phone call
on click of label i set local storage variable pn1 with phone no. from lable.
on pop up i put a button and in click event put js
window.location.href='tel:' + pn1;
after running app on real phone it is not working
Catch up wih the Appery.io community on our forum. Here you'll find information on the lastest questions and issues Appery.io developers are discussing.
https://forum.appery.io/
on click of label i set local storage variable pn1 with phone no. from lable.
on pop up i put a button and in click event put js
window.location.href='tel:' + pn1;
after running app on real phone it is not working
To get value from local storage please use next code:
pre
localStorage.getItem('pn1');
/pre
Your code should be like this:
pre
var phone=localStorage.getItem('pn1');
window.location.href='tel:' + phone;
/pre
i tried it on phone .
it just send no. 5 to call.
if i put direct no. instead of local storage i will send that no. to call.
Please try to put next code on button click event:
pre
window.location.href='tel:8805693250';
/pre
Does it work for you?
as i told u , i want to dial the no. fetched from database not a fix no.
the person is not knowledgeable
Thank you for your feedback. Your opinion is very important for us.
Hi Ketan,
What data do you store in Database?
Could you show us a screenshot of service response please?
I am storing number.
Fetching it to a label.
After touching label popup is opening.
On pop up there is a button for calling the number.
Hi Ketan,
Let's try the following:prewindow.open("tel:" + Appery('label').text());/preWhere 'label' is a label where you mapped a number beforehand.