Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/usr/bin/php
- <?php
- $data = ":irc.choopa.net 353 EeeZor = #IRP :EeeZor @alberth @AaronBot @UBystand @CoolioJaz @LuaBot @Juju @Eeems";
- // $data = ":irc.choopa.net 333 EeeZor #IRP Eeems!~THEGAME@57o9.org 1304800102";
- $matches = array();
- preg_match_all('/:([\S]+) (353) [\S]+ (?:=|@) #([\S]+) :(.+)/',$data,$matches);
- out($data);
- if(count($matches)>0&&isset($matches[4])){
- out($matches[4][0]);
- $t = explode(" ",$matches[4][0]);
- foreach($t as $u){
- out('Adding user: '.trim($u));
- }
- }
- function out($text){
- echo $text."\n";
- }
- ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement