Replace php short tags as they are as portable as standard <?php. In other words in the php.ini short tags is off by default.

This commit is contained in:
Mark Crane
2013-07-15 22:32:43 +00:00
parent 3eddead2a0
commit ad27dc407d
2 changed files with 66 additions and 66 deletions

View File

@@ -34,7 +34,7 @@ function hide_advanced_config() {
<tr>
<td align='left' width="50%">
<strong>
<?
<?php
if ($action == "update") {
echo $text['header-xmpp-edit'];
}
@@ -44,13 +44,13 @@ function hide_advanced_config() {
?>
</strong><br>
</td> <td width='50%' align='right'>
<input type='submit' name='submit' class='btn' value='<?=$text['button-save']?>'>
<input type='button' class='btn' name='' alt='back' onclick="window.location='xmpp.php'" value='<?=$text['button-back']?>'>
<input type='submit' name='submit' class='btn' value='<?php echo $text['button-save']?>'>
<input type='button' class='btn' name='' alt='back' onclick="window.location='xmpp.php'" value='<?php echo $text['button-back']?>'>
</td>
</tr>
<tr>
<td align='left' colspan='2'>
<?=$text['description-xmpp-edit-add']?><br />
<?php echo $text['description-xmpp-edit-add']?><br />
</td>
</tr>
</table>
@@ -60,70 +60,70 @@ function hide_advanced_config() {
<tr>
<td width="30%" class='vncellreq' valign='top' align='left' nowrap='nowrap'>
<?=$text['label-profile_name']?>:
<?php echo $text['label-profile_name']?>:
</td>
<td width="70%" class='vtable' align='left'>
<input class='formfld' type='text' name='profile_name' maxlength='255' value="<?php echo $profile['profile_name']; ?>">
<br />
<?=$text['description-profile_name']?>
<?php echo $text['description-profile_name']?>
</td>
</tr>
<tr>
<td class='vncellreq' valign='top' align='left' nowrap='nowrap'>
<?=$text['label-username']?>:
<?php echo $text['label-username']?>:
</td>
<td class='vtable' align='left'>
<input class='formfld' type='text' name='profile_username' autocomplete='off' maxlength='255' value="<?php echo $profile['profile_username'];?>">
<br />
<?=$text['description-username']?>
<?php echo $text['description-username']?>
</td>
</tr>
<tr>
<td class='vncellreq' valign='top' align='left' nowrap='nowrap'>
<?=$text['label-password']?>:
<?php echo $text['label-password']?>:
</td>
<td class='vtable' align='left'>
<input class='formfld' type='password' name='profile_password' autocomplete='off' id='profile_password' maxlength='50' onfocus="document.getElementById('show_profile_password').innerHTML = '<?=$text['label-password']?>: '+document.getElementById('profile_password').value;" value="<?php echo $profile['profile_password'];?>">
<input class='formfld' type='password' name='profile_password' autocomplete='off' id='profile_password' maxlength='50' onfocus="document.getElementById('show_profile_password').innerHTML = '<?php echo $text['label-password']?>: '+document.getElementById('profile_password').value;" value="<?php echo $profile['profile_password'];?>">
<br />
<span onclick="document.getElementById('show_profile_password').innerHTML = ''"><?=$text['description-password']?> </span><span id='show_profile_password'></span>
<span onclick="document.getElementById('show_profile_password').innerHTML = ''"><?php echo $text['description-password']?> </span><span id='show_profile_password'></span>
</td>
</tr>
<tr>
<td class='vncellreq' valign='top' align='left' nowrap='nowrap'>
<?=$text['label-auto_login']?>:
<?php echo $text['label-auto_login']?>:
</td>
<td class='vtable' align='left'>
<select class='formfld' name='auto_login'>
<option value='true' <?php if($profile['auto_login'] == "true") echo "selected='selected'"; ?>><?=$text['label-true']?></option>
<option value='false' <?php if($profile['auto_login'] == "false") echo "selected='selected'"; ?>><?=$text['label-false']?></option>
<option value='true' <?php if($profile['auto_login'] == "true") echo "selected='selected'"; ?>><?php echo $text['label-true']?></option>
<option value='false' <?php if($profile['auto_login'] == "false") echo "selected='selected'"; ?>><?php echo $text['label-false']?></option>
</select>
<br />
<?=$text['description-auto_login']?>
<?php echo $text['description-auto_login']?>
</td>
</tr>
<tr>
<td width='30%' class='vncell' valign='top' align='left' nowrap='nowrap'>
<?=$text['label-xmpp_server']?>:
<?php echo $text['label-xmpp_server']?>:
</td>
<td width='70%' class='vtable' align='left'>
<input class='formfld' type='text' name='xmpp_server' maxlength='255' value="<?php echo $profile['xmpp_server'];?>">
<br />
<?=$text['description-xmpp_server']?>
<?php echo $text['description-xmpp_server']?>
</td>
</tr>
<tr>
<td class='vncellreq' valign='top' align='left' nowrap='nowrap'>
<?=$text['label-default_exten']?>:
<?php echo $text['label-default_exten']?>:
</td>
<td class='vtable' align='left'>
<input class='formfld' type='text' name='default_exten' maxlength='255' value="<?php echo $profile['default_exten'];?>">
<br />
<?=$text['description-default_exten']?>
<?php echo $text['description-default_exten']?>
</td>
</tr>
@@ -132,9 +132,9 @@ function hide_advanced_config() {
<div id="show_advanced_box">
<table width="100%" border="0" cellpadding="6" cellspacing="0">
<tr>
<td width="30%" valign="top" class="vncell"><?=$text['label-advanced']?></td>
<td width="30%" valign="top" class="vncell"><?php echo $text['label-advanced']?></td>
<td width="70%" class="vtable">
<input type="button" onClick="show_advanced_config()" value="<?=$text['button-advanced']?>"></input>
<input type="button" onClick="show_advanced_config()" value="<?php echo $text['button-advanced']?>"></input>
</td>
</tr>
</table>
@@ -144,40 +144,40 @@ function hide_advanced_config() {
<tr>
<?php if (if_group("superadmin")) { ?>
<td class='vncellreq' valign='top' align='left' nowrap='nowrap'>
<?=$text['label-context']?>:
<?php echo $text['label-context']?>:
</td>
<td class='vtable' align='left'>
<input class='formfld' type='text' name='context' maxlength='255' value="<?php echo $profile['context'];?>">
<br />
<?=$text['description-context']?>
<?php echo $text['description-context']?>
</td>
</tr>
<?php } ?>
<tr>
<td class='vncellreq' valign='top' align='left' nowrap='nowrap'>
<?=$text['label-rtp_ip']?>:
<?php echo $text['label-rtp_ip']?>:
</td>
<td class='vtable' align='left'>
<input class='formfld' type='text' name='rtp_ip' maxlength='255' value="<?php echo $profile['rtp_ip'];?>">
<br />
<?=$text['description-rtp_ip']?>
<?php echo $text['description-rtp_ip']?>
</td>
</tr>
<tr>
<td class='vncellreq' valign='top' align='left' nowrap='nowrap'>
<?=$text['label-ext_rtp_ip']?>:
<?php echo $text['label-ext_rtp_ip']?>:
</td>
<td class='vtable' align='left'>
<input class='formfld' type='text' name='ext_rtp_ip' maxlength='255' value="<?php echo $profile['ext_rtp_ip'];?>">
<br />
<?=$text['description-ext_rtp_ip']?>
<?php echo $text['description-ext_rtp_ip']?>
</td>
</tr>
<tr>
<td class='vncellreq' valign='top' align='left' nowrap='nowrap'>
<?=$text['label-sasl_type']?>:
<?php echo $text['label-sasl_type']?>:
</td>
<td class='vtable' align='left'>
<select class='formfld' name='sasl_type'>
@@ -185,71 +185,71 @@ function hide_advanced_config() {
<option value='md5' <?php if($profile['sasl_type'] == "md5") echo "selected='selected'"; ?>>MD5</option>
</select>
<br />
<?=$text['description-sasl_type']?>
<?php echo $text['description-sasl_type']?>
</td>
</tr>
<tr>
<td class='vncell' valign='top' align='left' nowrap='nowrap'>
<?=$text['label-tls_enable']?>:
<?php echo $text['label-tls_enable']?>:
</td>
<td class='vtable' align='left'>
<select class='formfld' name='tls_enable'>
<option value='true' <?php if($profile['tls_enable'] == "true") echo "selected='selected'"; ?>><?=$text['label-true']?></option>
<option value='false' <?php if($profile['tls_enable'] == "false") echo "selected='selected'"; ?>><?=$text['label-false']?></option>
<option value='true' <?php if($profile['tls_enable'] == "true") echo "selected='selected'"; ?>><?php echo $text['label-true']?></option>
<option value='false' <?php if($profile['tls_enable'] == "false") echo "selected='selected'"; ?>><?php echo $text['label-false']?></option>
</select>
<br />
<?=$text['description-tls_enable']?>
<?php echo $text['description-tls_enable']?>
</td>
</tr>
<tr>
<td class='vncell' valign='top' align='left' nowrap='nowrap'>
<?=$text['label-use_rtp_timer']?>:
<?php echo $text['label-use_rtp_timer']?>:
</td>
<td class='vtable' align='left'>
<select class='formfld' name='use_rtp_timer'>
<option value='true' <?php if($profile['use_rtp_timer'] == "true") echo "selected='selected'"; ?>><?=$text['label-true']?></option>
<option value='false' <?php if($profile['use_rtp_timer'] == "false") echo "selected='selected'"; ?>><?=$text['label-false']?></option>
<option value='true' <?php if($profile['use_rtp_timer'] == "true") echo "selected='selected'"; ?>><?php echo $text['label-true']?></option>
<option value='false' <?php if($profile['use_rtp_timer'] == "false") echo "selected='selected'"; ?>><?php echo $text['label-false']?></option>
</select>
<br />
<?=$text['description-use_rtp_timer']?>
<?php echo $text['description-use_rtp_timer']?>
</td>
</tr>
<tr>
<td class='vncell' valign='top' align='left' nowrap='nowrap'>
<?=$text['label-vad']?>:
<?php echo $text['label-vad']?>:
</td>
<td class='vtable' align='left'>
<select class='formfld' name='vad'>
<option value='none' <?php if($profile['vad'] == "none") echo "selected='selected'"; ?>><?=$text['option-vad_none']?></option>
<option value='in' <?php if($profile['vad'] == "in") echo "selected='selected'"; ?>><?=$text['option-vad_in']?></option>
<option value='out' <?php if($profile['vad'] == "out") echo "selected='selected'"; ?>><?=$text['option-vad_out']?></option>
<option value='both' <?php if($profile['vad'] == "both") echo "selected='selected'"; ?>><?=$text['option-vad_both']?></option>
<option value='none' <?php if($profile['vad'] == "none") echo "selected='selected'"; ?>><?php echo $text['option-vad_none']?></option>
<option value='in' <?php if($profile['vad'] == "in") echo "selected='selected'"; ?>><?php echo $text['option-vad_in']?></option>
<option value='out' <?php if($profile['vad'] == "out") echo "selected='selected'"; ?>><?php echo $text['option-vad_out']?></option>
<option value='both' <?php if($profile['vad'] == "both") echo "selected='selected'"; ?>><?php echo $text['option-vad_both']?></option>
</select>
<br />
<?=$text['description-vad']?>
<?php echo $text['description-vad']?>
</td>
</tr>
<tr>
<td class='vncell' valign='top' align='left' nowrap='nowrap'>
<?=$text['label-candidate_acl']?>:
<?php echo $text['label-candidate_acl']?>:
</td>
<td class='vtable' align='left'>
<input class='formfld' type='text' name='candidate_acl' maxlength='255' value="<?php echo $profile['candidate_acl'];?>">
<br />
<?=$text['description-candidate_acl']?>
<?php echo $text['description-candidate_acl']?>
</td>
</tr>
<tr>
<td class='vncell' valign='top' align='left' nowrap='nowrap'>
<?=$text['label-local_network_acl']?>:
<?php echo $text['label-local_network_acl']?>:
</td>
<td class='vtable' align='left'>
<input class='formfld' type='text' name='local_network_acl' maxlength='255' value="<?php echo $profile['local_network_acl'];?>">
<br />
<?=$text['description-local_network_acl']?>
<?php echo $text['description-local_network_acl']?>
</td>
</tr>
</table>
@@ -258,31 +258,31 @@ function hide_advanced_config() {
</tr>
<tr>
<td class='vncellreq' valign='top' align='left' nowrap='nowrap'>
<?=$text['label-enabled']?>:
<?php echo $text['label-enabled']?>:
</td>
<td class='vtable' align='left'>
<select class='formfld' name='enabled'>
<option value='true' <?php if($profile['enabled'] == "true") echo "selected='selected'"; ?>><?=$text['label-true']?></option>
<option value='false' <?php if($profile['enabled'] == "false") echo "selected='selected'"; ?>><?=$text['label-false']?></option>
<option value='true' <?php if($profile['enabled'] == "true") echo "selected='selected'"; ?>><?php echo $text['label-true']?></option>
<option value='false' <?php if($profile['enabled'] == "false") echo "selected='selected'"; ?>><?php echo $text['label-false']?></option>
</select>
<br />
<?=$text['description-enabled']?>
<?php echo $text['description-enabled']?>
</td>
</tr>
<tr>
<td class='vncell' valign='top' align='left' nowrap='nowrap'>
<?=$text['label-description']?>:
<?php echo $text['label-description']?>:
</td>
<td class='vtable' align='left'>
<input class='formfld' type='text' name='description' value='<?php echo $profile['description'];?>'>
<br />
<?=$text['description-description']?>
<?php echo $text['description-description']?>
</td>
</tr>
<tr>
<td colspan='2' align='right'>
<input type='hidden' name='profile_id' value='<?php echo $profile['xmpp_profile_uuid']; ?>'>
<input type='submit' name='submit' class='btn' value='<?=$text['button-save']?>'>
<input type='submit' name='submit' class='btn' value='<?php echo $text['button-save']?>'>
</td>
</tr>
</table>

View File

@@ -2,8 +2,8 @@
<table width="100%" border="0" cellpadding="6" cellspacing="0">
<tr>
<td align='left'><b><?=$text['header-xmpp']?></b><br>
<?=$text['description-xmpp-list']?>
<td align='left'><b><?php echo $text['header-xmpp']?></b><br>
<?php echo $text['description-xmpp-list']?>
</td>
</tr>
</table>
@@ -11,14 +11,14 @@
<table width='100%' border='0' cellpadding='0' cellspacing='0'>
<tr>
<th><?=$text['label-profile_name']?></th>
<th><?=$text['label-context']?></th>
<th><?=$text['label-status']?></th>
<th><?=$text['label-enabled']?></th>
<th><?=$text['label-description']?></th>
<th><?php echo $text['label-profile_name']?></th>
<th><?php echo $text['label-context']?></th>
<th><?php echo $text['label-status']?></th>
<th><?php echo $text['label-enabled']?></th>
<th><?php echo $text['label-description']?></th>
<td align='right' width='42'>
<?php if (permission_exists('xmpp_add')) { ?>
<a href='xmpp_profile_edit.php' alt='<?=$text['button-add']?>'><?php echo $v_link_label_add; ?></a>
<a href='xmpp_profile_edit.php' alt='<?php echo $text['button-add']?>'><?php echo $v_link_label_add; ?></a>
<?php } ?>
</td>
</tr>
@@ -38,11 +38,11 @@ foreach($profiles_array as $profile){
<td class='<?php echo $row_style[$c]; ?>'><?php echo $profile['description']; ?>&nbsp;</td>
<td align='right' width='42'>
<?php if (permission_exists('xmpp_edit')) { ?>
<a href='xmpp_profile_edit.php?id=<?php echo $profile['xmpp_profile_uuid']; ?>' alt='<?=$text['button-edit']?>'><?php echo $v_link_label_edit; ?></a>
<a href='xmpp_profile_edit.php?id=<?php echo $profile['xmpp_profile_uuid']; ?>' alt='<?php echo $text['button-edit']?>'><?php echo $v_link_label_edit; ?></a>
<?php } ?>
<?php if (permission_exists('xmpp_delete')) { ?>
<a href='profile_delete.php?id=<?php echo $profile['xmpp_profile_uuid']; ?>' onclick="return confirm('<?=$text['confirm-delete']?>')"
alt='<?=$text['button-delete']?>'><?php echo $v_link_label_delete; ?></a>
<a href='profile_delete.php?id=<?php echo $profile['xmpp_profile_uuid']; ?>' onclick="return confirm('<?php echo $text['confirm-delete']?>')"
alt='<?php echo $text['button-delete']?>'><?php echo $v_link_label_delete; ?></a>
<?php } ?>
</td>
</tr>
@@ -53,7 +53,7 @@ if ($c==0) { $c=1; } else { $c=0; }
<tr>
<td colspan='6' align='right' width='42'>
<?php if (permission_exists('xmpp_add')) { ?>
<a href='xmpp_profile_edit.php' alt='<?=$text['button-add']?>'><?php echo $v_link_label_add; ?></a>
<a href='xmpp_profile_edit.php' alt='<?php echo $text['button-add']?>'><?php echo $v_link_label_add; ?></a>
<?php } ?>
</td>
</tr>