Welcome to the Question2Answer Q&A. There's also a demo if you just want to try it out.
0 votes
in Q2A Core by
How could one seperate the facebook button (later openID and others) to have it always in the same place without changing the position after login / logout ?

1 Answer

+1 vote
Best answer
Use an advanced theme to override function nav($navtype) where $navtype=='user', changing the output order in that case,
edited by
I was unable to do so, as I did not find out how to check if the situation is Logged In or Logged out.
But I found a way through css with the classes defined in the script:

.qa-nav-user-item {display:inline; margin-left:6px;} <<<<< no float !

Then adding these classes:



So the Facebook button is always in the upper right, should work on the original theme as well..(I hope)

It is not very elegant, but may be someone finds it helpful..

qa_get_logged_in_userid() returns the logged in userid, or null if no user is logged in.
edited by
Thanks, this is a nice function. Does it work everywhere ? For example in sidepanel to build a users account box with some info ? Like welcome message and users latest actions from the users page or similar ? - I will play around with that..still learning.


Something like

Welcome USER+Avatar, you have actually xxx points You need only yyy to become a (usertitle) . Get x points for any question and y for answers.....