Hi, wie der Titel schon sagt:
<div>
<p>
<input type="file" name="file_ar[]" />
<button onclick="alert(this.parentNode.lastChild.nodeName);">TEST</button>
<h5>rgreg</h5>
</p>
</div>
Während das ganze Beispiel mit firstChild problemlos funktioniert:
<div>
<p>
<input type="file" name="file_ar[]" />
<button onclick="alert(this.parentNode.firstChild.nodeName);">TEST</button>
<h5>rgreg</h5>
</p>
</div>
Woran liegts?
Timo