Porkie Posted September 15, 2009 Share Posted September 15, 2009 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /> </head> <?php { require('core.inc.php'); echo page_header(Members); echo '<LINK href="GR_style.css" rel="stylesheet" type="text/css">'; echo $error; } $q = "SELECT * FROM gg_users WHERE type = 'Administrator' ORDER BY name ASC"; $sql4 = mysql_query($q); echo '<P CLASS="style2">'; echo 'Administrator'; echo '</P>'; echo ("<br/>"); echo '<table>'; echo '<tr></tr>'; echo '<tr>'; while ($row = mysql_fetch_assoc($sql4)) { echo '<td width="75pt" align="left">'; echo '<P CLASS="style1">'; echo $row['name']; echo '<img style="width:80px;height:80px;" src="img/avatar/'.$row['avatar'].'.jpg" />'; echo '<a href="mailto:'.$row['email'].'">Email '.$row['name'].'</a>'; echo '</P>'; echo '</td>'; } echo '</tr>'; echo '</table>'; echo '<br>'; $q = "SELECT * FROM gg_users WHERE type = 'Music Enthusiast' ORDER BY name ASC"; $sql2 = mysql_query($q); echo '<P CLASS="style2">'; echo 'Music Enthusiasts'; echo '</P>'; echo ("<br/>"); echo '<table>'; echo '<tr></tr>'; echo '<tr>'; while ($row = mysql_fetch_assoc($sql2)) { echo '<td width="75pt" align="left">'; echo '<P CLASS="style1">'; echo $row['name']; echo '</P>'; echo '<img style="width:80px;height:80px;" src="img/avatar/'.$row['avatar'].'.jpg" />'; echo '</td>'; } echo '</tr>'; echo '</table>'; echo '<br>'; $q = "SELECT * FROM gg_users WHERE type = 'Band Members' ORDER BY name ASC"; $sql3 = mysql_query($q); echo '<P CLASS="style2">'; echo 'Band Members'; echo '</P>'; echo ("<br/>"); echo '<table>'; echo '<tr></tr>'; echo '<tr>'; while ($row = mysql_fetch_assoc($sql3)) { echo '<td width="75pt" align="left">'; echo '<P CLASS="style1">'; echo $row['name']; echo '</P>'; echo '<img style="width:80px;height:80px;" src="img/avatar/'.$row['avatar'].'.jpg" />'; echo '</td>'; } echo '</tr>'; echo '</table>'; echo page_footer(); ?> could anyone please clear out the crap in this page that isnt needed =( , i dont know the stuff that is needed and the stuff that isnt. iam still learnin how to write code however i know most off this isnt necessarily needed. cheers Link to comment https://forums.phpfreaks.com/topic/174369-code-clear-out/ Share on other sites More sharing options...
mikesta707 Posted September 15, 2009 Share Posted September 15, 2009 how are we supposed to know what is or isn't needed in this code... Link to comment https://forums.phpfreaks.com/topic/174369-code-clear-out/#findComment-919119 Share on other sites More sharing options...
Porkie Posted September 15, 2009 Author Share Posted September 15, 2009 its all needed however i mean strip it down, such as are all the "echos" needed etc, or is there an easyier way off not having to write out all the "echos" . Link to comment https://forums.phpfreaks.com/topic/174369-code-clear-out/#findComment-919128 Share on other sites More sharing options...
mikesta707 Posted September 15, 2009 Share Posted September 15, 2009 if you don't want all the echos, condense what you are echoing into 1 or 2 lines... but it doesn't matter really... Link to comment https://forums.phpfreaks.com/topic/174369-code-clear-out/#findComment-919141 Share on other sites More sharing options...
MatthewJ Posted September 15, 2009 Share Posted September 15, 2009 Yeah, I was bored <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /> </head> <?php { require('core.inc.php'); echo page_header(Members); echo '<LINK href="GR_style.css" rel="stylesheet" type="text/css">'; echo $error; } $q = "SELECT * FROM gg_users WHERE type = 'Administrator' ORDER BY name ASC"; $sql4 = mysql_query($q); echo '<P CLASS="style2">Administrator</P><br/><table><tr></tr><tr>'; while ($row = mysql_fetch_assoc($sql4)) { echo '<td width="75pt" align="left"><P CLASS="style1">'.$row['name'].'<img style="width:80px;height:80px;" src="img/avatar/'.$row['avatar'].'.jpg" /><a href="mailto:'.$row['email'].'">Email '.$row['name'].'</a></P></td>'; } echo '</tr></table><br>'; $q = "SELECT * FROM gg_users WHERE type = 'Music Enthusiast' ORDER BY name ASC"; $sql2 = mysql_query($q); echo '<P CLASS="style2">Music Enthusiasts</P><br/><table><tr></tr><tr>'; while ($row = mysql_fetch_assoc($sql2)) { echo '<td width="75pt" align="left"><P CLASS="style1">'.$row['name'].'</P><img style="width:80px;height:80px;" src="img/avatar/'.$row['avatar'].'.jpg" /></td>'; } echo '</tr></table><br>'; $q = "SELECT * FROM gg_users WHERE type = 'Band Members' ORDER BY name ASC"; $sql3 = mysql_query($q); echo '<P CLASS="style2">Band Members</P><br/><table><tr></tr><tr>'; while ($row = mysql_fetch_assoc($sql3)) { echo '<td width="75pt" align="left"><P CLASS="style1">'.$row['name'].'</P><img style="width:80px;height:80px;" src="img/avatar/'.$row['avatar'].'.jpg" /></td>'; } echo '</tr></table>'; echo page_footer(); ?> Link to comment https://forums.phpfreaks.com/topic/174369-code-clear-out/#findComment-919155 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.