Jump to content

Archived

This topic is now archived and is closed to further replies.

Zoski

Help with formating PHP results

Recommended Posts

Hello, I have a PHP script that is getting information from BF2s.com and displaying the results on my site.  The problem is that I have no idea ??? how to make the results display in a presentable fashion. Here is a link and you will see what I mean... http://www.zoski.com/ebfstats_menu/battlefield.php
I would like to have the results in either a grid or at least with some space in between them.
Thanks for your help!!

Share this post


Link to post
Share on other sites
'Formatting' the output is just a matter of separating each piece of data for each row and adding space around them or placing each one separately in <td></td> cells with a new row for each row of results.

Share this post


Link to post
Share on other sites
The current code already is using the <td>:

[quote]function showList($sortby = 'score', $format = '<tr><td><a href="{LINK}">{NICK}</a></td><td>{SCORE}</td><td>{KDR}</td><td>{TIME}</td></tr>') {
$this->log("showList($sortby, $format )");
[/quote]
any ideas?

Share this post


Link to post
Share on other sites
then (re)define the opening html table so that it has cellpadding or cellspacing to suit your needs. For bonus points, define the style of text in a td element in a CSS style declaration in the html.

Share this post


Link to post
Share on other sites
Thanks for your guidance AndyB, I somehow managed to get it looking decent (Check it out). I will work on the bonus later.

Thanks!  :P

Share this post


Link to post
Share on other sites

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.