jaytea commented on a Page, Real Name Revealer  -  Sep 01, 2011

Try changing this bit:
[quote]
var %realnick $ial(*,0)

to this:

var %realnick $iif($regex($ial(*,0),/^(.+?)$/),$regml(1))

[/quote]

what???

(Angel) Hi (Robin)-girl Hi

a quick look at the script, and i can only see this happening if the regexes contained '\b' in place of '\s'.

jethro, you see why coding like this can be detrimental? it makes it 1000 times harder to debug and interpret your scripts. it also leads to code that is painfully inefficient. looping through all IAL entries when you know you only have one nick to handle ($nick)?? oof.

there is one, and only one, reason to combine code in the manner that you've attempted. if you have the same procedure in numerous places in your script, it's a good idea to extract it and abstract it if necessary in order to avoid having to change the same thing repeatedly when it's time to update the procedure. but it needs to be the SAME procedure, not one that is dependent upon the area of the script from which it's called. as soon as you have to construct more than a couple of '$iif($event ...'s or include a segment of code which will be executed unnecessarily more often than not, then you've taken a step in the wrong direction.

 Respond  
Are you sure you want to unfollow this person?
Are you sure you want to delete this?
Click "Unsubscribe" to stop receiving notices pertaining to this post.
Click "Subscribe" to resume notices pertaining to this post.