Skip to content
  • Recent
  • Tags
  • Popular
  • Users
  • Search
Skins
  • Light
  • 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. Bug Reports
  3. Help! Sticky element doesen't work for me...

Help! Sticky element doesen't work for me...

Scheduled Pinned Locked Moved Bug Reports
18 Posts 2 Posters 163 Views
  • 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.
  • D Offline
    D Offline
    dnlbrv
    wrote on last edited by
    #9

    If I leave the row expanded as you said, the button state is not ".expand-link-clicked" and when I click it the row closes and the functionality logic of a category menu does not work.

    1 Reply Last reply
    0
    • arminunruhA Offline
      arminunruhA Offline
      arminunruh
      Global Moderator
      wrote on last edited by arminunruh
      #10

      So what you'd need to do is, you click the point using javascript.

      i can't open the site anymore:
      https://www.secretsfilms.com/site/en/alexis_taule_home-copy/

      but basically what you do is

      <script>
      window.laytheme.on('newpageshown', function(){
      jQuery('a[data-expand="39"]').click()
      })
      </script>
      

      Enter this css in "lay options" -> "custom css & html" -> "custom head content"

      obviously you can't use 'a[data-expand="39"]'

      instead, you need to find out the correct data-expand id by using inspect element
      Screenshot 2025-07-24 at 07.27.59.png

      1 Reply Last reply
      0
      • D Offline
        D Offline
        dnlbrv
        wrote on last edited by
        #11

        Hey,
        if I put the script:

        <script>
        window.laytheme.on("newpageshown", function() {
        jQuery('a[data-expand="13"]').click()
        });
        </script>

        page don't load. Only the menu is visible and the error in console says:
        [Error] TypeError: undefined is not an object (evaluating 'Gs.find')
        (anonymous function) (frontend.app.min.js:1:238436)
        dispatch (jquery.min.js:2:40041)
        trigger (jquery.min.js:2:70130)
        (anonymous function) (jquery.min.js:2:70734)
        each (jquery.min.js:2:3134)
        (anonymous function) (alexis_taule_home-copy:2773)
        emit (events_channels.min.js:1:1741)
        (anonymous function) (frontend.app.min.js:1:302722)

        Any idea? Thanks in advance

        1 Reply Last reply
        0
        • D Offline
          D Offline
          dnlbrv
          wrote on last edited by
          #12

          I tray activate the button but dont work:

          <script>
          window.laytheme.on("newpageshown", function() {
          jQuery('body.type-project.id-801 .btn_accion').trigger('click');
          });
          </script>

          1 Reply Last reply
          0
          • arminunruhA Offline
            arminunruhA Offline
            arminunruh
            Global Moderator
            wrote on last edited by arminunruh
            #13
            <script>
            window.laytheme.on('newpageshown', function(){
            if(jQuery('a[data-expand="13"]').length > 0){
            jQuery('a[data-expand="13"]').click();
            }
            })
            </script>
            

            the website seems to be online again.
            the above should be the correct code. i included a check, and i inserted the correct id

            i think this code is wrong:
            <script>
            window.laytheme.on("newpageshown", function() {
            jQuery('body.type-project.id-801 .btn_accion').trigger('click');
            });
            </script>

            can you use my code above and show a screenshot where you added it

            1 Reply Last reply
            0
            • D Offline
              D Offline
              dnlbrv
              wrote on last edited by
              #14

              After put your code, console says:
              [Error] TypeError: undefined is not an object (evaluating 'Gs.find')
              (anonymous function) (frontend.app.min.js:1:238436)
              dispatch (jquery.min.js:2:40041)
              trigger (jquery.min.js:2:70130)
              (anonymous function) (jquery.min.js:2:70734)
              each (jquery.min.js:2:3134)
              (anonymous function) (alexis_taule_home-copy:2797)
              emit (events_channels.min.js:1:1741)
              (anonymous function) (frontend.app.min.js:1:302722)

              In the screenshot you see where I added the code.

              Screenshot 2025-07-24 at 20.06.32.png

              1 Reply Last reply
              0
              • arminunruhA Offline
                arminunruhA Offline
                arminunruh
                Global Moderator
                wrote on last edited by arminunruh
                #15

                can you update lay theme now and try if it works now?
                i think now you shouldnt get the error anymore.

                seems like there was an issue with the compatibility of lay theme's code and the code i gave you

                1 Reply Last reply
                0
                • D Offline
                  D Offline
                  dnlbrv
                  wrote on last edited by
                  #16

                  I send the email
                  Thanxs a lot

                  1 Reply Last reply
                  0
                  • arminunruhA Offline
                    arminunruhA Offline
                    arminunruh
                    Global Moderator
                    wrote on last edited by
                    #17
                    <script>
                        window.laytheme.on('newpageshown', function(){
                            if(jQuery('a[data-expand="13"]').length > 0){
                                setTimeout(function(){
                                    console.log("hello!")
                                    jQuery('a[data-expand="13"]').click();
                                }, 1000)
                            }
                        })
                    </script>
                    

                    seems that with the new update and this timeout it works

                    1 Reply Last reply
                    0
                    • D Offline
                      D Offline
                      dnlbrv
                      wrote on last edited by
                      #18

                      Yeah, now works perfect.

                      thanxs again! Lay theme are the f****g best!

                      1 Reply Last reply
                      1
                      Reply
                      • Reply as topic
                      Log in to reply
                      • Oldest to Newest
                      • Newest to Oldest
                      • Most Votes


                      I also code custom websites or custom Lay features.
                      šŸ’æ Email me here: šŸ’æ
                      info@laytheme.com

                      Before you post:
                      1. When using a WordPress Cache plugin, disable it or clear your cache.
                      2. Update Lay Theme and all Lay Theme Addons
                      3. Disable all Plugins
                      4. Go to Lay Options → Custom CSS & HTML, click "Turn Off All Custom Code", click "Save Changes"

                      This often solves issues you might run into

                      When you post:
                      1. Post a link to where the problem is
                      2. Does the problem happen on Chrome, Firefox, Safari or iPhone or Android?
                      3. If the problem is difficult to explain, post screenshots / link to a video to explain it
                      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