WordPress.org

Ready to get started?Download WordPress

Forums

Elbee Elgee
[resolved] Move Feature Picture to side of text (29 posts)

  1. NobodySpecific42
    Member
    Posted 10 months ago #

    On my current homepage all featured pictures are shown above the text of the article, I would like them to be aligned to either the left or right with the text next to it. I have seen a lot of posts about this in other themes, but none of the fixes seem to work for this theme. Could anyone help?

  2. wp-21
    Member
    Posted 10 months ago #

    Hi,You just need to float the featured image to the left , so that text comes automatically to the right.
    locate the class for the featured image and give it float:left
    and you will be done.

  3. NobodySpecific42
    Member
    Posted 10 months ago #

    I wasn't able to find it in my initial search. Why I posted specifically on this theme since I was hoping someone else who used this theme would know what file and where I would need to add that to make it work.

  4. wp-21
    Member
    Posted 9 months ago #

    featured image code is like below

    <?php the_post_thumbnail(); ?>

    you'll find it most likely in content.php
    but editing directly source files is not recommended, it would be better if you could create child theme and then do the edits so that your changes are not lost when parent theme gets updated.

    http://codex.wordpress.org/Child_Themes

  5. NobodySpecific42
    Member
    Posted 9 months ago #

    There is no content.php in this theme, that is why I have been unable to find it. I was hoping someone else who uses this theme had this same problem =\ Really can't find where to change it at all, checked all the files that I thought would have it and none of them have
    <?php the_post_thumbnail(); ?>

  6. WPyogi
    Volunteer Moderator
    Posted 9 months ago #

    Can you post a link to your site? It might be a CSS question.

  7. NobodySpecific42
    Member
    Posted 9 months ago #

    Sure, XXXXXXXXX still in construction phase so there is a lot of filler stuff.

  8. WPyogi
    Volunteer Moderator
    Posted 9 months ago #

    I'm not totally sure this will work, but try adding this to your CSS - hopefully the theme has Custom CSS option? If not, you can add it via a plugin such as Custom CSS Manager.

    #lb-content img.wp-post-image {
        float: left;
        margin: 0 20px 10px 0
  9. NobodySpecific42
    Member
    Posted 9 months ago #

    Didn't seem to do anything.

  10. WPyogi
    Volunteer Moderator
    Posted 9 months ago #

    Oops, I forgot the closing bracket on that:

    #lb-content img.wp-post-image {
        float: left;
        margin: 0 20px 10px 0
    }

    Not sure that will change it - where did you add it?

  11. NobodySpecific42
    Member
    Posted 9 months ago #

    I had deleted it already, just re-added it to the top of style.css

  12. NobodySpecific42
    Member
    Posted 9 months ago #

    This time it works, I put it way further down last time, guess it was overwritten before. Awesome thanks, now just need to get some padding between that and the text.

  13. NobodySpecific42
    Member
    Posted 9 months ago #

    Looks like it does it for both the home page and the actual article page though, but I can deal with that as long as it works on the home page I suppose.

  14. WPyogi
    Volunteer Moderator
    Posted 9 months ago #

    Actually, the margins are getting overridden, so try this:

    #lb-content img.wp-post-image {
        float: left;
        margin: 0 20px 10px 0 !important;
    }
  15. WPyogi
    Volunteer Moderator
    Posted 9 months ago #

    If you only want it on the home page, we can do that...change it to:

    .home #lb-content img.wp-post-image {
        float: left;
        margin: 0 20px 10px 0 !important;
    }
  16. NobodySpecific42
    Member
    Posted 9 months ago #

    You are the greatest, thank you SOOOO much!!!! =]

  17. WPyogi
    Volunteer Moderator
    Posted 9 months ago #

    You're welcome :)!

  18. NobodySpecific42
    Member
    Posted 9 months ago #

    now randomly for some reason my sidebar is showing up below the content potion of the page, no idea why. :(

  19. WPyogi
    Volunteer Moderator
    Posted 9 months ago #

    You'll have to post your URL again - I'm on a different computer - no history.

  20. NobodySpecific42
    Member
    Posted 9 months ago #

    http://www.hexsavvy.com, something happened and now every layout is completely screwed no idea why and using my parent theme isn't working either... hmmmm

  21. WPyogi
    Volunteer Moderator
    Posted 9 months ago #

    This CSS is invalid - causing problems:

    {
            margin: 0;
    	padding: 0;
            background-color:rgb(99,94,99);
    }
  22. NobodySpecific42
    Member
    Posted 9 months ago #

    Got rid of that, still looks to be messed up. from the time you helped me fix the image to the time it broke the only thing I was editing was forums, so I honestly don't know how it would have broken this.

  23. WPyogi
    Volunteer Moderator
    Posted 9 months ago #

    Looks like this got too wide?

    div#lb-content {
        float: left;
        width: 700px;
    }
  24. NobodySpecific42
    Member
    Posted 9 months ago #

    Doesn't seem to be doing it, the problem is through the whole site, articles, forums, home, etc. Not sure what it would be =\

  25. WPyogi
    Volunteer Moderator
    Posted 9 months ago #

    Hmm, try changing the above to:

    div#lb-content {
        float: left;
        width: 680px;
    }

    I'm really not sure, but that seems to fix it.

  26. NobodySpecific42
    Member
    Posted 9 months ago #

    Doesn't seem to do anything for me =\

  27. NobodySpecific42
    Member
    Posted 9 months ago #

    Well, thanks for the help, I am going to try a few things and look at a couple different themes that look like they fix it. If I have any more questions I will post them here, you have been amazing and I have a much better grasp on CSS now hah.

  28. WPyogi
    Volunteer Moderator
    Posted 9 months ago #

    You could try taking out whatever changes you've made. Also, using the CSS validator can be helpful if there are errors:

    http://jigsaw.w3.org/css-validator/

    Though not everything that shows up as an error is really a problem - but you can double check that you don't have syntax errors...

  29. NobodySpecific42
    Member
    Posted 9 months ago #

    Alright thanks a lot!

Reply

You must log in to post.

About this Theme

About this Topic

Tags

No tags yet.