title: GWT and JSR-168/286 portlet namespace?
body: <p>We are developing a set of portlets for Liferay.  Currently we use JSPs, so we are able to use the  tag for the DIV and element IDs so that they are unique on the page, even if multiple instances of the same portlet appear on the page; for example:  </p>
  
  <pre><code>&lt;div id='&lt;portlet:namespace/&gt;div'&gt;  
  &lt;form&gt;
      Enter your name here: &lt;input type='text' id='&lt;portlet:namespace/&gt;name'/&gt;  
  &lt;/form&gt;  
  &lt;/div&gt;  
  </code></pre>
  
  <p>Now we'd like to try building the portlets with GWT instead of JSP.  Any examples I find of GWT portlets (of which there are only a couple) don't solve the "how do I assign unique IDs to the div and elements" problem, since GWT seems to be pre-compiled into Javascript before the IDs are ever generated.  Any idea on how to incorporate the portlet's namespace into the div/element IDs?</p>