Hallo.
Ich möchte, dass der Benutzer irgendwo ausserhalb des Textfeldes hinklickt und der Cursor automatisch ans Ende des Textes im Textfeld springt. Geht das irgendwie?
Versuch mal das hier:
---------------------
<form>
<textarea cols="80" rows="30">1. Zeile
2. Zeile
3. Zeile
Cursor -> </textarea>
</form>
<script type="text/javascript">
<!--
function fo()
{
document.forms[0].elements[0].focus();
document.forms[0].elements[0].value = document.forms[0].elements[0].value;
}
document.onclick = fo;
//-->
</script>
Funktioniert aber nicht in allen Browsern.
Gruß
Norbert