Answers.Body: <p>Set <a href="http://buildwithcraft.com/docs/config-settings#generateTransformsBeforePageLoad" rel="nofollow">generateTransformsBeforePageLoad</a> in your config/general.php file.</p>
  
  <pre><code>'generateTransformsBeforePageLoad' =&gt; true,
  </code></pre>
  
  <blockquote>
    <p>Configures Craft to generate new image transforms right when getUrl()
    is called, rather than when the browser first requests the image.</p>
  </blockquote>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2015-04-24T05:00:35.423Z
Answers.LastActivityDate: 2015-04-24T05:00:35.423Z
Answers.UserDisplayName: Eli Peters
Body: <p>Im creating a gallery for Fancybox and only wish to show the first image. The rest are hidden in a container and only referenced so that Fancybox can call on these latter. I've tried two approaches: anchor tag with and without the image tag.</p>
  
  <p>I am sure that this is a recent change as I have been using this technique on earlier craft versions and gettting good results.</p>
  
  <pre><code>&lt;div class="hide"&gt;
    &lt;a title="{{ image.title }}" href="{{ image.getUrl('wide') }}" class="fb" rel="fb-{{ ind }}"&gt;
      &lt;img src="{{ image.getUrl('wide') }}" title="{{ image.title }}" style="display: block!important" /&gt;
    &lt;/a&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>The image is generated but it looks like in a temporary location "...cpresources/transforms..." to which Fancybox doesn't recognise.</p>
  
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2015-04-23T23:45:30.700Z
Comments.Text: Just found the answer from an old colleague http://craftcms.stackexchange.com/questions/8712/cache-coldcache-checking-for-ungenerated-image-transforms/8713#8713
Comments.UserDisplayName: Eli Peters
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2015-04-24T02:48:00.093Z
Comments.Text: Wanna add that as an official answer, Eli?
Comments.UserDisplayName: Brad Bell
Tags: <image-transforms>
Title: Why does asset creation not work for hidden images?
ThreadText: # Why does asset creation not work for hidden images?
  
  (Asked by: username_0 on 2015-04-23)
  
  Im creating a gallery for Fancybox and only wish to show the first image. The rest are hidden in a container and only referenced so that Fancybox can call on these latter. I've tried two approaches: anchor tag with and without the image tag.
  
  I am sure that this is a recent change as I have been using this technique on earlier craft versions and gettting good results.
  
  ```
  <div class="hide">
    <a title="{{ image.title }}" href="{{ image.getUrl('wide') }}" class="fb" rel="fb-{{ ind }}">
      <img src="{{ image.getUrl('wide') }}" title="{{ image.title }}" style="display: block!important" />
    </a>
  </div>
  
  ```
  
  The image is generated but it looks like in a temporary location "...cpresources/transforms..." to which Fancybox doesn't recognise.
  
  **Tags:** image-transforms
  
  > **Comments:**
  > **username_0**: Just found the answer from an old colleague http://craftcms.stackexchange.com/questions/8712/cache-coldcache-checking-for-ungenerated-image-transforms/8713#8713  
  > **username_1**: Wanna add that as an official answer, Eli?  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_0 on 2015-04-24. Score: 2 | Accepted answer
  
  Set [generateTransformsBeforePageLoad](http://buildwithcraft.com/docs/config-settings#generateTransformsBeforePageLoad) in your config/general.php file.
  
  ```
  'generateTransformsBeforePageLoad' => true,
  
  ```
  
  > Configures Craft to generate new image transforms right when getUrl()
  > is called, rather than when the browser first requests the image.
  
  
  ---
  
  