Page 1 of 1

Popup dialog help

Posted: Fri May 21, 2010 6:30 pm
by darxide
I'm trying to design an admin panel for my website. Right now it's very basic and it lets me view users, join dates, etc.

What I want to do is allow admins to pull up a list of users, click on a button next to a user name and get a dialog window that lets them perform certain functions, such as banning the user, updating user information, etc.

How do I go about that? From what I've found so far it looks like I need to use JavaScript to make the dialog window, but how do I pass info from the admin panel to the popup and then back to the admin panel?

Thanks,
~Darxide

EDIT: Also, I have a drop down box that I'm trying to eliminate the Submit button for. I'd like it to post on change. I've tried this and it doesn't work:

Code: Select all

<form action="#stats" method="POST">
	<p>
	<select name="userList">
		<option selected></option>
		<?php $i=0;
       		if($numUsers>0){
			while ($i < $numUsers) {
			$populatelist=mysql_result($userListResult,$i,"username");
			$i++;
			echo '<option onchange="this.form.submit();">'.$populatelist.'</option>'; 
			}
		}		
		?>
	</select>
	<input type="submit" name="getUserInfo" class="submit" value="Get Info" tabindex="5" />
	</p>
</form>