Legendary Posted December 31, 2007 Share Posted December 31, 2007 Ok, on my site, every user has a profile. I want them to be able to allow a Live Chat button to show up on there profile, that will look like this : <a href="chat/main.php?userID=(userid)"><img src="images/livechat.png" border="0"></a> userid is what number user they are. So when they click that image, it will notify the other user that someone wants to chat with them, and if they accept, it will open a private Live chat with them, and the other person. If they are already in a chat, show a Please hold, already in use message, and the person who put the button there, can have admin features such as Ban from his/her chat. How can I make this? Quote Link to comment https://forums.phpfreaks.com/topic/83791-how-would-i-go-about-creating-this/ Share on other sites More sharing options...
forumnz Posted December 31, 2007 Share Posted December 31, 2007 You will probably need to look into AJAX. You will also have to execute something on main.php which sends a message to user where id=??. Sam Quote Link to comment https://forums.phpfreaks.com/topic/83791-how-would-i-go-about-creating-this/#findComment-426329 Share on other sites More sharing options...
Legendary Posted December 31, 2007 Author Share Posted December 31, 2007 Well, it wouldn't have to be sent to the person, it could be like, on there next refresh, have it show it. Or just have an auto refresh script on. Quote Link to comment https://forums.phpfreaks.com/topic/83791-how-would-i-go-about-creating-this/#findComment-426331 Share on other sites More sharing options...
forumnz Posted December 31, 2007 Share Posted December 31, 2007 Ok, but the person would still need notifying. I'd say have something included in each page like <php include('notify.php'); ?> Then notify.php would have the script which would do something like open a pop-up window if there was someone wanting to start chat. Sam Quote Link to comment https://forums.phpfreaks.com/topic/83791-how-would-i-go-about-creating-this/#findComment-426332 Share on other sites More sharing options...
Legendary Posted December 31, 2007 Author Share Posted December 31, 2007 Yea, thats good. But what I really need is chat.php I don't get how I would make it. To be able to do that Id thing. I mean I'm willing to do anything. Even if for every user, a new chat gets auto ftp'ed to there profile. Quote Link to comment https://forums.phpfreaks.com/topic/83791-how-would-i-go-about-creating-this/#findComment-426340 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.