Home Forums Plugin Support WP User Frontend Pro User Dashboard Queries

This topic is: not resolved

This topic contains 10 replies, has 2 voices, and was last updated by  Hannah 5 years, 1 month ago.

Viewing 11 posts - 1 through 11 (of 11 total)
  • Author
    Posts
  • #10258

    Hannah
    Member
    Post count: 14

    Hi there. Firstly, I love this plugin, it's great!
    Just a couple of questions regarding the user dashboard:

    1. Using the shortcode [wpuf_dashboard], the dashboard displays with:
    ‘Posts Created' first
    Then ‘Author info' underneath.

    I would like to change these around so that author info is displayed at the top of the page with the posts created underneath it. Is there a way to do this?

    2. The ‘Author info' shows username, profile picture and biographical info. I have created some extra custom fields (text and image) in the registration form which I would also like to show here – please can you tell me how to do this?

    Thanks in advance, Hannah

    #10259

    Tareq Hasan
    Keymaster
    Post count: 2831

    For both of these, you've to edit the plugin.

    1. In /class/frontend-dashboard.php, line 232, which reads $this->user_info();. You've to move this line to before this line: <?php if ( $dashboard_query->have_posts() ) { ?>.

    2. In the same file, user_info() function, you've to print the meta keys like this: <?php echo get_user_meta( $userdata->ID, 'your_meta_key', true ); ?>

    Hope that helps.

    #10279

    Hannah
    Member
    Post count: 14

    Hi Tareq, thanks for that.
    1. yes, got that working, thank you!

    However, because there's more of it, the text now runs out of the first box and over the second. Is there a way to make the box size responsive to the amount of text within it so it adjusts accordingly?

    2. yes, got that working for text. However, when I put in the meta key for an image section, instead of showing the image it just shows the image id number. is there a way round this?

    Thanks for your help! Hannah

    #10290

    Tareq Hasan
    Keymaster
    Post count: 2831

    1. Umm…that's a CSS issue. Adding this to your themes style.css should do.
    [css]
    .wpuf-author .wpuf-author-inside {
    height: auto !important;
    overflow: hidden;
    }
    [/css]

    2. WPUF stores attachmend ID's of uploaded images. So to show the actual image, here's a code example:
    [php]
    $images = get_user_meta( $userdata->ID, ‘mey_key_name', true );
    $thumb = wp_get_attachment_image( $attachment_id, ‘thumbnail' );
    $full_size = wp_get_attachment_url( $attachment_id );
    printf( ‘<a href="%s">%s</a>', $full_size, $thumb );
    [/php]

    #12628

    Hannah
    Member
    Post count: 14

    brilliant, thank you!
    One more problem (I hope!). On the page displaying the wpuf dashboard, the sidebar is pushed down to the bottom of the page. I've checked and it's definitely the wpuf dashboard which is causing it. How do I fix this?
    Thank you!
    Hannah

    #12634

    Hannah
    Member
    Post count: 14

    Ok, just had time to try those out. The first one worked brilliantly. The second one is still showing the image id rather than the actual image. I added the code and changed only the meta kay name. Is that right? Should I have changed anything else? Sorry, I'm very new to this!
    Thanks, Hannah

    #12646

    Tareq Hasan
    Keymaster
    Post count: 2831

    That's right, you just need to change the meta key only.

    #12648

    Hannah
    Member
    Post count: 14

    Hmm, I wonder why it's not working then? I'll keep playing around with it and see.
    Any ideas on the sidebar issue mentioned above?
    Thanks! Hannah

    #12728

    Tareq Hasan
    Keymaster
    Post count: 2831

    Hi Hanna, give the site link and details so I can check whats going on.

    #14114

    Hannah
    Member
    Post count: 14
    This reply has been marked as private.
    #14120

    Hannah
    Member
    Post count: 14

    ok, and just one more!
    on the page above, when you press ‘edit' next to a post, it takes you to the edit profile page rather than the post edit page.
    Thanks in advance ๐Ÿ™‚

Viewing 11 posts - 1 through 11 (of 11 total)

The topic ‘User Dashboard Queries’ is closed to new replies.