Open fkaul opened 12 years ago
Because the name will be read out from the contacts from the smartphone.
Of course - when I open whatsapp the message is displayed unter the correct contact. But in whatsapp you can define your own username as well. This username is used for the message display at the homescreen or the lockscreen. Its kind of a message preview. I think this is what they mean by "nickname" in the whatsapp.php.
Normally it would display something like Kaul: Hallo there!
But it shows: 4917296235269: Hallo there!
Did you sent the message to yourself?
Yes I did.
Yes, I did it too and saw my own number. My friends (who got spammed from me :D) saw my name, which they saved in their contacts.
I just tried sending it from another phone which makes no difference. Instead of the nickname the phone number is shown in the message preview at the homescreen.
I can reproduce this issue with an Iphone as client. To fix this a presence stanza must be send at the beginning of the session.
That one looks something like this:
<presence name="Nickname"></presence>
After that the incoming Iphone notification will appear with the nickname instead of the phonenumber. I created pull/77 for the fix. To use it
$wa->sendNickname("nicknameyouwanttouse");
how do i add nickname using the new codes in 1.2?
Hello, yesterday i download the package, everything ok, it's great!!, but i have a problem when i want to send a nickname, i try with sendNickname($nickname) after the Login(), but no send messages, What's the problem? Sorry for my english, i am spanish thank's
When sending a message through tests/whatsapp.php the nickname appearing at the lockscreen of the receivers phone is always the phonenumer.
Changing the nickname has no effect.
Can someone help me with that?
Cheers kaul