Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?
- session_start();
- if(!session_is_registered(myusername)){
- header("location:main_login.php");
- }
- ?>
- <?
- echo "<BR>Account: ".$_SESSION["user"];
- //acc name
- include "config.php";
- mysql_connect(SQL_HOST, SQL_USERNAME, SQL_PASSWORD);
- mysql_select_db(SQL_DBNAME);
- $result = mysql_query("SELECT * from characters WHERE account_name='".$_SESSION["user"]."'")
- or die(mysql_error());
- echo '<form method="POST" action="view_project.php">';
- echo '<input type="hidden" name="sector" value="sector_list">';
- echo '<select name="sector_list" class="inputstandard">';
- // keeps getting the next row until there are no more to get
- while($row = mysql_fetch_array( $result )) {
- // Print out the contents of each row into a table
- echo '<option value="'.$row['char_name'].'">'.$row['char_name'].'</option>';
- }
- echo '</select>';
- echo '<input type="submit" value="Go!"> ';
- echo '</form>';
- ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement