// Connection parameters $host = 'cspp53001.cs.uchicago.edu'; $username = '******'; $password = '******'; // better ways to do this, but they had us just do this... $database = $username . 'DB'; // Attempting to connect $dbcon = mysqli_connect($host, $username, $password, $database) or die('Could not connect: ' . mysqli_connect_error()); //print 'Connected successfully!<br />'; // Getting a user //$user = $_REQUEST['user']; //$user = $_SESSION['$selected_user']; $user = $_SESSION["selected_user"]; $login = $_SESSION["login_user"]; // FUNCTION TO PRINT HEAD OF FILE, USERS STATS head_init($user, $dbcon, $login); print_follower_feed($user, $result5, $dbcon); // Closing connection mysqli_close($dbcon); function print_replies($tp) { print '<div id="reply">'; print "<li> <strong>{$tp['0']}</strong></li>"; print "<li> {$tp['1']}</li>"; print '</div>'; print '<li><br /></li>'; } function print_head($user, $tuple, $tuple2, $tuple3, $tuple4, $tuple5, $login) { print '<!DOCTYPE html>'; print '<html lang="en">';
// Connection parameters $host = 'cspp53001.cs.uchicago.edu'; $username = '******'; $password = '******'; // better ways to do this, but they had us just do this... $database = $username . 'DB'; // Attempting to connect $dbcon = mysqli_connect($host, $username, $password, $database) or die('Could not connect: ' . mysqli_connect_error()); //print 'Connected successfully!<br />'; //$user = $_REQUEST['user']; // Getting a user $user = $_SESSION["selected_user"]; $login = $_SESSION["login_user"]; $tweet_selected = $_REQUEST['tweet_selected']; // FUNCTION TO PRINT HEAD OF FILE, USERS STATS head_init($user, $dbcon, $login, $tweet_selected); print_user_feed($user, $dbcon); // Closing connection mysqli_close($dbcon); function print_replies($tp) { print '<div id="reply">'; print "<li> <strong>{$tp['0']}</strong></li>"; print "<li> {$tp['1']}</li>"; print '</div>'; print '<li><br /></li>'; } function print_head($user, $tuple, $tuple2, $tuple3, $tuple4, $tuple5, $login, $dbc, $tweet_selected) { print '<!DOCTYPE html>'; print '<html lang="en">';
session_start(); // Connection parameters $host = 'cspp53001.cs.uchicago.edu'; $username = '******'; $password = '******'; // better ways to do this, but they had us just do this... $database = $username . 'DB'; // Attempting to connect $dbcon = mysqli_connect($host, $username, $password, $database) or die('Could not connect: ' . mysqli_connect_error()); //print 'Connected successfully!<br />'; // Getting a user $user = $_SESSION["selected_user"]; $login = $_SESSION["login_user"]; $tweet = $_REQUEST['tweet']; // FUNCTION TO PRINT HEAD OF FILE, USERS STATS head_init($user, $dbcon, $login, $tweet); print_user_feed($user, $dbcon); // Closing connection mysqli_close($dbcon); function print_replies($tp) { print '<div id="reply">'; print "<li> <strong>{$tp['0']}</strong></li>"; print "<li> {$tp['1']}</li>"; print '</div>'; print '<li><br /></li>'; } function print_head($user, $tuple, $tuple2, $tuple3, $tuple4, $tuple5, $login, $tweet, $dbc) { print '<!DOCTYPE html>'; print '<html lang="en">';
// Connection parameters $host = 'cspp53001.cs.uchicago.edu'; $username = '******'; $password = '******'; // better ways to do this, but they had us just do this... $database = $username . 'DB'; // Attempting to connect $dbcon = mysqli_connect($host, $username, $password, $database) or die('Could not connect: ' . mysqli_connect_error()); //print 'Connected successfully!<br />'; //$user = $_REQUEST['user']; // Getting a user $user = $_SESSION["selected_user"]; $login = $_SESSION["login_user"]; $list = $_REQUEST['list_name']; // FUNCTION TO PRINT HEAD OF FILE, USERS STATS head_init($user, $dbcon, $login, $list); print_user_feed($user, $dbcon); // Closing connection mysqli_close($dbcon); function print_replies($tp) { print '<div id="reply">'; print "<li> <strong>{$tp['0']}</strong></li>"; print "<li> {$tp['1']}</li>"; print '</div>'; print '<li><br /></li>'; } function print_head($user, $tuple, $tuple2, $tuple3, $tuple4, $tuple5, $login, $dbc, $list) { print '<!DOCTYPE html>'; print '<html lang="en">';