from the mIRC help file:
Quote:
The /ignore command

/ignore [-lrpcntikdwxu#] <on|off|nick/address> [type] [network]

Where p = private, c = channel, n = notice, t = ctcp, i = invite, k = control codes, d = dccs.

(...)

Note: If you have a /query window open with someone, private messages from them won't be ignored even if their address matches an ignore address.

therefore, if you want to ignore private messages only, change the line
Code:
ignore $ifmatch $protect(%nr).network
to
Code:
ignore -p $ifmatch $protect(%nr).network