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. General Discussion
  3. Make Phone sitetitle centered vertically on front page

Make Phone sitetitle centered vertically on front page

Scheduled Pinned Locked Moved General Discussion
3 Posts 2 Posters 73 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.
  • S Offline
    S Offline
    sds
    wrote on last edited by sds
    #1

    Hello. I've tried for ages to make my sitetitle image centered both horizontal and vertically on just the frontpage and only on the Phone version. Normally, the sitetitle is top left centered.

    So far, I've target the css as following and put it in the Custom CSS for Mobile

    body.slug-index .mobile-title img {
    
    }
    

    I can resize the title to fill out the screen, so it's horizontal centered, but no matter what I can't make it vertically centered. It will only be positioned on top of the screen, so somehow it might be keeping it's "top left" values.

    Any suggestions, thanks!

    S 1 Reply Last reply
    0
    • S sds

      Hello. I've tried for ages to make my sitetitle image centered both horizontal and vertically on just the frontpage and only on the Phone version. Normally, the sitetitle is top left centered.

      So far, I've target the css as following and put it in the Custom CSS for Mobile

      body.slug-index .mobile-title img {
      
      }
      

      I can resize the title to fill out the screen, so it's horizontal centered, but no matter what I can't make it vertically centered. It will only be positioned on top of the screen, so somehow it might be keeping it's "top left" values.

      Any suggestions, thanks!

      S Offline
      S Offline
      sds
      wrote on last edited by
      #2

      I've also tried

      body.slug-index .sitetitle {
          left: 50%!important;
          top: 50%!important;
      }
      

      As changing these values directly in the browser inspect panel will correctly place the sitetitle img in the center of the browser. However, using these values in the custom css has no effect.

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

        ure using the wrong selector

        body.slug-index .mobile-title {
            left: 50%!important;
            top: 50%!important;
            transform: translate(-50%, -50%);
        }
        
        1 Reply Last reply
        0
        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
        J
        joackim
        C
        craigfeldspar
        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