sweet, almost there. I have the script resolving UID to rule numbers now. Thanks heaps 🙂 The last part is generating the html tables. I have the following array defined as $raw;
[4] => Array
(
[0] => 777
[1] => 592
[2] => 592
[3] => 777
)
[5] => Array
(
[0] => 94008E69-9822-4031-8DB8-75FA70F72F50
[1] => 983269E8-9D56-40A9-A524-B4DF88F62CB9
[2] => 983269E8-9D56-40A9-A524-B4DF88F62CB9
[3] => 94008E69-9822-4031-8DB8-75FA70F72F50
my PHP table code looks like the following:
<?php
echo "<table border=\"1\" cellspacing=0><tr><td>source</td><td>dest</td><td>proto</td><td>port</td><td>policy</td><td>hits</td><tr>";
$num = count($raw[1]);
while ($num > -1) {
echo "<tr><td>" .$raw[1][$num]. "</td></td><td>" .$raw[2][0]. "</td><td>" .$raw[3][0]. "</td><td>" .$raw[4][0]. "</td><td>" .$resolution[1]. "</td><td>hits</td><tr>";
$num = num -1;
}
php?>
When using something like .$raw[2][0]., it works fine. When using the dynamic equivalent .$raw[2][$num]. it doesnt show anything. I figure it's translating the $num part, however I'm not quite sure why. What have I done wrong here?