From f4bffff49b7eac4e1936344d6dd8fa4d5df8f2b4 Mon Sep 17 00:00:00 2001 From: Ted Trask Date: Mon, 12 Jan 2009 20:34:27 +0000 Subject: Modified several pages to replace contenteditable with readonly. Added readonly to html.lsp and .css files. git-svn-id: svn://svn.alpinelinux.org/acf/core/trunk@1676 ab2d0c66-481e-0410-8bed-d214d4d58bed --- app/acf-util/password-html.lsp | 2 +- app/acf-util/roles-editrole-html.lsp | 2 +- lib/html.lua | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/app/acf-util/password-html.lsp b/app/acf-util/password-html.lsp index dca559d..faf8e44 100755 --- a/app/acf-util/password-html.lsp +++ b/app/acf-util/password-html.lsp @@ -17,7 +17,7 @@ io.write("") end -- If not in newuser action, disable userid if pageinfo.action ~= "newuser" then - form.value.userid.contenteditable = false + form.value.userid.readonly = true end local order = { "userid", "username", "roles", "password", "password_confirm" } displayform(form, order) diff --git a/app/acf-util/roles-editrole-html.lsp b/app/acf-util/roles-editrole-html.lsp index 0a32839..1997a97 100644 --- a/app/acf-util/roles-editrole-html.lsp +++ b/app/acf-util/roles-editrole-html.lsp @@ -10,7 +10,7 @@ displayformstart(form, page_info) -- If editing existing role, disable role if page_info.action ~= "newrole" then - form.value.role.contenteditable = false + form.value.role.readonly = true end io.write("
\n") displayformitem(form.value.role, "role") diff --git a/lib/html.lua b/lib/html.lua index a543659..96bf4ad 100644 --- a/lib/html.lua +++ b/lib/html.lua @@ -92,7 +92,7 @@ local generic_input = function ( field_type, v ) for i,k in ipairs ( { "name", "size", "checked", "maxlength", "value", "length", "class", "id", "src", - "align", "alt", "contenteditable", + "align", "alt", "contenteditable", "readonly", "tabindex", "accesskey", "onfocus", "onblur" } ) do str = str .. nv_pair ( k, v[k] ) @@ -120,7 +120,7 @@ form.longtext = function ( v ) for i,k in ipairs ( { "name", "rows", "cols", "class", "id", "tabindex", "accesskey", - "onfocus", "onblur" + "onfocus", "onblur", "readonly" } ) do str = str .. nv_pair ( k, v[k] ) end -- cgit v1.2.3