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)  

hostnameloop.php
Go to the documentation of this file.
1 <?php
24 require '../commons/base.inc.php';
25 try {
26  $host = $_REQUEST['host'];
27  $host = trim($host);
28  $host = base64_decode($host);
29  $host = trim($host);
31  ->set('name', $host)
32  ->load('name');
33  if ($Host->isValid()) {
34  $msg = sprintf(
35  "\t%s\n\t%s: %s",
36  _('A host with that name already exists'),
37  _('The primary mac associated is'),
38  $Host->get('mac')->__toString()
39  );
40  throw new Exception($msg);
41  }
42  $msg = '#!ok';
43 } catch (Exception $e) {
44  $msg = $e->getMessage();
45 }
46 echo $msg;
exit
exit
Definition: hostnameloop.php:47
FOGBase\getClass
static getClass($class, $data='', $props=false)
Definition: fogbase.class.php:439
$Host
$Host
Definition: hostnameloop.php:30
$msg
if($Host->isValid()) $msg
Definition: hostnameloop.php:42
$host
$host
Definition: hostnameloop.php:27