3 admin_externalpage_print_header();
5 $currenttab = 'mnetdetails';
6 require_once($CFG->dirroot
.'/admin/mnet/tabs.php');
8 print_simple_box_start("center", "");
10 <form method=
"post" action=
"peers.php">
12 <input type=
"hidden" name=
"sesskey" value=
"<?php echo $USER->sesskey ?>" />
13 <input type
="hidden" name
="step" value
="commit" />
14 <input type
="hidden" name
="last_connect_time" value
="<?php echo $mnet_peer->last_connect_time; ?>" />
15 <input type
="hidden" name
="id" value
="<?php echo isset($mnet_peer->id)? $mnet_peer->id : '0' ; ?>" />
16 <input type
="hidden" name
="applicationid" value
="<?php echo isset($mnet_peer->applicationid)? $mnet_peer->applicationid : '0' ; ?>" />
17 <input type
="hidden" name
="applicationname" value
="<?php echo isset($mnet_peer->application->name)? $mnet_peer->application->name : '' ; ?>" />
18 <table cellpadding
="9" cellspacing
="0" width
="635">
21 <td align
="right" valign
="top"><?php
print_string('site'); ?>:
</td>
22 <td valign=
"top"><input type=
"text" name=
"name" size=
"30" value=
"<?php echo $mnet_peer->name; ?>" /></td
>
25 <td align
="right" valign
="top"><?php
print_string('hostname', 'mnet'); ?>:
</td>
26 <td valign=
"top"><input type=
"text" name=
"wwwroot" size=
"30" value=
"<?php echo $mnet_peer->wwwroot; ?>" /></td
>
29 if (empty($mnet_peer->public_key
)) $mnet_peer->public_key
= '';
32 <td align=
"right" valign=
"top"><?php
33 print_string('publickey', 'mnet');
35 helpbutton("publickey", get_string('publickey', 'mnet'), "mnet", true, true);
41 if (isset($mnet_peer->deleted
) && $mnet_peer->deleted
> 0) {
42 $key = mnet_get_public_key($mnet_peer->wwwroot
, $mnet_peer->application
->xmlrpc_server_url
);
43 $mnet_peer->public_key
= clean_param($key, PARAM_PEM
);
48 if (empty($mnet_peer->public_key
)) {
49 print_string('nopubkey', 'mnet');
52 <textarea rows=
"17" cols=
"65" name=
"public_key" style=
"font-size: 8px;"><?php echo $mnet_peer->public_key
; ?></textarea>
56 <td align=
"right" valign=
"top"><?php print_string('expires', 'mnet'); ?>:
</td>
59 if($mnet_peer->public_key_expires
< time()) {
60 print_string('expired', 'mnet');
63 echo userdate($mnet_peer->public_key_expires
);
69 if(!empty($currentkey)) {
72 <td align=
"right" valign=
"top"></td>
73 <td valign=
"top"><?php print_string('keymismatch', 'mnet'); ?></td>
76 <td align=
"right" valign=
"top"><?php print_string('currentkey', 'mnet'); ?>:
</td>
77 <td valign=
"top"><pre style=
"font-size: 8px;"><?php echo $currentkey;?></pre></td>
82 if (isset($mnet_peer->id
) && $mnet_peer->id
> 0) {
85 <td align=
"right" valign=
"top"><?php print_string('last_connect_time', 'mnet'); ?>:
</td>
86 <td valign=
"top"><?php echo ($mnet_peer->last_connect_time
== 0)?
get_string('never','mnet') : date('H:i:s d/m/Y',$mnet_peer->last_connect_time
);?></td>
91 if (isset($mnet_peer->deleted
) && $mnet_peer->deleted
> 0){
94 <td align=
"right" valign=
"top"><?php print_string('deleted'); ?>:
</td>
96 <input type=
"radio" name=
"deleted" value=
"0" checked=
"checked" /> <?php print_string('reenableserver','mnet'); ?><br />
97 <input type=
"radio" name=
"deleted" value=
"1" /> <?php print_string('yes'); ?><br />
103 if (isset($mnet_peer->ip_address
) && '' != $mnet_peer->ip_address
){
106 <td align=
"right" valign=
"top"><?php print_string('ipaddress', 'mnet');
108 helpbutton("ipaddress", get_string('ipaddress', 'mnet'), "mnet", true, true);
110 <td valign=
"top"><?php echo $mnet_peer->ip_address
; ?></td>
118 <td><input type=
"submit" value=
"<?php print_string("savechanges
"); ?>" /></td
>
124 print_simple_box_end();
125 admin_externalpage_print_footer();