|
|
| Author |
Message |
darkwarrior Lurker

Joined: 02 Aug 2008 Posts: 172
|
Posted: Oct 29, 2008 3:12pm Post subject: PHP IRC Bot |
|
|
Greetings all. I am looking for a simple, free open source PHP IRC Bot that has a basic web panel. As an example, I visit http://mysite.com/bot.php and then there's a few different administration tasks I can perform, such as "Change Nickname" where I enter in a nickname, click submit, and then the Bot will do /nick Newnickname, and even a "Join Channel" where I type in a channel, and the bot will /join #channel ... I basically just need something like that that I can expand off of to build some additional features for my IRC Network.
I actually know how to get the php bot to connect and listen to commands on IRC, but I don't know how I'd make it communicate with the web. So, if anyone knows where I can find something along these lines, doesn't have to be exactly what I asked, at least a php bot that has a web panel that can make it perform commands on IRC. |
|
| Back to top |
|
 |
PingBad Guru

Joined: 05 Feb 2005 Posts: 2099 Location: New Zealand
|
Posted: Oct 29, 2008 4:29pm Post subject: |
|
|
| you're more than likely going to need a listening socket or use of DDE/DCOM for you to be able to interface with the bot in realtime while still having it on IRC (I'm assuming you're running your bot's script as a shell script - ie: [user@host ~]$ ./bot.php - as opposed to a web page url) |
|
| Back to top |
|
 |
zeke Idler

Joined: 04 Oct 2003 Posts: 325
|
Posted: Oct 29, 2008 5:12pm Post subject: |
|
|
SmartIRC is a PHP class which I have used several times for various bots. One could theoretically use a SQL database or a text file to pass information to a bot - it would be laggy, since it wouldn't make sense to poll SQL every second. Maybe every 20 or so?
Web panel passes request to SQL table, bot processes pending commands and deletes them, perhaps?
Bot would also update things regularly also - would prevent needing to pass commands constantly and wait for a response.
It would still be particularly laggy if the web client was waiting for responses from the bot.. |
|
| Back to top |
|
 |
greg27 Lurker

Joined: 07 Oct 2006 Posts: 179 Location: Australia
|
Posted: Oct 29, 2008 5:19pm Post subject: |
|
|
| take a look at this - i believe it does what zeke suggested and queries a mysql database every x seconds to check for new commands. it looks as though the project may have been abandoned, but it could provide a good starting point for you. |
|
| Back to top |
|
 |
|