title: JQuery prettyPhoto - open gallery from a link that's not an image
body: <p>I'm using the JQuery prettyPhoto lightbox clone, and it works great, but I have one small issue.</p>
  
  <p>All images have the following format:</p>
  
  <pre><code>&lt;a href='imageURL' rel='prettyPhoto[gallery1]'&gt;&lt;img src='imageURL' style='height:100px;' title='photoname' /&gt;&lt;/a&gt;
  </code></pre>
  
  <p>I have 4 images showing and another 10 hidden using a <code>&lt;div&gt;</code> with <code>style='display:none;'</code>. Clicking any of the 4 images opens the gallery, showing all 14 photos. That's fine.</p>
  
  <p>But I also need to have a link saying 'view all 14 photos' that, when clicked, opens the gallery. Now, if I don't give <code>&lt;a href='imageURL'&gt;</code> to the text link, it doesn't work. But if I link it to, for example, the first image, then that image is shown twice in the gallery. How can I avoid that?</p>
  
  <p>I thought about linking the text link to one of the hidden images instead, but that's not a solution, since the 4 visible images are randomly chosen using PHP.</p>