title: Create HTML table from server side
body: <p>I have stored my tags in the SQL Server database,
  TABLE NAME: Tags
  COLUMNS</p>
  
  <ul>
  <li>TagID</li>
  <li>TagName</li>
  <li>TagURL</li>
  </ul>
  
  <p>Now I want to create a list like below in the aspx page, created from the database. I have done the work of keeping all the tags and tagURL from the database in a dataset. But I have no idea how to create dynamic HTML list or asp.net list from database.</p>
  
  <p>I have to create list like this:</p>
  
  <pre><code>&lt;ul&gt;
              &lt;li class="tag1"&gt;&lt;a href="#"&gt;Lorem ipsum&lt;/a&gt;&lt;/li&gt; 
              &lt;li class="tag2"&gt;&lt;a href="#"&gt;Dolor sit amet&lt;/a&gt;&lt;/li&gt;
  
              &lt;li class="tag3"&gt;&lt;a href="#"&gt;Consectetur adipiscing elit&lt;/a&gt;&lt;/li&gt;
              &lt;li class="tag2"&gt;&lt;a href="#"&gt;Proin &lt;/a&gt;&lt;/li&gt;
              &lt;li class="tag4"&gt;&lt;a href="#"&gt;Sagittis libero&lt;/a&gt;&lt;/li&gt;
              &lt;li class="tag1"&gt;&lt;a href="#"&gt;Aliquet augue&lt;/a&gt;&lt;/li&gt;
              &lt;li class="tag1"&gt;&lt;a href="#"&gt;Quisque dui lacus&lt;/a&gt;&lt;/li&gt;
              &lt;li class="tag5"&gt;&lt;a href="#"&gt;Consequat&lt;/a&gt;&lt;/li&gt;
  
              &lt;li class="tag2"&gt;&lt;a href="#"&gt;Dictum non&lt;/a&gt;&lt;/li&gt;
              &lt;li class="tag1"&gt;&lt;a href="#"&gt;Venenatis et tortor&lt;/a&gt;&lt;/li&gt;
              &lt;li class="tag3"&gt;&lt;a href="#"&gt;Suspendisse mauris&lt;/a&gt;&lt;/li&gt;
              &lt;li class="tag4"&gt;&lt;a href="#"&gt;In accumsan &lt;/a&gt;&lt;/li&gt;
              &lt;li class="tag1"&gt;&lt;a href="#"&gt;Egestas neque&lt;/a&gt;&lt;/li&gt;
              &lt;li class="tag5"&gt;&lt;a href="#"&gt;Mauris eget felis&lt;/a&gt;&lt;/li&gt;
  
              &lt;li class="tag1"&gt;&lt;a href="#"&gt;Suspendisse&lt;/a&gt;&lt;/li&gt;
              &lt;li class="tag2"&gt;&lt;a href="#"&gt;condimentum eleifend nulla&lt;/a&gt;&lt;/li&gt;
          &lt;/ul&gt;
  </code></pre>
  
  <p>Where</p>
  
  <pre><code>&gt;  class="tag &lt;random number from 1-5&gt;"
  </code></pre>