title: Fancybox to open a text file?
body: <p>I wanted to make a website where i can preview with FancyBox files of some kind of types, like for example, images, text documents, etc.</p>
  
  <p>Doing this:</p>
  
  <pre><code>$(".text").fancybox();
  
  &lt;a class="text" href="document.css" title="document.css"&gt;&lt;img src="files.png"/&gt;OPEN ME&lt;/a&gt;
  </code></pre>
  
  <p>It opens the Document but it doesnt respect the margins and format of the document, i mean, everything is written in the same line, cause i suppose it opens it as if it would be an HTML, not as an Text Editor.</p>
  
  <p>So does anybody how to open it in the way Notepad++ or GEdit, for example, opens it?</p>
  
  <p>Thanks!</p>