While getElementsByTagName is part of the core DOM specification:
http://www.w3.org/TR/2000/REC-DOM-Le...l#ID-745549614
getElementsByName is defined only for the HTMLDocument object.
http://www.w3.org/TR/2003/REC-DOM-Le...ml#ID-26809268
Considering your particular example:
1. Starting HTML 4.01 (maybe earlier) name attribute can not be used with div element (and most elements as well). It was left mostly for backward compatibility with form elements. So you should not be using it like that.
2. You can retrieve the same list of nodes by:
document.getElementsById('myid').getElementsByTagName('div');
or if you remove all the extra white space within the myid element by simple:
document.getElementsById('myid').childNodes
EDIT beetle edited his replay behind by back