Unfortunately I am still unable to reproduce the issue here. I have installed Firefox, Opera, and have run all three browsers at the same time, closed them, etc. //echo $url seems fine for me. Perhaps you have some other software running in the background that is interfering in some way.
When you say mIRC "crashes", do you mean it actually crashes and reports an error message, or it freezes?