Changing Featured Image Position Property in Theme CSS

  • Unknown's avatar

    I simply need the featured image to appear static on the page, so when users scroll down the image does not begin to disappear behind the next block.

    To accomplish this, I have viewed the main CSS file for the theme which was used and am attempting to override the section(s) I need using the “!important” property, however, nothing I do is making the change desired and I’m uncertain if I’m simply using incorrect code or if I am not overriding the correct section of the theme, as I am having difficulty determining which portion controls the positioning of the featured image.

    The blog I need help with is: (visible only to logged in users)

  • Unknown's avatar

    Also, I forgot to mention, it already does what it is supposed to for mobile devices and stays put. It is only when using desktop that the problem arrises.

  • Unknown's avatar

    Greetings!

    This CSS will make the desktop version work like the mobile version:

    .page-banner {
    background-attachment: scroll;
    }

    Be sure to remove any custom CSS that did not work from before.

    Please let us know if this works for you.

    Did you know that your WordPress.com plan includes live chat support? Staff frequently recommends live chat support as a way to get help faster with questions about custom CSS.

  • Unknown's avatar

    same code with better formatting:

    .page-banner {
    	background-attachment: scroll;
    }
  • Unknown's avatar

    Well you’re just fixing my problems left and right today. This worked perfect! Thanks you SO MUCH!

  • The topic ‘Changing Featured Image Position Property in Theme CSS’ is closed to new replies.