mIRC Home    About    Download    Register    News    Help

Print Thread
Joined: May 2003
Posts: 4
R
Self-satisified door
OP Offline
Self-satisified door
R
Joined: May 2003
Posts: 4
Given this input "*** Client exiting: <nick> (<ident>@<domain>) (User has been mind-ripped)", how do I extract JUST the fully-specified domain name, ignoring everything else? confused (note that I have protected the actual data from one of the messages by replacing it in the note above with metatags)

This is from an on:1:SNOTICE:*mind-ripped* command, and is our server's peer-disconnect message format; I am trying to track involuntary disconnects from server by date, time and domain, so only want domain and time/date (time/date is taken care of).

Joined: Feb 2003
Posts: 2,812
Hoopy frood
Offline
Hoopy frood
Joined: Feb 2003
Posts: 2,812
define: fully specific domain name
1. host.com
2. user@host.com
3. nick!user@host.com

- Raccoon
Is "mind-ripped" a Matrix reference?


Well. At least I won lunch.
Good philosophy, see good in bad, I like!
Joined: May 2003
Posts: 4
R
Self-satisified door
OP Offline
Self-satisified door
R
Joined: May 2003
Posts: 4
Quote:
define: fully specific domain name
1. host.com
2. user@host.com
3. nick!user@host.com

Is "mind-ripped" a Matrix reference?

#1 will DO, but I'd prefer to capture everything after the @...I need the location data to be as specific as possible for the chart to have enough meaning.

As for "mind-ripped" being a reference to the movie "The Matrix", I think not...although I could easily be wrong here. Katherine Kurtz has used the term in several of her books as well.

Joined: Mar 2003
Posts: 272
C
Fjord artisan
Offline
Fjord artisan
C
Joined: Mar 2003
Posts: 272
Code:
On *:SNOTICE:*mind-ripped*:{
  echo -s $4 $+ !*@ $+ $remove($gettok($5,2,64),$chr(41))
}


That should do it, you can just use $remove($gettok($5,2,64),$chr(41)) to return that 'fully-specified' domain.


- cF
Dedicated helper for rent.
Joined: May 2003
Posts: 4
R
Self-satisified door
OP Offline
Self-satisified door
R
Joined: May 2003
Posts: 4
Thanks. Will see if it works as planned...Heh. Will know when I get up in the morning. smile

Joined: May 2003
Posts: 4
R
Self-satisified door
OP Offline
Self-satisified door
R
Joined: May 2003
Posts: 4
Sadly, it produces more characters than the raw server notice. Perhaps I did not make clear that I was using /msg to pipe the output to a dedicated channel? smile
Code:
on 1:SNOTICE:*mind-ripped*:/msg #Peerwatch On $adate at $time $1-

This (above) was the original code used. Sadly, the code snippet did not work as planned. Whole idea here is to produce a logfile with just the involuntary disconnects in it to simplify processing. I know that my code doesn't work as intended, though. smile


Link Copied to Clipboard