1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Can't Fix Annoying issue when viewing a user's posts

Discussion in 'Resolved Bug Reports' started by Luke F, Aug 16, 2010.

  1. Luke F

    Luke F Well-Known Member

    Go to any member page, go to the Postings tab (not the best wording ever, but that's a different story), click a post, then go back. Assuming your browser isn't configured to hold pages in the back history in memory, you will end up back on the main Profile Posts tab.

    This can be quite annoying if you want to stalk a user and look through all their posts :)

    It would be nice if the tabs set an anchor in the url - this would have the added benefit of being able to link to a specific tab.
    Enigma and erich37 like this.
  2. anotheralias

    anotheralias Well-Known Member

    I get the profile page and have to click on posts again to see the list of posts - rather than hitting back and returning to the list of posts. Is that what you mean?
  3. Luke F

    Luke F Well-Known Member

  4. Forsaken

    Forsaken Well-Known Member

    I'm pretty sure that is done on purpose; most systems that use AJAX tags for displaying content do it the same way as well.
  5. Shamil

    Shamil Well-Known Member

    I think this is As Designed. You know you can use new tabs/views/windows right? Or maybe it's just me who does that.
  6. Floris

    Floris Guest

    It's working as designed and how it should be. The upside of ajax is its downside.
    However, I usually leave a page with results open and load those results that I want to see in a new tab. This way I don't have to browse around.
  7. Brandon_R

    Brandon_R Guest

    It's working as designed. The best thing to do is to open the link in a new tab, since you won't be staying in it very long anyways because as you said you go back to view other posts after browsing.
  8. Luke F

    Luke F Well-Known Member

    meh, it's still a deficiency.

    The profile page tabs are pretty close to full page AJAX, and systems like that feel very half-baked without an anchor system to accompany them. It's not just the fact that the back button doesn't work as you would expect - you can't link to the individual tabs either.
    erich37 likes this.
  9. Shamil

    Shamil Well-Known Member

    Hmm interesting point. Although, I've never found myself to be in such a situation before.
  10. Forsaken

    Forsaken Well-Known Member

    If you're going to be looking at multiple posts... Wouldn't you open each post that interests you in a new tab?

    I open every post I read in a new tab, close out ones I'm done with, and then repeat.
    gordy likes this.
  11. erich37

    erich37 Well-Known Member

    agree on the issue when clicking on the browser-back-button does not bring back the page you are expecting.
    Skipping the AJAX from the Profile-pages would get a better User-Experience. Forget about increased page-loads.

    The stuff which annoys me somehow is that when having the member-setcard open, I always need to go to the user´s profile first, before I can see the user´s list of all his postings.
    I am actually always going to the user´s "Postings", as the content of the user is much more interesting to me than the "Profile Posts".
    A direct link from the member-setcard to the user´s "Postings" would help to avoid all that clicks.
    HydraulicJack, Darkimmortal and ked38 like this.
  12. Enigma

    Enigma Well-Known Member

    It doesn't have to be 'as designed' and the problem is easy to overcome. Let me explain what Darkimmortal means. When you click on one of the tabs, add a fragment that does not have an in-page anchor to the URL. For example #info and #postings; the 'profile posts' tab needs none, since it's the default. Since there is no in-page anchor for those two fragments, you will not jump down the page when it loads. Now, when the page loads, use Javascript to detect if there is a fragment in the URL, and if so (and it matches one of the tabs) then open that tab and load its contents automatically. If Javascript is disabled, you'll have the current behaviour, if Javascript is enabled, you'll get the enhanced experience which will provide easier navigation, especially using the back button, and will allow linking to the exact page (with the currently selected tab) that you're viewing.

    Ninja Edit: Actually, this already works. Add #info or #postings to the end of the current user profile URL and it will automatically open the correct tab. The only two things to fix would be first expose the fragment (add it to the URL) when clicking the tab. This might be as easy as letting execution fall through the click handler so the clicked anchor link adds it to the URL. Second, something should be done so that if Javascript is enabled, you don't skip down the page to where the <a name> element is when going to a URL containing the fragment or when clicking a tab. The second may not be really fixable, but then again, it might be as simple as removing the <a name> elements via Javascript.
    erich37 and Darkimmortal like this.
  13. Luke F

    Luke F Well-Known Member

    Of course I would do that normally - it was just an example ;)

    Very much agreed, and adding the anchor system as Enigma explained would make it easily possible :)
  14. Mike

    Mike XenForo Developer Staff Member

    There is actually history management in one of the libraries. Unfortunately, it falls over with a <base> tag specified.
  15. Kier

    Kier XenForo Developer Staff Member

    Still no sign that the library has been updated to handle <base /> at this time.
    HydraulicJack and AlexandrosD like this.
  16. Optic

    Optic Well-Known Member

    Sorry to bump this, but it looks like XF2 takes a completely different approach to this as there is anchor text now for each profile tab? :)
  17. Chris D

    Chris D XenForo Developer Staff Member

    That's correct.

    A) We use our own tabs system rather than relying on a library
    B) We no longer use the <base /> tag in XF2

    These things have meant we have been able to resolve it.

    There was anchor links in XF1, e.g. https://xenforo.com/community/members/optic.55951/#postings

    You'll see there that the anchor selects the correct tab, but the main issue revolved around pushing the history state correctly. Due to the changes above, that's now done, so each tab you select replaces the last history state, e.g. if you navigate to the postings tab, the address bar in the browser will update and a history state with that URL will be added, click away to something else and then click back in your browser, you'll get taken back to the postings tab rather than back to the profile posts tab as it is now.
    Optic likes this.

Share This Page