/[scire]/scire/Exporter.php
Gentoo

Contents of /scire/Exporter.php

Parent Directory Parent Directory | Revision Log Revision Log


Revision 42 - (show annotations) (download)
Sat Apr 22 19:26:31 2006 UTC (12 years, 7 months ago) by codeman
File size: 1418 byte(s)
updating code

1 <h2>Server Information Exporter</h2>List of clients in group:
2 <?
3 include('main_checklogin.php');
4 #This will be a core component and thus just show within scire.
5 require_once('DBInterface.php');
6
7 $clients = array();
8 if ($_POST['group']) {
9 print $_POST['group'];
10 $clients = get_group_clients($_POST['group']);
11 } else {
12 print "ALL";
13 $clients = get_all_clients();
14 }
15
16 #Get a list of the groups to put in the select box.
17 $profile_list = get_profile_list();
18 ?>
19
20 <form name="form1" method="post" action="#">
21 <select name="group" size="1">
22 <option value=""></option>
23 <?
24 foreach ($profile_list as $profile)
25 {
26 print "<option value=\"$profile[0]\">$profile[0]</option>\n";
27 }
28 ?>
29 </select>
30 <input type="submit" name="ChangeView" value="Go, because i hate doing it with javascript.">
31 </form>
32 <form name="form2" method="post" action="ExportedData.php">
33 <table><tr>
34 <th>HOSTNAME</th>
35 <th>STATUS</th>
36 <th>IP</th>
37 <th>MAC</th>
38 <th>METHOD</th>
39 <th>OTHER</th>
40 </tr>
41 <?
42 foreach ($clients as $client)
43 {
44 print "<tr><td>$client[1]</td>\n";
45 print "<td>$client[8]</td>\n";
46 print "<td>$client[3]</td>\n";
47 print "<td>$client[2]</td>\n";
48 print "<td>$client[5]</td>\n";
49 print "<td>$client[6]</td>\n";
50 }
51 ?>
52 </table>
53 <hr>
54 <input type="submit" name="ExportToXML" value="Export To XML">
55 <input type="submit" name="ExportToCSV" value="Export To CSV">
56 <input type="submit" name="ExportToTXT" value="Export To TXT">

Properties

Name Value
svn:executable *

  ViewVC Help
Powered by ViewVC 1.1.20