QFC Back/Next buttons driving me crazy

From: Date: Thu, 02 Jun 2005 17:41:33 +0000
Subject: QFC Back/Next buttons driving me crazy
Groups: php.pear.general 
Request: Send a blank email to pear-general+get-19442@lists.php.net to get a copy of this message
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 I've determined that trying to build a modern user interface out of HTML is like trying to make a bookshelf out of mashed potatoes[0]-- it was never designed for that. QF/QFC is a tremendous help in some ways, but makes other things (like weird workarounds) much more difficult and complicated. In western cultures where we read left-to-right, nav buttons should be in the order [<< Back] [Next >>] . And QFC wants both of the buttons to be Submit buttons. OK fine. Problem is, when users hit "enter" to go to the next page, the BACK button gets triggered, because it is first, and browsers seem to insist on that. Auugh. I have $page->setDefaultAction('next'). The hidden qf_default is getting passed correctly through in the submitvalues all right, but the browser is also explicitly sending the BACK action, so QFC is ignoring the hidden default action. So instead I tried making the BACK button a 'button', not a 'submit'. Some browsers are OK with that, others do stupid things like submit BOTH buttons on enter. And guess which button QFC heeds? The one that comes first: BACK. Gah. I found a nifty article (http://volition.vee.net/archives/000498.html) which suggests using CSS2 to assign a style "direction: rtl;" attribute to reverse the order of the buttons on display; thus I can have them in the code in the order the browser wants to see, but the user will see them in a sane order. Pretty slick. So I tried assigning a style or class attribute to the group that has my nav buttons. Maybe I'm missing something, but addGroup doesn't take attributes, nor does $group->updateAttributes() seem to work. So, what do I have to do? Subclass the group element and manually jack with the renderer to wrap a div around the group with the rtl direction? That seems like a crazily complicated hack to do something which should be the default behaviour. I can't be the first person to have run into this. Maybe I'm missing something obvious and I'm just too frustrated to see what it is. - -ken - -- - --------------- The world's most affordable web hosting. http://www.nearlyfreespeech.net [0] Apologies to jwz. -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.0 (GNU/Linux) iD8DBQFCn0TNe8HF+6xeOIcRAu/ZAKDG6DREDrhI7l8jfGEB0AIqZv1FqACgpi5J sDsDsAmOpXRWEFiQdwnPzao= =/wze -----END PGP SIGNATURE-----

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