My company has a database-driven system of web forms, each of which 
consists of many questions in various layouts (2-column radio, 1 
column checkbox, etc). The forms are never hard-coded. Each HTTP 
request causes Java code to perform DB queries to dynamically 
generate the various questions and answers. Those questions are then 
rendered through JSP and Struts tiles into HTML. 

The HTML also contains JavaScript functions to hide/show conditional 
questions on the web page based on answers to earlier questions. 

Now we're trying to figure out the best way to adapt this system to 
use a Flash front-end instead of HTML/JavaScript. 

My preliminary research suggests at least two possible approaches:

1. A pre-compiled SWF could send a request with certain parameters, 
and the server could respond with an XML description of the form to 
build. Then the SWF could parse that XML and dynamically generate 
the form using attachMovie for each form element (with a lot of math 
to determine relative positions of elements with variable sizes, 
like text labels). 

2. Flex might reduce the code for placing elements, by using MXML to 
describe the form structure as well as visual arrangement. I haven't 
used this yet, and I'm wary of Flex 2 simply because it requires 
Flash Player 9 which is only at 50% browser penetration 
(http://blog.flashforwardconference.com/2006/09/12/adobe-keynote-
some-highlights/) but I might try an earlier version of Flex if it 
helps. 

Does anyone have a suggestion about the best approach to solving 
this problem? 

Thanks in advance for any advice.





--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/flexcoders/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http://groups.yahoo.com/group/flexcoders/join
    (Yahoo! ID required)

<*> To change settings via email:
    mailto:[EMAIL PROTECTED] 
    mailto:[EMAIL PROTECTED]

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 

Reply via email to