title: Adding content to a div in HTML using GWT
body: <p>I am pretty new to GWT, and I have these dynamic divs setup on my starting GWT html page:</p>
  
  <pre><code>&lt;div id="nav"&gt;
  Navigation goes here...
  &lt;/div&gt;
  
  &lt;div id="core"&gt;
  &lt;/div&gt;
  
  &lt;div id="footer"&gt;
  footer info goes here
  &lt;/div&gt;
  </code></pre>
  
  <p>I have my main class that implements EntryPoint and ValueChangeHandler to dynamically change the "core" div so it renders different information based on what the user clicks on the main page (so it mimicks using different pages, but only using one through History and Hyperlink classes <a href="https://stackoverflow.com/a/1063523">Like this</a>). I tried doing this with something like:</p>
  
  <pre><code>        VerticalPanel panel = new VerticalPanel();
          HTML mapHtmlDiv = new HTML("&lt;div id=\"maps\"&gt;&lt;/div&gt;");
          panel.add(mapHtmlDiv);
          RootPanel.get("core").add(panel);
          // add a widget to the maps div downstream
  </code></pre>
  
  <p>Once the condition is met. However this is not allowed on GWT, as it throws an error along the lines of "A widget that has an existing parent widget may not be added to the detach list", what is the correct way of adding content and divs to HTML?</p>