The forum of the forums
Welcome to the Official Support Forum of Forumotion!

To take full advantage of everything offered by our forum, please log in if you are already a member, or join our community if you've not yet.



Create a free forum like this one.

Userlink on Menu

View previous topic View next topic Go down

Userlink on Menu

Post by ashik4u on October 8th 2015, 3:55 pm

Hello,
I want to make menu where will be the logged user link. After clicking the link, it will redirect him to his/her account

Code:
<a href="USERLINK VALUE">My Account</a>

ashik4u
Forumember

Male Posts : 168
Reputation : 2
Language : Bengali, English
Location : Dhaka, Bangladesh

http://bdtipsntricks.forumotion.org

Back to top Go down

Re: Userlink on Menu

Post by Zed is Not Dead on October 8th 2015, 4:07 pm

so a switch account kind of situation?

try this:

Code:
<div align="center">
           <script type="text/javascript">function switch_accounts() {jQuery.get(document.getElementById('logout').href, function() {jQuery.post('/login', 'login=1&username='+document.getElementById('switch_uname').value+'&password='+document.getElementById('switch_pass').value, function () {window.location.reload();});});}</script><img src="image url here" />        <input id="switch_uname" type="text" /><br /><input id="switch_pass" type="password" /><br /><input type="button" value="Switch Accounts" onclick="switch_accounts();" />
</div>

Zed is Not Dead
Forumember

Posts : 230
Reputation : 27
Language : English

http://fairytailonline-rp.forumotion.com/

Back to top Go down

Re: Userlink on Menu

Post by ashik4u on October 8th 2015, 4:11 pm

@Zed is Not Dead wrote:so a switch account kind of situation?

try this:

Code:
<div align="center">
           <script type="text/javascript">function switch_accounts() {jQuery.get(document.getElementById('logout').href, function() {jQuery.post('/login', 'login=1&username='+document.getElementById('switch_uname').value+'&password='+document.getElementById('switch_pass').value, function () {window.location.reload();});});}</script><img src="image url here" />        <input id="switch_uname" type="text" /><br /><input id="switch_pass" type="password" /><br /><input type="button" value="Switch Accounts" onclick="switch_accounts();" />
</div>

what will be the code for this function
Code:
<div class="categories online_menu" onMouseOver="fnShowMenu('Online');"><a href="#">My Account</a></div>
         

ashik4u
Forumember

Male Posts : 168
Reputation : 2
Language : Bengali, English
Location : Dhaka, Bangladesh

http://bdtipsntricks.forumotion.org

Back to top Go down

Re: Userlink on Menu

Post by Zed is Not Dead on October 8th 2015, 4:14 pm

That one I have no idea about, maybe ange can help

Zed is Not Dead
Forumember

Posts : 230
Reputation : 27
Language : English

http://fairytailonline-rp.forumotion.com/

Back to top Go down

Re: Userlink on Menu

Post by ashik4u on October 8th 2015, 4:31 pm

May be this thread belongs to "Scripts (Coding) Problem" forum. Sorry Sad

@Ange Tuteur help plz

ashik4u
Forumember

Male Posts : 168
Reputation : 2
Language : Bengali, English
Location : Dhaka, Bangladesh

http://bdtipsntricks.forumotion.org

Back to top Go down

View previous topic View next topic Back to top


 
Permissions in this forum:
You cannot reply to topics in this forum