I am developing a website in PHP. Now, I would like to simply add a notification system. Imagine it like Facebook friendships: when I get a friend request, I get a notification too.
I of course know a bit of Node.JS and Socket.IO, but the tricky part seems to be the implementation with PHP.
What I though of so far is:
1. user sends friend request
2. in my PHP code, I cURL my Node.JS service: "/notification?friendid=9634963478"
3. user with id 9634963478 should get a notification
The problem I am facing is:
How do I "log in" with the same credentials on Node.js? So that Basically no other user than me can get the messages?
I am not looking for code, but rather an "enlightenment" from some guru out there.