Re: [PHP] Avatar Displaying?
What's the script doing now vs what you want it to do?
Also you should use quotes on your HTML tags ;)
PHP Code:
while ($row = mysql_fetch_assoc($getposts))
{
$id = $row['id'];
$name = $row['name'];
$body = $row['body'];
$date = $row['date'];
echo '<table>
<tr>
<td>
<img src="http://forum.ragezone.com/images/'.$id.'.png" />
</td>
<td>
<br /> <br />
'.$name.' ~ '.$date.'<br />
<hr width="40" align="left" />
'.$body.'<br /><br /><br />
</td>
</tr>
</table>';
}
Re: [PHP] Avatar Displaying?
Quote:
Originally Posted by
s-p-n
What's the script doing now vs what you want it to do?
Also you should use quotes on your HTML tags ;)
PHP Code:
while ($row = mysql_fetch_assoc($getposts))
{
$id = $row['id'];
$name = $row['name'];
$body = $row['body'];
$date = $row['date'];
echo '<table>
<tr>
<td>
<img src="http://forum.ragezone.com/images/'.$id.'.png" />
</td>
<td>
<br /> <br />
'.$name.' ~ '.$date.'<br />
<hr width="40" align="left" />
'.$body.'<br /><br /><br />
</td>
</tr>
</table>';
}
Thanks Spence, helped me clean the code up, but no dice.
Not sure what the problem is.
I'm gonna take it a different route and use a MySQL DB for displaying the path.
---------- Post added at 01:30 PM ---------- Previous post was at 01:21 PM ----------
Thanks again for the help Spence!
Got it working now!
I just used your code, added a row on the table in my DB called images.
Then used that to display the avatar. Works like a charm!