Geodirectory listings item edit format

This topic contains 14 replies, has 3 voices, and was last updated by  Patrik 4 years, 3 months ago.

We have moved to a support ticketing system and our forums are now closed.

Open Support Ticket
  • Author
    Posts
  • #5641

    Foster
    Buyer
    Post count: 164

    Hello,
    I am having trouble figuring out how to format the list items on the Profile page. For example in “Favorites”, the Places listed show the title and description. I would like to show address, phone, etc, instead. Is there a template for that?

    I would also like to display the user avatar but not the cover image. The widget settings of UWP > Profile Header imply this is possible but I cannot get it to work. (attached img)

    #5649

    Alex Rollin
    Moderator
    Post count: 27815

    If hiding the cover isn’t working, we can take a look at the issue. Just share WP Admin credentials in a private reply along with login URL.

    About the listing excerpt, that format is a standard template for UsersWP listings and requires customization to change.

    You can, however, visit the new Tabs UI and create your own tabs with shortcodes like GD Listings which will use the archive item template from GD.

    #5683

    Foster
    Buyer
    Post count: 164
    This reply has been marked as private.
    #5697

    Patrik
    Moderator
    Post count: 1971

    Hi,

    This is an issue with the bootstrap layout template. We have fixed it and will be available in next update. If you want to apply the changes then let us know the FTP details in private reply and we will do it for you.

    Regards,
    Patrik

    #5700

    Patrik
    Moderator
    Post count: 1971

    Regarding, adding an address, phone, etc, for listing you can use a hook “uwp_before_profile_summary” or “uwp_after_profile_summary” to display the extra content. You may need the help of the developer for this as this is part of customization.

    Regards,
    Patrik

    #5758

    Foster
    Buyer
    Post count: 164

    Thanks guys,

    I used the new Tabs UI to add a shortcode that gives OK results. My new “Listings” and “Favorites” tabs are not as slick as the default ones but will work. It would be preferable if UsersWP could use an editable page-template system for archive items like GeoDirectory.

    In setting up the tabs, I have noticed now that the tab links are using anchors, it is causing the whole page to jump when loading. Is there a way to prevent this? Is there some advantage to using anchors that I’m missing? I thought the old way worked pretty well.

    #5761

    Patrik
    Moderator
    Post count: 1971

    We have used the anchor tag to scroll to the content of the tab. You can use some JS like following which will add smooth scrolling on click of the link:

    var $root = $('html, body');
    
    $('a[href^="#"]').click(function() {
        var href = $.attr(this, 'href');
    
        $root.animate({
            scrollTop: $(href).offset().top
        }, 500, function () {
            window.location.hash = href;
        });
    
        return false;
    });

    This is customization and we don’t provide support for that but I have given the hint so that you can get the idea or you can hire a developer to do this.

    Regards,
    Patrik

    #5766

    Foster
    Buyer
    Post count: 164

    If you could give me the exact code to add as a Code Snippet, I could try that.

    But I don’t think “smooth scrolling” is the solution I’m looking for. The page appears to reload every time I click a tab. Maybe the header image can be hidden to make it less jarring?

    #5923

    Patrik
    Moderator
    Post count: 1971

    Hi,

    The tabs are actually links. It will reload the page all the time you click on the tab. This was there in our older UWP version as well. Let us know what exactly you want to do.

    Regards,
    Patrik

    #5954

    Foster
    Buyer
    Post count: 164

    Hi Thanks, Patrik.
    I’m not sure yet what I’d like to do but I saw this in the changelog the other day and assumed it had something to do with the issue I’m having.

    1.2.0.9
    Profile tabs now used #anchor so to take user to the content – ADDED

    #5964

    Patrik
    Moderator
    Post count: 1971

    Hi,

    This change is for scrolling to the content after clicking on the link so the user don’t need to scroll to see the content. The page will always reload when you click on any tab and then scrolled to the content of the tab.

    Regards,
    Patrik

    #5999

    Foster
    Buyer
    Post count: 164
    This reply has been marked as private.
    #6003

    Patrik
    Moderator
    Post count: 1971

    Hi,

    The page scrolls to the top offset of the div but there is a header on your site so the div hides behind the header. You have to add the offset to the scroll so that it scrolls till the end of the header edge. Try the following code and let me know if it works for you:

    var $root = $('html, body');
    
    $('a[href^="#"]').click(function() {
        var href = $.attr(this, 'href');
    
        $root.animate({
            scrollTop: $(href).offset().top + 118
        }, 500, function () {
            window.location.hash = href;
        });
    
        return false;
    });

    You can change ‘118’ to the exact height of the header. The login details provided are not working so I am not able to check.

    Regards,
    Patrik

    #6186

    Foster
    Buyer
    Post count: 164

    Hi,
    I don’t know where to put that code. Or how to format it for a snippet for Code Snippets plugin. Can you help?

    #6328

    Patrik
    Moderator
    Post count: 1971

    Hi,

    You can put the code from Snippets->Add new and then give it a title and put the following code in the Code area:

    add_action('wp_footer', 'wp_footer_cb');
    function wp_footer_cb(){
        ?>
        <script type="text/javascript">
            jQuery( document ).ready(function() {
                var $root = jQuery('html, body');
    
                if ( window.location.hash ) {
                    var hash = window.location.hash,
                        $hash = jQuery(hash);
    
                    $root.animate({
                        scrollTop: $hash.offset().top - 120
                    }, 500, function () {
    
                    });
                }
            });
    
        </script>
        <?php
    }

    Let me know if this helps.

    Regards,
    Patrik

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

We have moved to a support ticketing system and our forums are now closed.

Open Support Ticket