Subversion Repositories slis

Rev

Rev 5501 | Rev 5689 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 5501 Rev 5633
Line 1... Line 1...
1
<?PHP
1
<?PHP
2
/* $Id: make.php 5501 2008-09-26 08:49:17Z plb $
2
/* $Id: make.php 5633 2008-12-17 09:55:15Z plb $
3

3

4
This script has been written by Bruno Bzeznik
4
This script has been written by Bruno Bzeznik
5
Copyright (C) 2002 Bruno Bzeznik <Bruno@ac-grenobole.fr>
5
Copyright (C) 2002 Bruno Bzeznik <Bruno@ac-grenobole.fr>
6

6

7
This script is released under GNU Public Licence (GPL)
7
This script is released under GNU Public Licence (GPL)
Line 352... Line 352...
352
    // SLIS Variables
352
    // SLIS Variables
353
    $name = $slis->name;
353
    $name = $slis->name;
354
    $type = trim($slis->type);
354
    $type = trim($slis->type);
355
    $cnet = find_net($slis->ip_wan,$slis->netmask_wan);
355
    $cnet = find_net($slis->ip_wan,$slis->netmask_wan);
356
    $network_wan = $cnet[network];
356
    $network_wan = $cnet[network];
-
 
357
    $cidr_wan = $cnet[cidr];
357
    $cnet = find_net($slis->ip_lan,$slis->netmask_lan);
358
    $cnet = find_net($slis->ip_lan,$slis->netmask_lan);
358
    $network_lan = $cnet[network];
359
    $network_lan = $cnet[network];
-
 
360
    $cidr_lan = $cnet[cidr];
359
    $varlist += array(
361
    $varlist += array(
360
            "%slis_type%"        => $type,
362
            "%slis_type%"        => $type,
361
            "%slis_name%"        => $name,
363
            "%slis_name%"        => $name,
362
            "%slis_version%"     => $slis->version,
364
            "%slis_version%"     => $slis->version,
363
            "%slis_gateway%"     => $slis->ip_gateway,
365
            "%slis_gateway%"     => $slis->ip_gateway,
364
            "%slis_is_isdn%"     => $slis->is_isdn,
366
            "%slis_is_isdn%"     => $slis->is_isdn,
365
            "%slis_wan_ip%"      => ( $slis->is_isdn == 't' ? $slis->ip_lan : $slis->ip_wan),
367
            "%slis_wan_ip%"      => ( $slis->is_isdn == 't' ? $slis->ip_lan : $slis->ip_wan),
366
            "%slis_wan_netmask%" => ( $slis->is_isdn == 't' ? $slis->netmask_lan : $slis->netmask_wan),
368
            "%slis_wan_netmask%" => ( $slis->is_isdn == 't' ? $slis->netmask_lan : $slis->netmask_wan),
367
            "%slis_wan_network%" => ( $slis->is_isdn == 't' ? $network_lan : $network_wan),
369
            "%slis_wan_network%" => ( $slis->is_isdn == 't' ? $network_lan : $network_wan),
-
 
370
            "%slis_wan_cidr%"    => ( $slis->is_isdn == 't' ? $cidr_lan : $cidr_wan),
368
            "%slis_lan_ip%"      => $slis->ip_lan,
371
            "%slis_lan_ip%"      => $slis->ip_lan,
369
            "%slis_lan_netmask%" => $slis->netmask_lan,
372
            "%slis_lan_netmask%" => $slis->netmask_lan,
370
            "%slis_lan_network%" => $network_lan,
373
            "%slis_lan_network%" => $network_lan,
-
 
374
            "%slis_lan_cidr%"    => $cidr_lan,
371
            "%is_cyberschool%"   => ( $slis->is_cyber_school != 't' ? '0' : '1'),
375
            "%is_cyberschool%"   => ( $slis->is_cyber_school != 't' ? '0' : '1'),
372
            "%samba%"            => ( $slis->is_cyber_school != 't' ? '0' : '1'),
376
            "%samba%"            => ( $slis->is_cyber_school != 't' ? '0' : '1'),
373
            "%fetchmail%"        => ($slis->is_fetchmail != 't' ? '0' : '1' ),
377
            "%fetchmail%"        => ($slis->is_fetchmail != 't' ? '0' : '1' ),
374
            "%gateway_type%"     => $slis->gateway_type,
378
            "%gateway_type%"     => $slis->gateway_type,
375
            "%gateway_user%"     => $slis->gateway_user,
379
            "%gateway_user%"     => $slis->gateway_user,