fogproject  1.5.9
About: FOG is a Linux-based network computer cloning solution for Windows, Mac OSX and various Linux distributions that ties together a few open-source tools with a PHP-based web interface. FOG doesn’t use any boot disks, or CDs; everything is done via TFTP and PXE.
  Fossies Dox: fogproject-1.5.9.tar.gz  ("unofficial" and yet experimental doxygen-generated source code documentation)  

printerlisting.php
Go to the documentation of this file.
1 <?php
22 require '../commons/base.inc.php';
23 try {
24  $printerCount = FOGCore::getClass('PrinterManager')
25  ->count();
26  if ($printerCount < 1) {
27  throw new Exception("#!np\n");
28  }
29  echo "#!ok\n";
32  'Printer',
33  array('id' => $printerids),
34  'name'
35  );
36  foreach ((array)$printerids as $index => $printerid) {
37  $name = $printernames[$index];
38  echo "#printer$index=$name\n";
39  unset(
40  $name,
41  $index,
42  $printerids[$index],
43  $printerid,
44  $printernames[$index]
45  );
46  }
47 } catch (Exception $e) {
48  echo $e->getMessage();
49 }
FOGBase\getClass
static getClass($class, $data='', $props=false)
Definition: fogbase.class.php:439
$printernames
$printernames
Definition: printerlisting.php:31
$printerids
$printerids
Definition: printerlisting.php:30
exit
foreach((array) $printerids as $index=> $printerid) catch(Exception $e) exit
Definition: printerlisting.php:47
FOGBase\getSubObjectIDs
static getSubObjectIDs( $object='Host', $findWhere=array(), $getField='id', $not=false, $operator='AND', $orderBy='name', $groupBy=false, $filter='array_unique')
Definition: fogbase.class.php:2006