on both version´s off mIRC 6.21 and 6.32.


Code:
;---------------CODE--------------
alias test {
  remove test.txt
  write -i1 test.txt hi
  write -i1 test.txt bye
  echo -a $lines(test.txt) == 2
  echo -a $read(test.txt,n,1) == hi
  echo -a $read(test.txt,n,2) == bye
}
;---------------OUTPUT-------------
2 == 2
hi == hi
bye == bye


Code:
;---------------CODE--------------
alias test1 {
  remove test.txt
  write -al1 test.txt hi
  write -al1 test.txt bye
  echo -a $lines(test.txt) == 2
  echo -a $read(test.txt,n,1) == hi
  echo -a $read(test.txt,n,2) == bye
}
;---------------OUTPUT-------------
1 == 2
hibye == hi
== bye


My second question is:

On help is saying : The -i switch indicates that the text should be inserted at the specified line instead of overwriting it. If you do not specify any text then a blank line is inserted. If you do not specify a line number then a blank line is added to the end of the file.

Why the -i $+ Line don´t work to insert text to that line like it´s says on help ??

Why do we need to use the -al $+ line option ??