From 1f07ec78de62c18573c1ae8361729b8122ee7280 Mon Sep 17 00:00:00 2001 From: Alexey Verkhovsky Date: Sun, 13 Nov 2005 17:48:21 +0000 Subject: [PATCH] Put cursor in the text area when opening wiki/edit --- app/views/wiki/edit.rhtml | 3 ++- app/views/wiki/new.rhtml | 1 + 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/app/views/wiki/edit.rhtml b/app/views/wiki/edit.rhtml index 270d5bec..0da5eb6f 100644 --- a/app/views/wiki/edit.rhtml +++ b/app/views/wiki/edit.rhtml @@ -14,7 +14,7 @@ %>

- +

as @@ -35,4 +35,5 @@ function cleanAuthorName() { document.getElementById('authorName').value = 'AnonymousCoward'; } } +document.forms["editForm"].elements["content"].focus(); diff --git a/app/views/wiki/new.rhtml b/app/views/wiki/new.rhtml index e7a73bca..fcc6d565 100644 --- a/app/views/wiki/new.rhtml +++ b/app/views/wiki/new.rhtml @@ -30,4 +30,5 @@ function cleanAuthorName() { document.getElementById('authorName').value = 'AnonymousCoward'; } } +document.forms["editForm"].elements["content"].focus();