title: Photoshop Script - Save layers and put into folders with same structure as groups
body: <p>I found an online script which saves each layer as a png/jpeg. It works perfectly, however it does not take photoshop groups into account. I've had a look online and I can't find anything of the sort.</p>
  
  <p>Just to be clear I want to add the features to the script so it still saves each layer as a png but also places the layers into folders, in the same layout that they are in their groups in the application.</p>
  
  <p>Here is the SaveLayers.jsx script I currently have:</p>
  
  <pre><code>https://www.dropbox.com/s/uog82udqd6c2pwj/SaveLayers.jsx
  </code></pre>
  
  <p>Not sure if it's possible but thanks in advance.
  By the way I have hardly any knowledge of javascript.</p>