Author | Message | Time |
---|---|---|
privatewilly | Hi! The subject says it all. Does someone know a ways to list the users that are actually present in a battle.net channel in php? The Webbot here works as complete chat programm, but I only need the user list. Any guesses? thx, Willy | January 30, 2004, 11:14 AM |
j0k3r | I believe there are multiple threads here that touch on the subject, maybe go look through them, tell us what you find, then write your own? | January 30, 2004, 11:25 AM |
privatewilly | I tried to search but didn't find anything. But because you asked so nicely, and knowing now that there is something that can be found, I will try again :) | January 30, 2004, 1:09 PM |
Tuberload | You are either going to have to interface the PHP script with a bot made in another programming language, or make a bot of sort out of PHP that will connect, logon, join the specified channel, and gather information. I would go with the first suggestion, but either should work. Keep in mind the second solution assumes PHP supports sockets, and I don't know whether it does or not. Edit: PHP does have socket support, so code on! | January 30, 2004, 7:25 PM |
privatewilly | Doesn't anyone know if this has been done already? "This" = only php-bot-sort-of-thing. :) | February 2, 2004, 10:23 AM |
j0k3r | Let me ask why does it have to be in PHP? | February 2, 2004, 12:32 PM |
privatewilly | That way, I could easily display just who is present in a spezific channel. I don't need the rest (chatting, pics, etc.). I only want to do a script which asks "is someone online?", and the response will be "yes, 5" or "no". And for the php-question: cause i can only access php. perhaps asp. but no bot on a server or such a thing. You understand, I'm running a "Query-Server-Site-With-Php", so I'm just interested in that part. And I thought "maybe someone has a solution for that". ps: I'm aware that this post is a complete mess :) | February 2, 2004, 2:22 PM |
Tuberload | [quote author=privatewilly link=board=22;threadid=4999;start=0#msg42292 date=1075731727] That way, I could easily display just who is present in a spezific channel. I don't need the rest (chatting, pics, etc.). I only want to do a script which asks "is someone online?", and the response will be "yes, 5" or "no". And for the php-question: cause i can only access php. perhaps asp. but no bot on a server or such a thing. You understand, I'm running a "Query-Server-Site-With-Php", so I'm just interested in that part. And I thought "maybe someone has a solution for that". ps: I'm aware that this post is a complete mess :) [/quote] Maybe you can't read, but I gave you two solutions to your little problem in a previous post... | February 2, 2004, 9:46 PM |
privatewilly | yes, no problems with reading so far. Got even my screen turned on. I thank you for your solutions. But I asked if someone already has a working solution in his sleeve, and I wanted to answer joker's question. | February 2, 2004, 11:03 PM |
Myndfyr | One of the features I've wanted to implement in my bot that is somewhat held up while my computer is fixed is to do something like this. Basically, I'm using the .NET Platform for the bot application and my website.... The website provides a web service that basically says "User_Joined(string screenName, string pid)" and "User_Left(string screenName)," and we keep the users list in state memory. Whenever someone requests the page, it checks state memory to see if that user has been online. That was my solution, although how you could move this to PHP, I'm not sure. | February 3, 2004, 12:11 AM |
Kp | [quote author=privatewilly link=board=22;threadid=4999;start=0#msg42292 date=1075731727] I only want to do a script which asks "is someone online?", and the response will be "yes, 5" or "no".[/quote] If you only want to say whether someone is online, the task becomes much easier. In such a case, your client merely needs to logon as 'anonymous' and issue a /whois, then parse the result. Logging on as anonymous means you can use the chatgate, that you won't disturb the channel's users, and that you have a lot less material to parse. | February 5, 2004, 10:52 PM |
privatewilly | thx, for the hint. "anonymous"logon already works. | February 9, 2004, 10:50 PM |
blinkdude | my web channel is done in php.... use vb to connect if you dont know alot about packets and blah flags use CSB by cuphead.... on the Userjoins Event use OCD or sqlvb6.dll to update who joins and then send it to MySql. [code] Private Sub CSB_UserJoins(ByVal Username As String, ByVal Flags As Long, ByVal Message As String, ByVal Ping As Long, ByVal Product As String, SimulatedEvent As Boolean) txtsqlq.text = "Insert into `table name` where `ID` =" & Username & "and `ping` =" & ping & "and `icon` =" & icon call sqlinsert(txtsql.text) End Sub [/code] then when the lea i think its UserLeaves use [code] Private Sub CSB_UserLeaves(ByVal Username As String, ByVal Flags As Long, SimulatedEvent As Boolean) txtsqlq.text = "Delete from `blah` where `ID` =" & Username call del(txtsql.text) End Sub [/code] for the calls you need the dll thats the way i use... just search on google for Vb To MySql and im sure youll find something just as ez ... heres a link to my web bot... http://www.eternalsoldiers.net/esbot/chnnel.php and if you want to just use spht web bot you can and use this link for just users in channel. http://www.valhallalegends.com/skywing/isapi/BinaryChatISAPI.dll?channellistex=accname | February 11, 2004, 11:44 AM |
Grok | "sqlvb6.dll"? What is that, a bare-naked MSSQL ODBC? If you're using VB6 for such a trivial application such as a bot, there's no excuse to not use ADO and ADOX. If you're wanting more power than you can get with an Access database, you can install MSDE too. | February 11, 2004, 12:41 PM |
blinkdude | Yea but with that dll it will handle the queries 1 by 1 , in order not all at once this is wat it says on the file i found came with .dll and module's text [code] ' MySQL Module for Visual Basic written in Delphi ' ' Introduction: The dll this module links to is in fact a wrapper for libmySQL.dll, ' which, because of the complicated data structures would be harder to implement in VB. ' libmySQL.dll is part of the mySQL package and can be freely distributed as such. [/code] | February 13, 2004, 10:54 PM |