Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- $con = mysql_connect( "localhost","root","root" );
- $list = "";
- if ( !$con ){
- die( 'Could not connect: ' . mysql_error() );
- } else {
- mysql_select_db( "lolerstream", $con );
- $query = "SELECT * FROM suggestions";
- $result = mysql_query( $query,$con ) or die( 'Could not execute query: ' . mysql_error() );
- while ( $row = mysql_fetch_array( $result ) ) {
- $list = $list + " <div class='suggestion'> $row['submitdate'] -\t $row['contents'] </div> \n ";
- }
- }
- mysql_close($con);
- ?>
Advertisement
Add Comment
Please, Sign In to add comment