Jump to content

Coding on productpage SS 7.1 version

Recommended Posts

Hi everyone,

 

I'm busy making a website with Squarespace for my business. I have just bought the universal filter option to integrate in my productpage/webshop. Nevertheless, it is not working. I've copied the following code, which normally would be enough to enhance my filters, but it's not working. 

 

Can anyone help me out?

Thanks a lot,

Kevin

<!--Header Injection Tab-->
<link rel="stylesheet" href="//assets.squarewebsites.org/custom-filter/custom-filter.min.css"/>

<!--Footer Injection Tab-->
<script>
window.customFilterSettings = {
    'targets': [{
        container: '#block-yui_3_17_2_3_1512982186827_4022', //css selector to target container where you want to place filter
        items: '.summary-item', //css selector for items you want to filter
        settings: {
            view: 'dropdowns', // filter style
            showItemsCount: true,// if true, you will see your items counter, set false to hide
            filter: {
                enabled: true,
                category: false, // disable default categories dropdown
                tag: false, // disable default tags dropdown
                items: [{
                        name: 'Your Category Name', //name the dropdown here
                        allLabel: 'All', //name the showed label
                        allOption: 'All', //name all option for breadcrumbs and buttons views of Filter
                        multiple: true, // allow multiple options being selected
                        getAttr: 'categories'
                    },
                    {
                        name: 'Your Tags Name',
                        allLabel: 'All', //name the showed label
                        allOption: 'All', //name all option for breadcrumbs and buttons views of Filter
                        multiple: true, // allow multiple options being selected
                        getAttr: 'tags'
                    }
                ]
            },
            sort: {
                enabled: true,
                title: 'Sort', // name of sort dropdown
                items: [{
                    name: 'Name',
                    order: 'asc|desc', //add asc and desc order to parameters
                    sort: '.summary-title-link' //css selector or custom function here which returns the sort factor
                }]
            },
            search: {
                enabled: true,
                text: 'Search'
            }
        }
    }]
};
</script>
<script src="//assets.squarewebsites.org/custom-filter/custom-filter.min.js"></script>

Link to comment
  • Replies 2
  • Views 689
  • Created
  • Last Reply
12 hours ago, Kevinvs said:

Hi everyone,

 

I'm busy making a website with Squarespace for my business. I have just bought the universal filter option to integrate in my productpage/webshop. Nevertheless, it is not working. I've copied the following code, which normally would be enough to enhance my filters, but it's not working. 

 

Can anyone help me out?

Thanks a lot,

Kevin

<!--Header Injection Tab-->
<link rel="stylesheet" href="//assets.squarewebsites.org/custom-filter/custom-filter.min.css"/>

<!--Footer Injection Tab-->
<script>
window.customFilterSettings = {
    'targets': [{
        container: '#block-yui_3_17_2_3_1512982186827_4022', //css selector to target container where you want to place filter
        items: '.summary-item', //css selector for items you want to filter
        settings: {
            view: 'dropdowns', // filter style
            showItemsCount: true,// if true, you will see your items counter, set false to hide
            filter: {
                enabled: true,
                category: false, // disable default categories dropdown
                tag: false, // disable default tags dropdown
                items: [{
                        name: 'Your Category Name', //name the dropdown here
                        allLabel: 'All', //name the showed label
                        allOption: 'All', //name all option for breadcrumbs and buttons views of Filter
                        multiple: true, // allow multiple options being selected
                        getAttr: 'categories'
                    },
                    {
                        name: 'Your Tags Name',
                        allLabel: 'All', //name the showed label
                        allOption: 'All', //name all option for breadcrumbs and buttons views of Filter
                        multiple: true, // allow multiple options being selected
                        getAttr: 'tags'
                    }
                ]
            },
            sort: {
                enabled: true,
                title: 'Sort', // name of sort dropdown
                items: [{
                    name: 'Name',
                    order: 'asc|desc', //add asc and desc order to parameters
                    sort: '.summary-title-link' //css selector or custom function here which returns the sort factor
                }]
            },
            search: {
                enabled: true,
                text: 'Search'
            }
        }
    }]
};
</script>
<script src="//assets.squarewebsites.org/custom-filter/custom-filter.min.js"></script>

Did you contact the author to help?

BeyondSpace - Squarespace Website Developer

🖼️ Lightbox Studio (Enable Pinch/Zoom on lightbox)
🗓️ Delivery Date Picker (Squarespace Date picker form field)
💫 Gallery block 7.1 workaround
🥳 Sparkplugin Customisations Browsers (Browse +100 Spark plugin customisations)
🥳 Elfsight Template Browsers (Browse +1000 Elfsight widget Templates)

If you find my answer useful, let's leave a like or upvote so others with the same issue can find their solution. Thank you!

 

Link to comment

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Squarespace Webinars

Free online sessions where you’ll learn the basics and refine your Squarespace skills.

Hire a Designer

Stand out online with the help of an experienced designer or developer.