Navigation
This is archived content. Visit our new forum.

Tagged: 

  • Author
    Posts
  • #1408562

    oga23
    Participant

    Hi,
    i used this code to display the author bio, but the info has no gap on the right side – is right next to the picture:

    function add_after_content($content) {
    if ( is_singular( 'post' ) ) {
      $author_text = do_shortcode( '[gap size="3em"][author class="man" title="Več o avtorju"]' );
     return $content.' '.$author_text;
    }
    }
    add_filter('the_content', add_after_content);

    is there a way to move the text a little to the right – away from the picture? i also think this was for the icon stack and i use integrity.

    thanks.

    #1408585

    Jade
    Moderator

    Hi there,

    Thanks for writing in! To assist you with this issue, we’ll first need you to provide us with your URL. This is to ensure that we can provide you with a tailored answer to your situation. Once you have provided us with your URL, we will be happy to assist you with everything.

    #1408609

    oga23
    Participant

    Hi,

    no problem: https://mojzastopnik.si/cas-tece/

    Could you also check, why there is no content on my portfolio items in the frontend, the content is there in the backend:
    https://mojzastopnik.si/portfolio-item/dirty-harry/

    Or should i open a new topic? i just realized there is nothing showing…

    thanks.

    #1409130

    Lely
    Moderator

    Hi There,

    Did you remove the code? I can’t see author bio at the end of your post. See this:http://screencast-o-matic.com/watch/cbeDhi6B7t. I am just seeing entry share.
    Regarding the portfolio item, the content is really blank when I check the source code.
    Would you mind providing us with login credentials so we can take a closer look? To do this, you can make a post with the following info:

    – Link to your site
    – WordPress Admin username / password
    – FTP credentials

    Don’t forget to select Set as private reply. This ensures your information is only visible to our staff.

    #1409995

    oga23
    Participant
    This reply has been marked as private.
    #1410611

    Rue Nel
    Moderator

    Hello There,

    Thanks for updating in! The code should be working as expected. The only problem is that the avatar is quite big. By default, the author box needs to have at least 90 pixels width for the avatar. To resolve this, please add the following css code in the customizer, Appearance > Customize > Custom > Edit Global CSS

    // set Author avatar size
    .x-author-box .avatar {
        max-width: 90px;
        height: auto !important;
    }

    The code is not causing any issue for the portfolio item. Even if the code is disabled or not even there, there is still no content for the portfolio item. It seems that a 3rd party plugin is causing an issue. Did you make any changes to the portfolio template?

    Please let us know how it goes.

    #1414459

    oga23
    Participant

    hi,
    after i removed the code the portfolio items and blog posts were all there. I have another code in my functions php, that hides the author and date under the post and portfolio title. Could it be that this is causing the problem?
    And i saw you entered the css code? or was it me and i don’t even know it? anyway – thanks.
    So, what can we do?
    Check out the code mentioned above and see if it is causing this problem and we’ll see from there, ok?

    regards.

    #1414852

    Christian
    Moderator

    Try wrapping add_after_content with single quotes like this

    add_filter('the_content', 'add_after_content');

    Thanks.