[Project_owners] Getting XBL-described Textbox Reference

basic basic at mozdev.org
Wed Sep 15 14:36:29 EDT 2004


Bradley E. Rintoul wrote:
> I need to set the value of a textbox described in XBL in Javascript. 
> The Javascript is "normal" javascript and not within an XBL-defined
> element.
> 
> Formerly, I could do something like this:
> 
> var textB = document.getElementById( "textboxInQuestion" );
> textB.value = "desired value";
> 
> But now I cannot.
> 
> Do I need to use getAnonymousElement type of stuff?  Does anyone know
> how to do this?
try textB = document.getAnonymousElementByAttribute(elementBoundTo,'id','textboxInQuestion');
note that elementBoundTo is the element the xbl binding is bound to.

--
basic


More information about the Project_owners mailing list