|
Posted by Erwin Moller on 05/19/06 18:33
Luke wrote:
> Hi Erwin!
>
Hi Luke,
> You said "poor design". Did you mean HTML design out our
> precess/workflow design?
Both I guess.
Imagine you could set up this system from scratch: Would you have come up
with what you have on your hands now?
Probably not. You would design a nice database where all possible answers
would be stored for all different questiontypes (radio, text, check, etc)
in such a way you can easily retrieve them.
But I do not know how this is implemented at the moment, you only told us
about the HTML-mess, not about the database that stores the answers/values.
> How would you approach this problem (1000elements, editable)?
I wouldn't: Weekend starting now. :P
Seriously, I would be extremely tempted to discuss the situation with the
owners of the system and suggest a complete redesign.
If that is impossible, well, my (wild) guess is that a serversidesolution is
most attractive, but you'll have to come up with some smart
routines/regexpr/whatever that will:
1) find all elementtypes in the form
2) Retrieve their values from a database.
3) insert the right code in the HTML at the right place.
This might be easy for:
<input type="text" name="firstName" value="">
but for options in a selectbox, you'll have to traverse through them and
insert SELECTED at the right places.
This will become increasingly difficult if the HTML is all screwed up
because it was generated by WYSIWYG and drag and drop like programs.
Sounds like something that could give you a good headache, but it is of
course possible (if all the HTML is legal).
Alternatively, why not start thinking from the backend, the database?
You have a databse that stores the value/selections/etc.
Maybe it is easier to create a basic template that is based on that.
Of course you would loose all your HTML-layout and fall back to a general
presentationtype.
>
>> Is this right?
>
> Yes!
>
> As for AJAX. I read about it and played with it for a while. However I
> don't think that this would be a good solution here. I agree with you
> that this would be extremely slow. And when would I call this function?
> On page OnLoad? Also, we usually have a "reset" button which cancel all
> changes made /easy to mess up with 1000 elements on a form/. With AJAX
> this button would have to send another 1000 requests to go back to
> defaults.
>
> Frankly, I would prefer a server side solution. Still believe someone
> may have a great idea. Waiting!
>
> Regards,
> Luke
Best of luck, Luke.
Maybe somebody comes up with a briliant solution in the weekend. :-)
Regards,
Erwin Moller
Navigation:
[Reply to this message]
|