title: Python and displaying HTML
body: <p>I've gotten pretty comfortable with Python and now I'm looking to make a rudimentary web application.  I was somewhat scared of Django and the other Python frameworks so I went caveman on it and decided to generate the HTML myself using another Python script.  </p>
  
  <p>Maybe this is how you do it anyways - but I'm just figuring this stuff out.  I'm really looking for a tip-off on, well, what to do next.  </p>
  
  <p>My Python script PRINTS the HTML (is this even correct? I need it to be on a webpage!), but now what?</p>
  
  <p>Thanks for your continued support during my learning process.  One day I will post answers!</p>
  
  <p>-Tyler </p>
  
  <p>Here's my code:</p>
  
  <pre><code>from SearchPhone import SearchPhone
  
  phones = ["Iphone 3", "Iphone 4", "Iphone 5","Galaxy s3", "Galaxy s2", "LG Lucid", "LG Esteem", "HTC One S", "Droid 4",
            "Droid RAZR MAXX", "HTC EVO", "Galaxy Nexus", "LG Optimus 2", "LG Ignite",
            "Galaxy Note", "HTC Amaze", "HTC Rezound", "HTC Vivid", "HTC Rhyme", "Motorola Photon",
            "Motorola Milestone", "myTouch slide", "HTC Status", "Droid 3", "HTC Evo 3d", "HTC Wildfire",
            "LG Optimus 3d", "HTC ThunderBolt", "Incredible 2", "Kyocera Echo", "Galaxy S 4g",
            "HTC Inspire", "LG Optimus 2x", "Samsung Gem", "HTC Evo Shift", "Nexus S", "LG Axis", "Droid 2",
            "G2", "Droid x", "Droid Incredible" 
            ]
  
  print """&lt;!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"&gt;
  &lt;html xmlns="http://www.w3.org/1999/xhtml"&gt;
  &lt;head&gt;
  &lt;meta http-equiv="Content-Type" content="text/html; charset=utf-8" /&gt;
  &lt;title&gt;table of phones&lt;/title&gt;
  &lt;/head&gt;
  
  &lt;body&gt;
  &lt;/body&gt;
  &lt;/html&gt;
  """
  
  #table
  print '&lt;table width="100%" border="1"&gt;'
  for x in phones:
      y = SearchPhone(x)
      print "\t&lt;tr&gt;"
      print "\t\t&lt;td&gt;" + str(y[0]) + "&lt;/td&gt;"
      print "\t\t&lt;td&gt;" + str(y[1]) + "&lt;/td&gt;"
      print "\t\t&lt;td&gt;" + str(y[2]) + "&lt;/td&gt;"
      print "\t\t&lt;td&gt;" + str(y[3]) + "&lt;/td&gt;"
      print "\t\t&lt;td&gt;" + str(y[4]) + "&lt;/td&gt;"
      print "\t&lt;/tr&gt;"
  print "&lt;/table&gt;"
  </code></pre>