<?xml version='1.0'?>
<feed xmlns:opensearch='http://a9.com/-/spec/opensearch/1.1/' xmlns:s='http://jadedpixel.com/-/spec/shopify' xmlns='http://www.w3.org/2005/Atom'>
<id>
http://vogue.myshopify.com/blogs/weblog
</id>
<title>
Vogue - Weblog
</title>
<author>
<name>
Vogue
</name>
</author>
<link href='http://vogue.myshopify.com/blogs/weblog' rel='self'/>
<link href='http://vogue.myshopify.com/blogs/weblog' rel='alternate'/>
<updated>
2007-08-26 09:17:56 -0600
</updated>
<entry>
<id>
tag:db1@shopify.com,2007:articles/92941
</id>
<title>
RSS 2.0 Feed for Collections
</title>
<summary type='html'>
<![CDATA[<p>Providing your visitors with an <span class="caps">RSS</span> feed subscription is an excellent way to keep them updated with the latest products added to your store. Shopify automatically generates these for blogs, but not for collections. Bummer!</p>


	<p>We can easily create an <span class="caps">RSS 2</span>.0 feed ourselves though with a couple simple steps. It&#8217;s <em>rumored</em> that Shopify may eventually automatically generate feeds for you, but until then we&#8217;ll need to improvise. Let&#8217;s get started.</p>


	<p><strong>Create a Page</strong><br />First thing we need is a blank page. Login into your Shopify admin and follow the steps below&#8230;</p>


	<ol>
	<li>Click the &#8220;Blogs &#38; Pages&#8221; tab</li>
		<li>Press &#8220;Create Blog or Page&#8221; </li>
		<li>Type <strong>RSS</strong> in the form field</li>
		<li>Submit the form (Create new Page)</li>
		<li>Leave the description blank (Write your Page)</li>
		<li>Submit the form (Post Page)</li>
	</ol>


	<p>You&#8217;ve setup the page where the feed will be available, which will be located at <code>http://domain.com/pages/rss</code>. Now let&#8217;s make sure you have a collection with all your products.</p>


	<p><strong>All Products Collection</strong><br />If you don&#8217;t already have a smart collection with all your products setup, we&#8217;ll need that&#8230;</p>


	<ol>
	<li>Click the &#8220;Collections&#8221; tab</li>
		<li>Press &#8220;Create new Collection&#8221; </li>
		<li>Type <strong>All</strong> in the title field</li>
		<li>Click the &#8220;Smart Collection&#8221; radio button</li>
		<li>Set conditions to <em>product price is greater than 0</em></li>
		<li>Submit the form (Create Collection)</li>
	</ol>


	<p>You&#8217;ve just setup a collection that will always contain <strong>all product</strong> in your store that have a price greater than 0. Now let&#8217;s create the actual feed&#8230;</p>


	<p><strong>Generate the Feed</strong><br />This step is a simple copy and paste. Open <code>theme.liquid</code> from the <strong>Look &#38; Feel</strong> tab and add the following block of code before the <span class="caps">FIRST CHARACTER</span> of the file&#8230;</p>


<pre><code>{% case page.handle %}{% when "rss" %}&lt;?xml version="1.0" encoding="utf-8"?&gt;
&lt;rss version="2.0"&gt;
    &lt;channel&gt;
        &lt;title&gt;{{ shop.name }}&lt;/title&gt;
        &lt;link&gt;{{ shop.url }}&lt;/link&gt;
        &lt;description&gt;TYPE A 25-30 WORD DESCRIPTION OF YOUR FEED!&lt;/description&gt;
        &lt;language&gt;en-us&lt;/language&gt;
        &lt;copyright&gt;Copyright {{ "now" | date: "%Y" }} {{ shop.name }}&lt;/copyright&gt;
        {% for product in collections.all.products %}&lt;item&gt;
            &lt;title&gt;{{ product.title }}&lt;/title&gt;
            &lt;link&gt;{{ shop.url }}{{ product.url }}&lt;/link&gt;
            &lt;description&gt;{% for image in product.images limit: 1 %}&amp;lt;p&amp;gt;
            &amp;lt;img src="{{ image | product_img_url: 'medium' }}" 
            alt="{{ product.title }}" /&amp;gt;&amp;lt;/p&amp;gt;{% endfor %}&amp;lt;p&amp;gt;
            &amp;lt;a href="{{ shop.url }}{{ product.url }}"&amp;gt;
            {{ product.title }}&amp;lt;/a&amp;gt;&amp;lt;/p&amp;gt;&amp;lt;p&amp;gt;&amp;lt;strong&amp;gt;
            {{ product.price_min | money }}{% if product.price_varies %} - 
            {{ product.price_max | money }}{% endif %}&amp;lt;/strong&amp;gt;
            &amp;lt;/p&amp;gt;&amp;lt;p&amp;gt;{{ product.description | strip_html | 
            truncate: 300 }}&amp;lt;/p&amp;gt;&lt;/description&gt;
        &lt;/item&gt;
    {% endfor %}&lt;/channel&gt;
&lt;/rss&gt;{% else %}</code></pre>

	<p>Do <span class="caps">NOT</span> move the page content down before pasting the code in. Just paste it and leave the rest trailing your new code. Be sure to replace the capitalized section in the code above with <span class="caps">YOUR</span> feed description. Finally, go to the very end of <code>theme.liquid</code> and add the following closing tag immediately after the <span class="caps">LAST CHARACTER</span>&#8230;</p>


<pre><code>{% endcase %}</code></pre>

	<p>Open your browser and type <code>http://domain.com/pages/rss</code> in the <span class="caps">URL</span> and you should see a fully functional <span class="caps">RSS 2</span>.0 feed! Here&#8217;s the <a href="/pages/rss">sample Vogue feed</a>. While you could be completely finished right now, I prefer to use <a href="http://feedburner.com">Feed Burner</a> to track statistics and enhance the feed with their tools.</p>


	<p><strong>Feed Burner</strong><br />If you choose to use <a href="http://feedburner.com">Feed Burner</a>, simply sign up for an account and use <code>http://domain.com/pages/rss</code> as the <span class="caps">URL</span> they request. You will then be given the opportunity to create your new <span class="caps">URL</span>, which will look something like <code>http://feeds.feedburner/your-feed</code>. Once you have the <span class="caps">URL</span> assigned, place it as a hyperlink somewhere on your site.</p>


	<p>If you&#8217;re using <a href="http://feedburner.com">Feed Burner</a>, paste the following link in any/all of your liquid templates&#8230;</p>


<pre><code>&lt;a href="http://feeds.feedburner.com/your-feed"&gt;Subscribe&lt;/a&gt;</code></pre>

	<p>Alternatively, you could use the feed we created&#8230;</p>


<pre><code>&lt;a href="/pages/rss"&gt;Subscribe&lt;/a&gt;</code></pre>

	<p><strong>Complete</strong><br />That&#8217;s it! Now you have a fully functional, stat tracking <span class="caps">RSS 2</span>.0 feed for all your products!</p>]]>
</summary>
<updated>
2007-08-26 09:17:56 -0600
</updated>
<published>
2007-08-26 09:17:56 -0600
</published>
<author>
<name>
Jared Burns
</name>
</author>
<link href='http://vogue.myshopify.com/blogs/weblog/92941-rss-2-0-feed-for-collections' rel='alternate'/>
</entry>
<entry>
<id>
tag:db1@shopify.com,2007:articles/91391
</id>
<title>
Intelligent Tabbed Navigation
</title>
<summary type='html'>
<![CDATA[<p>Making sure your visitors don&#8217;t get lost in your site is an important role of a web publisher such as yourself. Any site on the web that pays attention to usability uses some variation of <a href="http://en.wikipedia.org/wiki/Breadcrumb_%28navigation%29">breadcrumbs</a> or tabbed navigation. These are great ways to give your visitors a way back to dry land if they get discombobulated.</p>


	<p><img src="http://static0.jadedpixel.com/s/files/1/0001/8021/assets/tabber.png" title="Tabbed Navigation" alt="Tabbed Navigation" /></p>


	<p>Though you may not know it, <strong>Vogue</strong> is already setup for tabbed navigation. You won&#8217;t need to write any <span class="caps">CSS</span> or <span class="caps">XHTML</span>, just some Liquid logic to light the tags up. By the way, this tutorial assumes you&#8217;re using the version of <strong>Vogue</strong> downloaded from this site. Also, the navigation tabs are displayed from your <em>main-menu</em> linklist.</p>


	<p>So, here we go. Open <code>theme.liquid</code> and locate the following block of code&#8230;</p>


<pre><code>&lt;div id="navigation"&gt;
    &lt;ul id="navigate"&gt;{% for link in linklists.main-menu.links %}
        &lt;li&gt;&lt;a href="{{ link.url }}"&gt;{{ link.title }}&lt;/a&gt;&lt;/li&gt;{% endfor %}
    &lt;/ul&gt;
&lt;/div&gt;</code></pre>

	<p><strong>The code to insert is not displaying properly here, possibly due to textile, so you&#8217;ll need to retype the code from the following screenshot&#8230;</strong></p>


	<p><a href="http://static1.jadedpixel.com/s/files/1/0001/8021/assets/tabbed-big.png" rel="lightbox[tabbed]"><img src="http://static1.jadedpixel.com/s/files/1/0001/8021/assets/tabbed.png" alt="Tabbed Navigation Code" /></a></p>


	<p>Each time Shopify iterates through the forloop, our logic checks to see if the next link to be displayed is equal to the page we&#8217;re currently on. If that&#8217;s the case, we add <code>class="current"</code> to the link tag. I&#8217;ve already prepared the styling in the <span class="caps">CSS</span> documents.</p>


	<p>This set of logic covers most all cases &#8211; index, collections, pages, blogs, cart and search. For the blog links, make sure you title the link with the exact name of the blog. All the other pages check <span class="caps">URL</span>&#8217;s so the links can have different names than the page title, collection title, etc.</p>


	<p>That&#8217;s all! Watch those tab&#8217;s tell you where you are.</p>]]>
</summary>
<updated>
2007-08-22 22:53:31 -0600
</updated>
<published>
2007-08-22 22:53:31 -0600
</published>
<author>
<name>
Jared Burns
</name>
</author>
<link href='http://vogue.myshopify.com/blogs/weblog/91391-intelligent-tabbed-navigation' rel='alternate'/>
</entry>
<entry>
<id>
tag:db1@shopify.com,2007:articles/91381
</id>
<title>
Product Tags
</title>
<summary type='html'>
<![CDATA[<p>Displaying tags on the collection page is a piece of cake, but showing them on the product page always tends to baffle people. Thank goodness for the flexibility of <a href="http://liquidmarkup.org">Liquid</a> though, which makes this quite an easy task.</p>


	<p><strong>All Products Collection</strong><br />Before getting into the actual code, we need to create a collection that holds <strong>all</strong> the products. We can accomplish this by creating a <em>smart collection</em> titled <strong>All</strong> with conditions set to <em>product price is greater than 0</em>. Go ahead and do this now by clicking the &#8220;Collections&#8221; tab, then create a new smart collection.</p>


	<p><strong>The Tags</strong><br />Now that we have a way to iterate through all the products, we can easily grab the tags for each product and dynamically show all products containing the specified tag(s) when clicked. Open <code>product.liquid</code> and locate the following code towards the end of the page&#8230;</p>


<pre><code>Browse more {{ product.type | link_to_type }} or additional 
{{ product.vendor | link_to_vendor }} products.</code></pre>

	<p>This would be an ideal place to add the tags, so go ahead an replace the previous code with the following&#8230;</p>


<pre><code>Browse more {{ product.type | link_to_type }}, additional 
{{ product.vendor | link_to_vendor }} products, or items tagged 
{% for tag in product.tags %}
&lt;a href="/collections/all/{{ tag }}"&gt;{{ tag }}&lt;/a&gt;{% unless forloop.last %}, 
{% endunless %}{% endfor %}.</code></pre>

	<p>Save and test it out. That&#8217;s it!</p>]]>
</summary>
<updated>
2007-08-22 22:01:55 -0600
</updated>
<published>
2007-08-22 22:01:55 -0600
</published>
<author>
<name>
Jared Burns
</name>
</author>
<link href='http://vogue.myshopify.com/blogs/weblog/91381-product-tags' rel='alternate'/>
</entry>
<entry>
<id>
tag:db1@shopify.com,2007:articles/91361
</id>
<title>
Continue Shopping...
</title>
<summary type='html'>
<![CDATA[<p>While it&#8217;s great to add an item to the cart, then automatically go to the cart to see what you&#8217;ve put in it, sometimes you&#8217;d prefer to stay at the current product. Essentially, add the product and encourage the customer to continue shopping.</p>


	<p>This post is not a full fledged tutorial about this topic as you can do all kinds of cool stuff with <em>Javascript (AJAX)</em>, this article is intended to give you a quick and easy way to <em>stay put</em> after adding a product to the cart. Plus, it doesn&#8217;t rely on <em>Javascript</em>.</p>


	<p>All we&#8217;re going to do is add a single line of code <span class="caps">INSIDE</span> the cart form in <code>product.liquid</code>. So, open <code>product.liquid</code> and locate the opening form tag&#8230;</p>


<pre><code>&lt;form action="/cart/add" method="post"&gt;</code></pre>

	<p>and add the following line immediately beneath it&#8230;</p>


<pre><code>&lt;input type="hidden" name="return_to" value="back" /&gt;</code></pre>

	<p>Save. If you watch the <span class="caps">URL</span> while adding the product to the cart, you&#8217;ll see it quickly add the product then return to the current product <span class="caps">URL</span>. Obviously, to really make this effective you&#8217;d want to notify the user that the product has been added and encourage them to continue shopping, but this is a start.</p>]]>
</summary>
<updated>
2007-08-22 21:38:52 -0600
</updated>
<published>
2007-08-22 21:38:52 -0600
</published>
<author>
<name>
Jared Burns
</name>
</author>
<link href='http://vogue.myshopify.com/blogs/weblog/91361-continue-shopping' rel='alternate'/>
</entry>
<entry>
<id>
tag:db1@shopify.com,2007:articles/91351
</id>
<title>
Min-Width Quirk
</title>
<summary type='html'>
<![CDATA[<p>For those of you who applied <strong>Vogue</strong> from the Shopify admin, the is a quirk that you&#8217;ll <span class="caps">DEFINITELY</span> want to fix. If you downloaded <strong>Vogue</strong> from this site, the issue has already been resolved. At any rate, take a look at this horrid screenshot&#8230;</p>


	<p><img src="http://static0.jadedpixel.com/s/files/1/0001/8021/assets/min-width.png" title="Min-Width" alt="Min-Width" /> <img src="http://static0.jadedpixel.com/s/files/1/0001/8021/assets/min-width-bug.png" title="Min-Width Quirk" alt="Min-Width Quirk" /></p>


	<p>You&#8217;ll notice the backgrounds of the inner divisions don&#8217;t span the width of the browser when it&#8217;s less than the width of the container, which is 875 pixels. This is definitely not a good thing, but I believe it&#8217;s limited to Safari and Firefox. Fortunately, we can quickly fix this.</p>


	<p>We simply need to add <strong>min-width: 875px;</strong> to #header, #mini-header, #layout and #footer in stylesheet.css, sea.css, and caramel.css&#8230;</p>


	<p>Here&#8217;s an example of the header id in stylesheet.css&#8230;</p>


<pre><code>#header {
    color: #fff;
    background: #9b0103 url(header.png) repeat-x center top;
    min-width: 875px;
}</code></pre>

	<p>Repeat that for each of the id&#8217;s mentioned above in all three stylesheets, if you intend to use either of the others at some point. Well, were good to go again. Sheesh!</p>]]>
</summary>
<updated>
2007-08-22 21:15:26 -0600
</updated>
<published>
2007-08-22 21:15:26 -0600
</published>
<author>
<name>
Jared Burns
</name>
</author>
<link href='http://vogue.myshopify.com/blogs/weblog/91351-min-width-quirk' rel='alternate'/>
</entry>
<entry>
<id>
tag:db1@shopify.com,2007:articles/91301
</id>
<title>
Removing the Sidebar Indents
</title>
<summary type='html'>
<![CDATA[<p>If you downloaded <strong>Vogue</strong> from this site, this article doesn&#8217;t apply to you. However, if you applied <strong>Vogue</strong> from within the Shopify admin, you may choose to make this simple modification.</p>


	<p>I&#8217;ve had several <a href="http://forums.shopify.com/categories/3/posts/10889#comment-12594">questions</a> about removing the indent of the lists in the sidebar. Fortunately, this is an easy modification.</p>


	<p><img src="http://static0.jadedpixel.com/s/files/1/0001/8021/assets/indent.png" title="Sidebar with Indent" alt="Sidebar with Indent" /> <img src="http://static0.jadedpixel.com/s/files/1/0001/8021/assets/indent-no.png" title="Sidebar without Indent" alt="Sidebar without Indent" /></p>


	<p><strong>Navigation &#38; Blog Entries</strong><br />Open your stylesheet (<code>stylesheet.css</code>, <code>caramel.css</code> and/or <code>sea.css</code>), locate the section called <em>@group Global Styles</em>, then highlight the following section&#8230;</p>


<pre><code>ul, ol {
    margin-bottom: 10px;
}

ul li {
    margin-left: 25px;
    padding: 1px 0;
    list-style-type: disc;
    list-style-position: outside;
}

ol li {
    margin-left: 25px;
    padding: 1px 0;
    list-style-type: decimal;
    list-style-position: outside;
}</code></pre>

	<p>and replace with&#8230;</p>


<pre><code>ul, ol {
    margin-bottom: 15px;
}

ul li {
    padding: 2px 0 2px 15px;
    list-style-type: disc;
    list-style-position: inside;
}

ol li {
    padding: 2px 0 2px 15px;
    list-style-type: decimal;
    list-style-position: inside;
}</code></pre>

	<p>Save. While we just took care of the navigation list and weblog entries, we still need to shift the <em>Featured Product</em> list to the left as well.</p>


	<p><strong>Featured Products</strong><br />Still in your stylesheet, locate the following block of code&#8230;</p>


<pre><code>ul#featuring li {
    padding: 4px 20px;
    list-style-type: none;
    list-style-position: outside;
    margin: 0;
}</code></pre>

	<p>and change to&#8230;</p>


<pre><code>ul#featuring li {
    padding: 4px 0;
    list-style-type: none;
    list-style-position: outside;
}</code></pre>

	<p>Save your stylesheet once again to update your theme with the new changes.</p>


	<p><strong>Complete</strong><br />That should do it. Head over to your shop and if you did everything correctly, the sidebar contents should all be left aligned.</p>]]>
</summary>
<updated>
2007-08-22 20:22:12 -0600
</updated>
<published>
2007-08-22 20:22:12 -0600
</published>
<author>
<name>
Jared Burns
</name>
</author>
<link href='http://vogue.myshopify.com/blogs/weblog/91301-removing-the-sidebar-indents' rel='alternate'/>
</entry>
<entry>
<id>
tag:db1@shopify.com,2007:articles/91281
</id>
<title>
Grab the Feed
</title>
<summary type='html'>
<![CDATA[<p>Up until now visitors have been subscribing to the <span class="caps">XML</span> feed that Shopify generates for this blog. For any blog in any Shopify store, by simply adding .xml to the blog name in the <span class="caps">URL</span>, an <span class="caps">RSS</span> feed is available (i.e. <code>http://vogue.sofamade.com/blogs/weblog.xml</code>).</p>


	<p>I&#8217;ve switched this blog over to <a href="http://feedburner.com">Feed Burner</a>, so please update your feed reader to the <a href="http://feeds.feedburner.com/vogue">new address</a>...</p>


	<p><a href="http://feeds.feedburner.com/vogue"><img src="http://static0.jadedpixel.com/s/files/1/0001/8021/assets/subscribe.png" title="All things Vogue, Shopify and Liquid..." alt="All things Vogue, Shopify and Liquid..." /></a></p>


	<p>Grab the feed while it&#8217;s hot! I&#8217;ll be posting several tutorials very soon.</p>]]>
</summary>
<updated>
2007-08-22 18:31:30 -0600
</updated>
<published>
2007-08-22 18:31:30 -0600
</published>
<author>
<name>
Jared Burns
</name>
</author>
<link href='http://vogue.myshopify.com/blogs/weblog/91281-grab-the-feed' rel='alternate'/>
</entry>
<entry>
<id>
tag:db1@shopify.com,2007:articles/91001
</id>
<title>
Vogue Gets Easier!
</title>
<summary type='html'>
<![CDATA[<p>As with any Shopify theme, you currently have to log into your account and apply it before being able to dive into the code. Well, I&#8217;ve just added a <a href="/pages/download">new section</a> to this site where you can download <strong>Vogue</strong> without applying it to your shop.</p>


	<p>Now, the downloadable version has some noticeable differences from <strong>Vogue</strong> in your admin. Why is this? Well, there are several customizations (custom image sizes, etc.) that prove to be a challenge with the version available directly from Shopify. After completing <strong>Vogue</strong>, the Shopify guys made a few changes to the <span class="caps">XHTML</span>/CSS to improve <strong>Vogue&#8217;s</strong> performance on Shopify. While the changes are excellent, some of them limit <strong>Vogue&#8217;s</strong> flexibility.</p>


	<p>So, I since blended the code and am excited to announce <strong>Vogue 1.1</strong>. As previously mentioned, simply head to the <a href="/pages/download">download</a> page to get your hands on the latest version. Once you&#8217;ve downloaded it, you can upload the <span class="caps">ZIP</span> file into your admin.</p>


	<p>It&#8217;s important to note that this latest release does <strong>NOT</strong> include any customizations such as image logo, custom image sizes, color schemes, etc. You will need to make those changes <span class="caps">AFTER</span> you download the latest version, but they will be a breeze as all the tutorials on this site will guide you through the process.</p>


	<p>As always, send an email to <strong>vogue [at] sofamade [dot] com</strong> to inform us of any issues. <strong>Vogue</strong> is provided free of charge, but also free of support. I try to answer as many questions as I can, but my time is limited. Refer to the <a href="http://forums.shopify.com">Shopify Forums</a> for general support. Thanks!</p>]]>
</summary>
<updated>
2007-08-22 12:49:42 -0600
</updated>
<published>
2007-08-22 12:49:42 -0600
</published>
<author>
<name>
Jared Burns
</name>
</author>
<link href='http://vogue.myshopify.com/blogs/weblog/91001-vogue-gets-easier' rel='alternate'/>
</entry>
<entry>
<id>
tag:db1@shopify.com,2007:articles/84151
</id>
<title>
Javascript Disabled?
</title>
<summary type='html'>
<![CDATA[<p>One thing that&#8217;s always kinda bugged me about the standard Shopify themes is the fact that they rely on a user having Javascript turned on. Well, at least the cart does.</p>


	<p>While it&#8217;s true that the majority of users have <a href="http://www.w3schools.com/browsers/browsers_stats.asp">Javascript enabled</a>, I believe it&#8217;s designers/developers duty to make sure websites function properly if a user chooses to disable it. There are exceptions, but I strive to make the page work for everybody, then add the dynamic and interactive Javascript features later.</p>


	<p>All that said, all the standard Shopify themes (including <strong>Vogue</strong>) use Javascript to remove a product from the cart. It&#8217;s bothered me, but I&#8217;ve never spent the time to figure out how to remove an item without it. Fortunately, <a href="http://shopify.com">Daniel of Shopify</a> did!</p>


	<p>While perusing through Daniel&#8217;s <strong>Showroom theme</strong>, I stumbled across his solution to remove a product from the cart with Javascript if it&#8217;s enabled and a standard <span class="caps">XHTML LINK</span> tag if it&#8217;s not. This is fantastic because we can easily apply this method to the <strong>Vogue</strong> theme and make it 100% accessible! Let&#8217;s do it&#8230;</p>


	<p>First, login to your admin, click &#8220;Look &#38; Feel&#8221;, then click <code>cart.liquid</code>. Once you&#8217;ve opened the cart template, locate the following block of code towards the bottom&#8230;</p>


<pre><code>&lt;a href="#" onclick="remove_item({{ item.variant.id }}); return false;"&gt;Remove&lt;/a&gt;</code></pre>

	<p>And replace it with&#8230;</p>


<pre><code>&lt;a href="/cart/change/{{ item.variant.id }}?quantity=0" 
onclick="remove_item({{item.variant.id}}); return false;"&gt;Remove&lt;/a&gt;</code></pre>

	<p>This little piece of code was the only thing holding <strong>Vogue</strong> back from accessibility to everybody. There is now NO dependence on Javascript, but still takes advantage of it if enabled!</p>]]>
</summary>
<updated>
2007-08-10 17:42:56 -0600
</updated>
<published>
2007-08-10 17:42:56 -0600
</published>
<author>
<name>
Jared Burns
</name>
</author>
<link href='http://vogue.myshopify.com/blogs/weblog/84151-javascript-disabled' rel='alternate'/>
</entry>
<entry>
<id>
tag:db1@shopify.com,2007:articles/75341
</id>
<title>
Custom Image Sizes
</title>
<summary type='html'>
<![CDATA[<p>The most common question I receive is, &#8220;How do I make my product images the same size as the <strong>Vogue</strong> demo site?&#8221; Fortunately, your shop can look just like this with a little creativity.</p>


	<p><strong>For these modifications to work correctly, you must be using Vogue <a href="/pages/download">downloaded</a> from this site. When using Vogue applied from your Shopify admin, you will experience issues with the product page.</strong></p>


	<p>Before we get into the tutorial, it&#8217;s important to understand how <strong>Shopify</strong> handles product images. After an image is uploaded through the shop admin, Shopify stores it on a separate image server, which can then be accessed using <a href="http://liquidmarkup.org">Liquid</a> within the theme templates. A few default sizes are available using a <a href="http://help.shopify.com/design/show/product_img_url">Liquid Filter</a> for product images.</p>


	<p>After some begging and pleading (not really), Tobi recently added <strong>original</strong> as a variant of the <a href="http://help.shopify.com/design/show/product_img_url">product_img_url</a> filter. This variant is what makes <em>custom image sizes</em> possible, but does require a slight work-around. So, let&#8217;s do it already&#8230;</p>


	<p><strong>Product Images</strong><br />We&#8217;ll need to create an image to act as your <em>custom image</em> that will display on <code>index.liquid</code> and <code>collection.liquid</code>. We&#8217;ll also create a custom <span class="caps">AND</span> full size image to display on <code>product.liquid</code>.</p>


	<p>Using <a href="http://www.adobe.com/products/photoshop">Photoshop</a> or another photo editing tool, open your product image and&#8230;</p>


	<ol>
	<li>Resize/Crop to 175&#215;130 pixels, then save as <em>title-feature.jpg</em>.</li>
		<li>Re-open original and resize/crop to 356&#215;265 pixels, then save as <em>title-product.jpg</em></li>
		<li>Re-open original and resize/crop to 480&#215;360 pixels, then save as <em>title.jpg</em>.</li>
	</ol>


	<p>After these images have been created, upload them to your product images. Make sure <em>title-feature.jpg</em> is in the first position and <em>title-product.jpg</em> is in the second position. Any product in the third position or greater should be sized like <em>title.jpg</em> and the quantity is unlimited. Do this for all of your products.</p>


	<p><strong>Edit the Templates</strong><br />Now that you have uploaded the appropriate product images, we need to edit a bit of code in the theme templates. First, open <code>index.liquid</code> and locate&#8230;</p>


<pre><code>&lt;img src="{{ product.images.first | product_img_url: 'small' }}" 
alt="{{ product.title }}" /&gt;</code></pre>

	<p>and change to&#8230;</p>


<pre><code>&lt;img src="{{ product.images.first | product_img_url: 'original' }}" 
alt="{{ product.title }}" /&gt;</code></pre>

	<p>Save, then open <code>collection.liquid</code> and make the same changes as above. Next, open <code>product.liquid</code> and locate&#8230;</p>


<pre><code>{% for image in product.images %}{% if forloop.first %}
&lt;div id="product-image"&gt;
    &lt;a href="{{ image | product_img_url: 'original' }}" rel="lightbox[images]" 
    title="{{ product.title }}"&gt;&lt;img src="{{ image | product_img_url: 'medium' }}" 
    alt="{{ product.title }}" /&gt;&lt;/a&gt;
&lt;/div&gt;</code></pre>

	<p>and replace with&#8230;</p>


<pre><code>{% for image in product.images offset: 1 %}{% if forloop.first %}
&lt;div id="product-image"&gt;
    &lt;a href="{{ image | product_img_url: 'original' }}" rel="lightbox[images]" 
    title="{{ product.title }}"&gt;&lt;img src="{{ image | product_img_url: 'original' }}" 
    alt="{{ product.title }}" /&gt;&lt;/a&gt;
&lt;/div&gt;</code></pre>

	<p><strong>Complete</strong><br />Go to your homepage and it should now look like this <strong>Vogue</strong> demo site. All done!</p>]]>
</summary>
<updated>
2007-07-29 21:56:44 -0600
</updated>
<published>
2007-07-29 21:56:44 -0600
</published>
<author>
<name>
Jared Burns
</name>
</author>
<link href='http://vogue.myshopify.com/blogs/weblog/75341-custom-image-sizes' rel='alternate'/>
</entry>
</feed>