<snip> Question 1. if my writeHTML() method returns HTML with struts tags will, the struts tags be evaluated properly. </snip>
No of course not. <snip> My problem is this. I can create a java class for each attribute that i need to use and my class can have a method such as "writeHTML()" which returns HTML text to display the attribute on a web page. </snip> Create a bean for each. Use taglibs and iteration etc... to display. If this results in a complicated tag structure needed to output the stuff then write your own tag that does what you would have done in writeHtml(), or alternatively look into using the tile extension. -----Original Message----- From: news [mailto:[EMAIL PROTECTED] Behalf Of sjones Sent: Wednesday, 4 June 2003 21:16 To: [EMAIL PROTECTED] Subject: Struts View (JSP's -vs-Servlets) I am writing an application that will Access an LDAP Directory Server The directory has many, many attributes and an attribute may be a single element or an array of elements. Using an entry of the type- employee we have this example. Example: A phone number attribute will store as many phone numbers as needed. Cost Center element will always have just a single value. My problem is this. I can create a java class for each attribute that i need to use and my class can have a method such as "writeHTML()" which returns HTML text to display the attribute on a web page. In doing this, I don't have to code the HTML tag for this on every page in my web app that needs to display this attribute. I can simply call the writeHTML method from the class and have the same code throught the APP. It would seem to me that a servlet is a better choice for implmenting a view. Question 1. if my writeHTML() method returns HTML with struts tags will, the struts tags be evaluated properly. Question 2 can u do this in a JSP page: <%= "<html:text property=\"" + fld_nme + "\" " + " value=\"" + fld_val + "\">"; %> --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]