From: Thomas 'PointedEars' Lahn on 16 Nov 2009 07:22 mirek wrote: > On 13 Lis, 19:26, Martin Honnen <mahotr...(a)yahoo.de> wrote: >> What is it exactly that you want to read out? The id attribute value of >> the first input element in the form? >> >> That could be done as follows: >> >> var variable = "<form name='formABC' method='POST'>"+ >> "<input type='text' id='nameABC'>"+ >> "</form>"; >> >> var div = document.createElement('div'); >> div.innerHTML = variable; >> >> var input = >> div.getElementsByTagName('form')[0].getElementsByTagName('input')[0]; >> if (input != null) { >> alert(input.id); >> >> } >> [...] > > Thank U very much. InnerHtml is the answer 4 my question :) You mistyped "the cause of my future problems" only slightly. This is not an Internet chat. And trim your quotes. <http://jibbering.com/faq/#posting> PointedEars -- Prototype.js was written by people who don't know javascript for people who don't know javascript. People who don't know javascript are not the best source of advice on designing systems that use javascript. -- Richard Cornford, cljs, <f806at$ail$1$8300dec7(a)news.demon.co.uk>
First
|
Prev
|
Pages: 1 2 Prev: using a general browser as a form-based capture method Next: What is a software engineer? |