Also the menu with /status didn't work. Same also for the most recent mirc.

Anyhow, I modified the script a little without knowing what I am doing.

Code:
on *:connect: { getip }

alias getip {
  if ($sock(getip)) { sockclose getip } 
  sockopen getip www.whatismyip.com 80
  sockmark getip $1
}

on *:sockopen:getip:{
  if ($sockerr) { echo -snc info * [GetIP] Cannot resolve your ip: $sock($sockname).wsmsg | return }
  sockwrite $sockname GET $+(/automation/n09230945.asp HTTP/1.0,$lf,HOST: $sock($sockname).addr,$str($lf,2))  
}

on *:sockread:getip:{
  sockread -f &a
  var %s = $gettok($bvar(&a,1-).text,-1,10), %r =  /^(?:\d{1,3}\.){3}\d{1,3}$/
  echo aa
  if (!$regex(%s,%r)) {
    echo c
    echo -snc info * [GetIP] Error parsing socket reply: $bvar(&a,1-).text
    echo d
  }
  else {
    set -e %external.ip %s
    echo -snc info * [GetIP] Resolved external IP: %s (set at 'local info')
    .localinfo $host %s
  }
}


Now I get
Code:
aa
c
* [GetIP] Error parsing socket reply: Date: Fri, 08 Oct 2010 11:27:48 GMT
Server: Microsoft-IIS/6.0
X-Powered-By: ASP.NET
X-AspNet-Version: 2.0.50727
Location: http://nnscript.com
Cache-Control: private
Content-Length: 0


d
aa
* [GetIP] Resolved external IP: .....(modified by me)....... (set at 'local info')


And it works. Correct IP is set every time. Also the eggdrop partyline (dcc chat) is works now.

Thank you again for your effort!