Jump to content

biainno

Member
  • Posts

    4
  • Joined

  • Last visited

Posts posted by biainno

  1. since the maximum columns for blog page is 4, is there a code for more columns, say perhaps 5?

    this is what i tried out, under custom CSS:
     

    @media screen and (min-width:600px) {
    .blog-basic-grid {
        grid-template-columns: repeat(5,minmax(0,1fr)) !important;
    	}
    }


    but the issue is that it alters the number of posts in each page and also the button (next page) at the bottom right is in the middle now.

  2. hm, is there a way to manually hardcode it though? i tried this, but the formatting of the page is off:

     

    <script type="text/javascript" src="//ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js"></script>
     
      <script type="text/javascript">
          $(document).ready(function(){
              if( $('.blog-item').length != 0 ){
                  var categories = []; 
                  $('.blog-item').each(function () {
                    categories.push({
                      categoryName: $(this).find('.blog-title').html(),
                      listItem: $(this)
                    });
                  });
                  categories.sort(function(a,b) {
                    var c = a.categoryName.toUpperCase();
                    var d = b.categoryName.toUpperCase();
                    return (c > d) ? 1 : ((d > c) ? -1 : 0);
                  });
                  $.each(categories, function(index, object){
                      object.listItem.appendTo(object.listItem.parent());
                  });
              }
          });
      </script>

     

×
×
  • 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.