Support Forum

Opening first tab on user profile

CE cwwcwi0ecnuwijcowecwreiovuejwcko
cwwcwi0ecnuwijcowecwreiovuejwcko
Member

I have disabled the first “Profile” tab completely in “Profile Tabs & Menus”. So my first tab on the users forum profile should be “Options” now. The only problem is that this “Options” tab is not opened by default (like the profile tab). I need to click it first.

Just tried to move the “Options” tab above the “Profile” tab, but the behavior doesn’t change. Looks like the auto expanding tab is statically set on “Profile”.

5 Answers

New Answer

MP Mr Papa
Mr Papa
Member

yes… but you can change it…  in your theme, you will find the template function that launches the profile…

sp_ProfileEdit()

just change it to

sp_ProfileEdit(‘options’);

and that one will come up by default…

but in your case, what was coming up?  nothing?  will have to make sure there is fallback in place if there isnt a profile tab – not sure anyone has ever removed that tab… ;)

CE cwwcwi0ecnuwijcowecwreiovuejwcko
cwwcwi0ecnuwijcowecwreiovuejwcko
Member

I refer users to the WordPress profile page, so I don’t need that tab. Keeping everything minimalistic. The tabs are loaded but the first one, in my case “Options” is not opened. But it works good after clicking the tab :)

Guess it has something to do with jQuery activating the first tab. Your suggestion work great. Thanks!

Before click (without fix):

before.jpeg

After click (without fix):

after.jpeg

 

 

MP Mr Papa
Mr Papa
Member

yeah, what i was saying…  have opened a ticket for a fallback if the selected tab does not exist to pick the first tab in the list…

but you can always select any tab to open first as I detailed…  thanks for the heads up…

CE cwwcwi0ecnuwijcowecwreiovuejwcko
cwwcwi0ecnuwijcowecwreiovuejwcko
Member

Ok, thanks. I see spProfileTabs is using “ul li” to format. Maybe the jQuery tab loader can activate the ul li:first-child by default.

MP Mr Papa
Mr Papa
Member

have already made a code change to handle this… easier to handle in the tab passed in the ajax… but thanks!