title: how to use fancybox with mvc3 and pictures stored in database
body: <pre><code>&lt;a href="@Url.Action("ShowPicture", "Pictures", new { id = Model.Pictures[i].PictureId })" title="lala" rel="image_group"&gt;
                  &lt;img src="@Url.Action("ShowPicture", "Pictures", new { id = Model.Pictures[i].PictureId })" width="200px" alt=""/&gt;
              &lt;/a&gt;
  </code></pre>
  
  <p>when i open link theh i can see picture</p>
  
  <p><a href="http://www.shrani.si/f/1N/77/2nh6icYN/2.png" rel="nofollow">http://www.shrani.si/f/1N/77/2nh6icYN/2.png</a></p>
  
  <p>but if i use fancybox then i usee</p>
  
  <p><a href="http://www.shrani.si/f/1g/Ka/4FZT4Kf6/1.png" rel="nofollow">http://www.shrani.si/f/1g/Ka/4FZT4Kf6/1.png</a></p>
  
  <p>i am reading picture from database. How to us efancybox with mvc and pictures stored in database</p>
  
  <p>Puicture controller:</p>
  
  <pre><code>public ActionResult ShowPicture(int id)
          {
              ShowPictureModel model = new PictureManager().GetShowPictureModel(id);
              return File(model.Bytes, model.ContentType);
          }
  </code></pre>