Skip to content
  • Recent
  • Tags
  • Popular
  • Users
  • Search
Skins
  • Light
  • Brite
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse

Lay Theme Forum

  1. Home
  2. General Discussion
  3. Fullscreen Slider Counter

Fullscreen Slider Counter

Scheduled Pinned Locked Moved General Discussion
7 Posts 3 Posters 1.1k Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • K
    K
    kalamakumaran
    wrote on last edited by kalamakumaran
    #1

    Hi everybody,

    for anybody who is interested in having some kind of pagination/counter function for the fullscreen slider (e.g.. 1/20) I have a snippet I want to share with you.

    <div class="num"></div>
    
    <script>
    window.laytheme.on("newpageshown", function() {
        jQuery(window).on("fpAfterLoad", function() {
             var slideNumber = jQuery('.fp-section.active').index() -4;
             var numSections = jQuery('.fp-section').length;
         
             jQuery('.num').html(slideNumber + '/' + numSections)
        });
    });
    </script>
    

    I don't why know but my counter only starts from 0 when I put -4 in the function. That probably needs to be adjusted in your case.

    btw: code works for me with vertical fullscreen slider and auto-scrolling turned on.

    Enjoy!

    1 Reply Last reply
    0
    • RichardR
      RichardR
      Richard
      Global Moderator
      wrote on last edited by Richard
      #2

      Dear @kalamakumaran

      Thank you for the Code! 💥
      Fullscreen Slider Addon comes with 'pagination' :)


      Best wishes
      Richard
      1 Reply Last reply
      0
      • fabiandraxlF
        fabiandraxlF
        fabiandraxl
        wrote on last edited by
        #3

        Hej @Richard and @kalamakumaran

        The Code seams not to work anymore, did something change in the meantime?

        Tank you in advance and best regards,
        Fabian

        1 Reply Last reply
        0
        • K
          K
          kalamakumaran
          wrote on last edited by
          #4

          For me it still works.
          What exactly doesn’t work in your case?
          Maybe I can help.

          fabiandraxlF 1 Reply Last reply
          1
          • K kalamakumaran

            For me it still works.
            What exactly doesn’t work in your case?
            Maybe I can help.

            fabiandraxlF
            fabiandraxlF
            fabiandraxl
            wrote on last edited by
            #5

            Hej @kalamakumaran

            Thank you so much for trying to help out. :)

            I added the <script> and added the div but it does not show my row count and neither the actual row, it always shows me -4/1 ... have a look here: https://new.fabiandraxl.com/jaga/

            So i think it has to do with something with the javascript which is not able to fetch the corresponding sections etc?!

            Thank you and best regards,
            Fabian

            1 Reply Last reply
            0
            • K
              K
              kalamakumaran
              wrote on last edited by kalamakumaran
              #6

              Could be that the code is for any reason only working for the vertical fullscreen slider.

              Why don't you just use the carousel plugin for a horizontal slideshow? There you can set up a counter without custom code.

              Sorry that I can't help you any further with that.

              Awesome website btw.

              fabiandraxlF 1 Reply Last reply
              0
              • K kalamakumaran

                Could be that the code is for any reason only working for the vertical fullscreen slider.

                Why don't you just use the carousel plugin for a horizontal slideshow? There you can set up a counter without custom code.

                Sorry that I can't help you any further with that.

                Awesome website btw.

                fabiandraxlF
                fabiandraxlF
                fabiandraxl
                wrote on last edited by
                #7

                Hej @kalamakumaran,

                Could be, but I personally have no clue. :P haha

                Carousel is not that customizable, the side I showcased here was just an example wanted to built much more complex slides with the Gridder, which are not possible with the carousel plugin.

                Thank you and have a great week!

                1 Reply Last reply
                0

                Hello! It looks like you're interested in this conversation, but you don't have an account yet.

                Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

                With your input, this post could be even better 💗

                Register Login
                Reply
                • Reply as topic
                Log in to reply
                • Oldest to Newest
                • Newest to Oldest
                • Most Votes


                Online Users
                Forgot your key, lost your files, need a previous Lay Theme or Addon version? Go to www.laykeymanager.com
                laytheme.com
                • Login

                • Don't have an account? Register

                • Login or register to search.
                • First post
                  Last post
                0
                • Recent
                • Tags
                • Popular
                • Users
                • Search