Supportlogo-header

04:15PM, Aug 16, 2006

James D. Member

Create a page listing all collections?

Hello all, I want to have a list of all my collections, but I do not want to put this list on my front page -- I want it on a separate page (like /collections/ for example). Is this possible? I've never used shopify before, so forgive me if this question is foolish, but I'm trying to get a client's site up as quickly as possible. Many thanks,
James D.

05:04PM, Aug 16, 2006

Richard Quick Shopify Advisor

Hi James,

Yes, you can do this.

If you set up a page (pages and blogs in your admin) you can put links to any collection in there either with html or textile to format your text.




Richard Quick
thePasty.comRichardQuickDesign.com

Richard Quick Finalist: SxSW Web Awards 2009 (CSS Category) SEO and Web design http://www.successfulsites.co.uk http://www.richardquickdesign.com

07:21PM, Aug 16, 2006

James D. Member

Richard, thank you for your reply.

Can I include other navigation lists though? Or am I restricted to hard-coding the lists in HTML?

James D.

09:16PM, Aug 16, 2006

Jamie Administrator

If you have a nav list that you don’t want on your index page then you can use conditionals in theme.liquid to control the output (or stop it in this case). But in the case that you have a navigation that you only want on all /collection pages you have it easy, in your collection.liquid template just drop your code in and it will only show on /collection pages. A body id can be passed through each page even on an individual level, making your control pretty granular for your css rules. The wiki reference page that would help you is here

Unfortunately there is no page on conditionals yet that I can find. But you can open any of the themes and grab some conditional code snipetts.

10:27PM, Aug 16, 2006

Richard Quick Shopify Advisor

You could use the following liquid code in your page.liquid file:


{% if page.handle == "collections-page" %}
   {% for link in linklists.my-new-linklist.links %}
      <li>{{ link.title | link_to: link.url }}</li>
   {% endfor %}
{% endif %}
Richard Quick Finalist: SxSW Web Awards 2009 (CSS Category) SEO and Web design http://www.successfulsites.co.uk http://www.richardquickdesign.com

11:26PM, Aug 16, 2006

Jamie Administrator

Thanks for the sprinkle of conditional Richard. I have a shoppify snippet library I have been slowly building thank mostly to your posts :)

11:58PM, Aug 16, 2006

Richard Quick Shopify Advisor

no probs – just happy to help

:)

Richard Quick Finalist: SxSW Web Awards 2009 (CSS Category) SEO and Web design http://www.successfulsites.co.uk http://www.richardquickdesign.com

02:44PM, Aug 18, 2006

James D. Member

Thanks a bunch Jamie and Richard. I had an inkling I’d just have to do conditionals in my main theme.

Cheers!

James D.

03:02PM, Aug 18, 2006

tobi Shopify

Jamie: You should really start a blog on this stuff. Could become really popular quickly

Tobias Lütke - Shopify CEO // http://twitter.com/tobi

Last edited 08:40PM, Jun 01, 2009

Salvatore Member

I need something similar to this and I know I’m close. Instead of using a linklist(because then I would have to add 300 links manually) I would simply just like to display a list of clickable links of all products in a particular collection on a certain page/handle. Can anyone help. Thanks.

I created a page with the handle “a-to-z”

This is what I have so far and it does not work:

{% if page.handle == "a-to-z" %}
   {% for product in collections[all].products %}
   {{ product.title }}

   {% endfor %}
{% endif %}

Many thanks!

Sal

Salvatore

02:47PM, Jun 02, 2009

Salvatore Member

Ok, I m getting there but now I have a problem where it only limits me to listing 50 products: Take a look:

http://www.virginfragrances.com/pages/a-to-z

here is my code:

{% if page.handle == "a-to-z" %}
   {% for product in collections.example.products %}
   <a href="{{ product.url | within: collections.example }}">{{ product.title }}</a><br>

   {% endfor %}
{% endif %}

There should be over 300 products in this list and somewhere its limiting it to only showing 50. Thanks in advance.

Regards,

Sal

Salvatore

login or Sign up for an account to reply.