title: How to open a file within pyramid for reading?
body: <p>I have a typical Pyramid web application setup. The application directory (I don't know what this directory is called in Pyramid?) contains the static, templates and <strong>ini</strong>.py files. In this directory I also created a directory called <code>static_content</code> that I use to store some special report templates. </p>
  
  <p>In my view code I am using something like this to read the files in the sub-directories of the <code>static_content</code> directory:</p>
  
  <pre><code>f = open("/static_content/abc/report_template.tpt" , "r")
  </code></pre>
  
  <p>Then over in my <strong>init</strong>.py file I added a line:</p>
  
  <pre><code>config.add_static_view("static_content", "static_content")
  </code></pre>
  
  <p>I get an IO Error.....how do I fix this?</p>
  
  <p>Regards,
  Mark Huang</p>