MyBB Community Forums

Full Version: Account Switcher Mod
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
First things first: I know this mod isn't offered anymore, however a friend of mine gave me a copy and I patched it to fix the security issue.

The problem: It works perfectly, but I was wondering if there was a way to get the list of subaccounts to go into a dropdown menu.

[Image: IyWtW7a.png]

That is the way they are listed regularly.

And heres the code from the different templates:

as_header
<hr />{$as_header_userbit}

as_usercp
<html><head><title>{$mybb->settings['bbname']} - {$lang->as_name}</title>{$headerinclude}</head>
						<body>
						{$header}
						<table width="100%" border="0" align="center">
							<tr>
							{$usercpnav}
								<td valign="top">
									<table border="0" cellspacing="{$theme['borderwidth']}" cellpadding="{$theme['tablespace']}" class="tborder" style="position:relative; top:50px; left:258px;">
										<tr><td class="thead" colspan="2" style="position:relative; top:5px; left:0px;"><strong>{$lang->as_name}</strong></td></tr>
										<tr>
											<td class="trow1" valign="top">
												<fieldset class="trow2">
													<legend><strong>{$lang->as_usercp_options}</strong></legend>
													{$as_usercp_options}
												</fieldset>
											</td></style>
											{$as_usercp_users}
										</tr>
									</table></style>
								</td>
							</tr>
						</table>
						{$footer}
						</body>
						</html>
as_usercp_nav
<tr><td class="trow1 smalltext"><a href="usercp.php?action=as_edit" class="usercp_nav_item usercp_nav_usergroups">{$lang->as_name}</a></td></tr>
as_usercp_options
<form method="post" action="usercp.php">
						<input type="hidden" name="my_post_key" value="{$mybb->post_code}" />
							{$as_usercp_input}
						</table>
						</form>
as_usercp_userbit
<tr><td>
							<form method="post" action="usercp.php">
							<input type="hidden" name="my_post_key" value="{$mybb->post_code}" />
							<input type="hidden" name="action" value="as_detachuser" />
							<input type="hidden" name="uid" value="{$attachedOneUID}" />
							<table width="100%" border="0" style="border:1px solid #000;margin:2px 0;padding:3px;" class="trow1">
								<tr>
									<td>{$attachedOneName}</td>
									<td align="right">
										<input type="submit" value="{$lang->as_detachuser}" name="{$lang->as_detachuser}" class="button" />
									</td>
								</tr>
							</table>
							</form>
						</td></tr>
as_usercp_users
<td class="trow1" valign="top">
							<fieldset class="trow2">
								<legend><strong>{$lang->as_usercp_users}</strong></legend>
								<table cellspacing="0" cellpadding="{$theme['tablespace']}">
									<tr><td>{$lang->as_usercp_attached}</td></tr>
									{$as_usercp_userbit}
								</table>
							</fieldset>
						</td>