WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] How i can remove this margin? (5 posts)

  1. heijmeijer
    Member
    Posted 2 years ago #

    I'm using related post, but i can't remove this margin:

    Link image: http://twitpic.com/7hz0ut

    Related post code:

    <div class="related_post">
    » Posts Relacionados
    <?php do_action('erp-show-related-posts', array('title'=>'', 'num_to_display'=>5, 'no_rp_text'=>'Nada encontrado.')); ?>
    </div>

    Thx! :D

    [Please post code snippets between backticks or use the code button.]

  2. Jeremy Herve
    Member
    Posted 2 years ago #

    Can you give us the URL of your site, so we can see it and try to debug live?
    Thanks!

  3. heijmeijer
    Member
    Posted 2 years ago #

    My website is still a private server (localhost), but the code is below:

    Sidebar.php

    <div class="<strong>rightpost</strong>">
    <div class="<strong>related_post</strong>">
    » Posts Relacionados
    <?php do_action('erp-show-related-posts', array('title'=>'', 'num_to_display'=>5, 'no_rp_text'=>'Nada encontrado.')); ?>
    </div>
    </div>

    [Please post code snippets between backticks or use the code button.]

    Style.css

    /* Sidebar */
    <strong>.rightpost</strong>{
    	float: right;
    	text-align: left;
    	margin: auto;
    	width: 230px;
    	text-decoration: none;
    	padding: 10px 10px 10px 5px;
    	background: #e0ecfe;
    	border: 1px solid;
    	border-color: #caddfc;
    	border-radius: 1em;
    	-moz-border-radius: 1em;
    	-webkit-border-radius: 1em;
    	-khtml-border-radius: 1em;
      list-style:none;
    }
    
    <strong>.related_post</strong>{
      list-style:none;
    }
  4. Jeremy Herve
    Member
    Posted 2 years ago #

    You could try remove the padding here, see if that helps:

    padding: 10px 10px 10px 0;
  5. heijmeijer
    Member
    Posted 2 years ago #

    Worked! Thx! :D

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags