title: When storing Images in the File System, Use relative paths or absolute paths?
body: <p>I am working on a web app and I decided (after reading many post on SO) to store the actual images in the file system and to store the metadata in the DB.</p>
  <p>Should I store a relative path or an absolute path.</p>
  <p>I can think of some advantages for each of the choices.</p>
  <p><strong>Absolute:</strong></p>
  <p><em>Pros:</em></p>
  <p>It is obvious where the file is even to other apps reading the DB<br />
  Can put the photos anywhere on the drive (would require an handler)</p>
  <p><em>Cons:</em></p>
  <p>Need to convert the absoulte path to a relative path for use in the site or create a handler<br />
  If I migrate to another server I may have to change all the paths</p>
  <p><strong>Relative:</strong></p>
  <p><em>Pros:</em></p>
  <p>Simply add the link to the html and it works</p>
  <p><em>Cons:</em></p>
  <p>If I change the app root I have to move the pictures or change all the paths<br />
  Have to put the pictures in a public directory (Or I gain nothing over the absolute path)</p>
  <p>Ok these are some of things going on in my head right now.</p>
  <p>I can't decide.</p>