03-11-2009, 11:25 PM
|
#83 (permalink)
|
|
The Contributor
Join Date: Feb 2009
Posts: 65
Thanks: 0
|
Adding it to your page is real simple. Make sure first that the page you want to see it on is a .php file (roster.php). Then just pace the code were you need it to run
HTML Code:
<html>
<body>
<!-- your html-->
<?php
//the php
?>
<!-- more html-->
</body>
</html>
To display the roster straight from the WoW web site use this block of code form my earlier post
PHP Code:
$xml = new SimpleXMLElement($rosterxml);
foreach ($xml->guild->members->children() as $char) {
echo 'Name: ' . $char['name'] . ' ';
echo 'Class: ' . $char['class'] . ' ';
echo 'Level: ' . $char['level'] . ' <br>';
}
Were you see the "echo" in that block you can just "echo" out any html formatting for each characters info
PHP Code:
echo '<tr>
<td class="roster">' . $char['name'] . '</td>
<td class="roster">' . $char['class'] . '</td>
<td class="roster">' . $char['level'] . '</td>
</tr>';
That will place each characters name, class and level in a table row.
|
|
|
|