Thread overview |
---|
March 19, 2008 HTMLayout, how to get elementText of plaintext, ping bobef | ||||
---|---|---|---|---|
| ||||
It's too slowly to open dsource form from China this time, so I ask here :) get user changed value of input control, just element.elementText, but how to get user changed value of plaintext control ? I tried methods below, all failed: elePlaintext.attribute("value")); //old value elePlaintext.elementText); //nothing ? elePlaintext.innerText); //nothine ? elePlaintext.innerHTML); //old value elePlaintext.outerHTML); //old value -- yidabu <yidabu.nospam@gmail.com> D语言 中文支持(D Chinese Support) http://www.d-programming-language-china.org/ http://bbs.d-programming-language-china.org/ http://dwin.d-programming-language-china.org/ http://scite4d.d-programming-language-china.org/ |
March 19, 2008 Re: Got it | ||||
---|---|---|---|---|
| ||||
Posted in reply to yidabu | just: (*plaintext.value).toString On Wed, 19 Mar 2008 20:43:05 +0800 yidabu <yidabu.nospam@gmail.com> wrote: > > It's too slowly to open dsource form from China this time, so I ask here :) > > get user changed value of input control, just element.elementText, but how to get user changed value of plaintext control ? > > I tried methods below, all failed: > > elePlaintext.attribute("value")); //old value > elePlaintext.elementText); //nothing ? > elePlaintext.innerText); //nothine ? > elePlaintext.innerHTML); //old value > elePlaintext.outerHTML); //old value > > > -- > yidabu <yidabu.nospam@gmail.com> > D语言 中文支持(D Chinese Support) > http://www.d-programming-language-china.org/ > http://bbs.d-programming-language-china.org/ > http://dwin.d-programming-language-china.org/ > http://scite4d.d-programming-language-china.org/ -- yidabu <yidabu.nospam@gmail.com> D语言 中文支持(D Chinese Support) http://www.d-programming-language-china.org/ http://bbs.d-programming-language-china.org/ http://dwin.d-programming-language-china.org/ http://scite4d.d-programming-language-china.org/ |
March 27, 2008 Re: Got it | ||||
---|---|---|---|---|
| ||||
Posted in reply to yidabu | Sorry, I wasn't around :)
I use elePlaintext.innerText usually. It works fine for me. Your solution is also fine, but it uses the JSON structure.
yidabu Wrote:
> just:
> (*plaintext.value).toString
>
> On Wed, 19 Mar 2008 20:43:05 +0800
> yidabu <yidabu.nospam@gmail.com> wrote:
>
> >
> > It's too slowly to open dsource form from China this time, so I ask here :)
> >
> > get user changed value of input control, just element.elementText, but how to get user changed value of plaintext control ?
> >
> > I tried methods below, all failed:
> >
> > elePlaintext.attribute("value")); //old value
> > elePlaintext.elementText); //nothing ?
> > elePlaintext.innerText); //nothine ?
> > elePlaintext.innerHTML); //old value
> > elePlaintext.outerHTML); //old value
> >
> >
> > --
> > yidabu <yidabu.nospam@gmail.com> DÓïÑÔ¡¡ÖÐÎÄÖ§³Ö(D Chinese Support) http://www.d-programming-language-china.org/ http://bbs.d-programming-language-china.org/ http://dwin.d-programming-language-china.org/ http://scite4d.d-programming-language-china.org/
>
>
> --
> yidabu <yidabu.nospam@gmail.com> DÓïÑÔ¡¡ÖÐÎÄÖ§³Ö(D Chinese Support) http://www.d-programming-language-china.org/ http://bbs.d-programming-language-china.org/ http://dwin.d-programming-language-china.org/ http://scite4d.d-programming-language-china.org/
|
March 30, 2008 Re: Got it | ||||
---|---|---|---|---|
| ||||
Posted in reply to bobef | Thanks! bobef, HTMLayout is a wonderful library, the only problem seems documentiations and examples, e.g. how to get or set element value, I can not understand that some times some methods work fine, but some times failed. On Thu, 27 Mar 2008 08:17:27 -0400 bobef <bobef@abv-nospam.bg> wrote: > Sorry, I wasn't around :) > > I use elePlaintext.innerText usually. It works fine for me. Your solution is also fine, but it uses the JSON structure. > > yidabu Wrote: > > > just: > > (*plaintext.value).toString > > > > On Wed, 19 Mar 2008 20:43:05 +0800 > > yidabu <yidabu.nospam@gmail.com> wrote: > > > > > > > > It's too slowly to open dsource form from China this time, so I ask here :) > > > > > > get user changed value of input control, just element.elementText, but how to get user changed value of plaintext control ? > > > > > > I tried methods below, all failed: > > > > > > elePlaintext.attribute("value")); //old value > > > elePlaintext.elementText); //nothing ? > > > elePlaintext.innerText); //nothine ? > > > elePlaintext.innerHTML); //old value > > > elePlaintext.outerHTML); //old value -- yidabu <yidabu.nospam@gmail.com> D语言 中文支持(D Chinese Support) http://www.d-programming-language-china.org/ http://bbs.d-programming-language-china.org/ http://dwin.d-programming-language-china.org/ http://scite4d.d-programming-language-china.org/ |
March 31, 2008 Re: Got it | ||||
---|---|---|---|---|
| ||||
Posted in reply to yidabu | > the only problem seems documentiations and examples I know, but I am not likely to write documentation. That's where the original documentation comes in handy. One needs to be familiar with HTMLayout anyway... > how to get or set element value, I can not understand that some times some methods work fine, but some times failed. Well this is because of how HTMLayout works. Generally you you HElement.value for elements like <input> and <select> and for normal elements like <div> <etc> you use the (inner/outer)(HTML/Text) methods. Sometimes you can use these for inputs as well. yidabu Wrote: > > Thanks! bobef, HTMLayout is a wonderful library, the only problem seems documentiations and examples, e.g. how to get or set element value, I can not understand that some times some methods work fine, but some times failed. > > > On Thu, 27 Mar 2008 08:17:27 -0400 > bobef <bobef@abv-nospam.bg> wrote: > > > Sorry, I wasn't around :) > > > > I use elePlaintext.innerText usually. It works fine for me. Your solution is also fine, but it uses the JSON structure. > > > > yidabu Wrote: > > > > > just: > > > (*plaintext.value).toString > > > > > > On Wed, 19 Mar 2008 20:43:05 +0800 > > > yidabu <yidabu.nospam@gmail.com> wrote: > > > > > > > > > > > It's too slowly to open dsource form from China this time, so I ask here :) > > > > > > > > get user changed value of input control, just element.elementText, but how to get user changed value of plaintext control ? > > > > > > > > I tried methods below, all failed: > > > > > > > > elePlaintext.attribute("value")); //old value > > > > elePlaintext.elementText); //nothing ? > > > > elePlaintext.innerText); //nothine ? > > > > elePlaintext.innerHTML); //old value > > > > elePlaintext.outerHTML); //old value > > > -- > yidabu <yidabu.nospam@gmail.com> DÓïÑÔ¡¡ÖÐÎÄÖ§³Ö(D Chinese Support) http://www.d-programming-language-china.org/ http://bbs.d-programming-language-china.org/ http://dwin.d-programming-language-china.org/ http://scite4d.d-programming-language-china.org/ |
Copyright © 1999-2021 by the D Language Foundation