Subclassing a QuickForm element

From: Date: Fri, 18 Feb 2005 05:37:43 +0000
Subject: Subclassing a QuickForm element
Groups: php.pear.general 
Request: Send a blank email to pear-general+get-17563@lists.php.net to get a copy of this message
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 I need to create a subclass of a standard QF text input element that includes a link wiht an onClick which calls some JS to populate the associated element's value with some custom stuff. The best way I can imagine do this is by subclassing the text element, and then overloading the toHTML() method to include my link and overloading the _getJS() method to include my JS. I got this idea from looking at Jamie Alessio's advmultiselect... it seems that's how he does it there. But I can't for the life of me find the original toHTML() method that the text element uses! I've searched through its inheritance, and the only toHTML() method I can find is in HTML_Common, and it's essentially blank (virtual method?). So I guess that's not it. Where would be the toHTML() method of a text element that I should use as a template for my custom text element? - -ken - -- - --------------- The world's most affordable web hosting. http://www.nearlyfreespeech.net -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.0 (GNU/Linux) iD8DBQFCFX8ne8HF+6xeOIcRAqNuAJ4gLKUfNcapMEE6JRDhwfoy0JCuuQCfQOAF 9JUYsDA7NypcFuTho0+bUS4= =kKKB -----END PGP SIGNATURE-----

« previous php.pear.general (#17563) next »