Things have gotten a bit more complicated... as they tend to do with contracting jobs... =P
The initial functional specification defined that all calendar events have the same elements; start-date, end-date, description, etc... But this is now changing and events can have different elements based on what type of event they are; a conference event will have a "register-by" element while a web announcement event will not. This means we will need a separate XSLT for each of the different event types to transform the XML into HTML.
Now I have some ideas how this might be done but wanted to see what everyone here thought about them and see if anyone can offer some alternate solutions.
- One way is to have an XSLT handler that would look at each of the events type element and, based on the value, call out a named XSLT template to handle the rendering. I'm kind of leaning towards this solution as it keeps everything in XSLT.
- Another way is to have a JSP be the handler and call out different XSLT based on the events type. Not my favorite solution as we would have to parse the XML in the JSP and then parse it again in the XSLT.
Thanks for your help! - John
