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 9038cfb9b7
commit f4c96be7df
2 changed files with 66 additions and 66 deletions
+54 -54
View File
@@ -34,7 +34,7 @@ function hide_advanced_config() {
<tr> <tr>
<td align='left' width="50%"> <td align='left' width="50%">
<strong> <strong>
<? <?php
if ($action == "update") { if ($action == "update") {
echo $text['header-xmpp-edit']; echo $text['header-xmpp-edit'];
} }
@@ -44,13 +44,13 @@ function hide_advanced_config() {
?> ?>
</strong><br> </strong><br>
</td> <td width='50%' align='right'> </td> <td width='50%' align='right'>
<input type='submit' name='submit' class='btn' value='<?=$text['button-save']?>'> <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='<?=$text['button-back']?>'> <input type='button' class='btn' name='' alt='back' onclick="window.location='xmpp.php'" value='<?php echo $text['button-back']?>'>
</td> </td>
</tr> </tr>
<tr> <tr>
<td align='left' colspan='2'> <td align='left' colspan='2'>
<?=$text['description-xmpp-edit-add']?><br /> <?php echo $text['description-xmpp-edit-add']?><br />
</td> </td>
</tr> </tr>
</table> </table>
@@ -60,70 +60,70 @@ function hide_advanced_config() {
<tr> <tr>
<td width="30%" class='vncellreq' valign='top' align='left' nowrap='nowrap'> <td width="30%" class='vncellreq' valign='top' align='left' nowrap='nowrap'>
<?=$text['label-profile_name']?>: <?php echo $text['label-profile_name']?>:
</td> </td>
<td width="70%" class='vtable' align='left'> <td width="70%" class='vtable' align='left'>
<input class='formfld' type='text' name='profile_name' maxlength='255' value="<?php echo $profile['profile_name']; ?>"> <input class='formfld' type='text' name='profile_name' maxlength='255' value="<?php echo $profile['profile_name']; ?>">
<br /> <br />
<?=$text['description-profile_name']?> <?php echo $text['description-profile_name']?>
</td> </td>
</tr> </tr>
<tr> <tr>
<td class='vncellreq' valign='top' align='left' nowrap='nowrap'> <td class='vncellreq' valign='top' align='left' nowrap='nowrap'>
<?=$text['label-username']?>: <?php echo $text['label-username']?>:
</td> </td>
<td class='vtable' align='left'> <td class='vtable' align='left'>
<input class='formfld' type='text' name='profile_username' autocomplete='off' maxlength='255' value="<?php echo $profile['profile_username'];?>"> <input class='formfld' type='text' name='profile_username' autocomplete='off' maxlength='255' value="<?php echo $profile['profile_username'];?>">
<br /> <br />
<?=$text['description-username']?> <?php echo $text['description-username']?>
</td> </td>
</tr> </tr>
<tr> <tr>
<td class='vncellreq' valign='top' align='left' nowrap='nowrap'> <td class='vncellreq' valign='top' align='left' nowrap='nowrap'>
<?=$text['label-password']?>: <?php echo $text['label-password']?>:
</td> </td>
<td class='vtable' align='left'> <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 /> <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> </td>
</tr> </tr>
<tr> <tr>
<td class='vncellreq' valign='top' align='left' nowrap='nowrap'> <td class='vncellreq' valign='top' align='left' nowrap='nowrap'>
<?=$text['label-auto_login']?>: <?php echo $text['label-auto_login']?>:
</td> </td>
<td class='vtable' align='left'> <td class='vtable' align='left'>
<select class='formfld' name='auto_login'> <select class='formfld' name='auto_login'>
<option value='true' <?php if($profile['auto_login'] == "true") echo "selected='selected'"; ?>><?=$text['label-true']?></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'"; ?>><?=$text['label-false']?></option> <option value='false' <?php if($profile['auto_login'] == "false") echo "selected='selected'"; ?>><?php echo $text['label-false']?></option>
</select> </select>
<br /> <br />
<?=$text['description-auto_login']?> <?php echo $text['description-auto_login']?>
</td> </td>
</tr> </tr>
<tr> <tr>
<td width='30%' class='vncell' valign='top' align='left' nowrap='nowrap'> <td width='30%' class='vncell' valign='top' align='left' nowrap='nowrap'>
<?=$text['label-xmpp_server']?>: <?php echo $text['label-xmpp_server']?>:
</td> </td>
<td width='70%' class='vtable' align='left'> <td width='70%' class='vtable' align='left'>
<input class='formfld' type='text' name='xmpp_server' maxlength='255' value="<?php echo $profile['xmpp_server'];?>"> <input class='formfld' type='text' name='xmpp_server' maxlength='255' value="<?php echo $profile['xmpp_server'];?>">
<br /> <br />
<?=$text['description-xmpp_server']?> <?php echo $text['description-xmpp_server']?>
</td> </td>
</tr> </tr>
<tr> <tr>
<td class='vncellreq' valign='top' align='left' nowrap='nowrap'> <td class='vncellreq' valign='top' align='left' nowrap='nowrap'>
<?=$text['label-default_exten']?>: <?php echo $text['label-default_exten']?>:
</td> </td>
<td class='vtable' align='left'> <td class='vtable' align='left'>
<input class='formfld' type='text' name='default_exten' maxlength='255' value="<?php echo $profile['default_exten'];?>"> <input class='formfld' type='text' name='default_exten' maxlength='255' value="<?php echo $profile['default_exten'];?>">
<br /> <br />
<?=$text['description-default_exten']?> <?php echo $text['description-default_exten']?>
</td> </td>
</tr> </tr>
@@ -132,9 +132,9 @@ function hide_advanced_config() {
<div id="show_advanced_box"> <div id="show_advanced_box">
<table width="100%" border="0" cellpadding="6" cellspacing="0"> <table width="100%" border="0" cellpadding="6" cellspacing="0">
<tr> <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"> <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> </td>
</tr> </tr>
</table> </table>
@@ -144,40 +144,40 @@ function hide_advanced_config() {
<tr> <tr>
<?php if (if_group("superadmin")) { ?> <?php if (if_group("superadmin")) { ?>
<td class='vncellreq' valign='top' align='left' nowrap='nowrap'> <td class='vncellreq' valign='top' align='left' nowrap='nowrap'>
<?=$text['label-context']?>: <?php echo $text['label-context']?>:
</td> </td>
<td class='vtable' align='left'> <td class='vtable' align='left'>
<input class='formfld' type='text' name='context' maxlength='255' value="<?php echo $profile['context'];?>"> <input class='formfld' type='text' name='context' maxlength='255' value="<?php echo $profile['context'];?>">
<br /> <br />
<?=$text['description-context']?> <?php echo $text['description-context']?>
</td> </td>
</tr> </tr>
<?php } ?> <?php } ?>
<tr> <tr>
<td class='vncellreq' valign='top' align='left' nowrap='nowrap'> <td class='vncellreq' valign='top' align='left' nowrap='nowrap'>
<?=$text['label-rtp_ip']?>: <?php echo $text['label-rtp_ip']?>:
</td> </td>
<td class='vtable' align='left'> <td class='vtable' align='left'>
<input class='formfld' type='text' name='rtp_ip' maxlength='255' value="<?php echo $profile['rtp_ip'];?>"> <input class='formfld' type='text' name='rtp_ip' maxlength='255' value="<?php echo $profile['rtp_ip'];?>">
<br /> <br />
<?=$text['description-rtp_ip']?> <?php echo $text['description-rtp_ip']?>
</td> </td>
</tr> </tr>
<tr> <tr>
<td class='vncellreq' valign='top' align='left' nowrap='nowrap'> <td class='vncellreq' valign='top' align='left' nowrap='nowrap'>
<?=$text['label-ext_rtp_ip']?>: <?php echo $text['label-ext_rtp_ip']?>:
</td> </td>
<td class='vtable' align='left'> <td class='vtable' align='left'>
<input class='formfld' type='text' name='ext_rtp_ip' maxlength='255' value="<?php echo $profile['ext_rtp_ip'];?>"> <input class='formfld' type='text' name='ext_rtp_ip' maxlength='255' value="<?php echo $profile['ext_rtp_ip'];?>">
<br /> <br />
<?=$text['description-ext_rtp_ip']?> <?php echo $text['description-ext_rtp_ip']?>
</td> </td>
</tr> </tr>
<tr> <tr>
<td class='vncellreq' valign='top' align='left' nowrap='nowrap'> <td class='vncellreq' valign='top' align='left' nowrap='nowrap'>
<?=$text['label-sasl_type']?>: <?php echo $text['label-sasl_type']?>:
</td> </td>
<td class='vtable' align='left'> <td class='vtable' align='left'>
<select class='formfld' name='sasl_type'> <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> <option value='md5' <?php if($profile['sasl_type'] == "md5") echo "selected='selected'"; ?>>MD5</option>
</select> </select>
<br /> <br />
<?=$text['description-sasl_type']?> <?php echo $text['description-sasl_type']?>
</td> </td>
</tr> </tr>
<tr> <tr>
<td class='vncell' valign='top' align='left' nowrap='nowrap'> <td class='vncell' valign='top' align='left' nowrap='nowrap'>
<?=$text['label-tls_enable']?>: <?php echo $text['label-tls_enable']?>:
</td> </td>
<td class='vtable' align='left'> <td class='vtable' align='left'>
<select class='formfld' name='tls_enable'> <select class='formfld' name='tls_enable'>
<option value='true' <?php if($profile['tls_enable'] == "true") echo "selected='selected'"; ?>><?=$text['label-true']?></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'"; ?>><?=$text['label-false']?></option> <option value='false' <?php if($profile['tls_enable'] == "false") echo "selected='selected'"; ?>><?php echo $text['label-false']?></option>
</select> </select>
<br /> <br />
<?=$text['description-tls_enable']?> <?php echo $text['description-tls_enable']?>
</td> </td>
</tr> </tr>
<tr> <tr>
<td class='vncell' valign='top' align='left' nowrap='nowrap'> <td class='vncell' valign='top' align='left' nowrap='nowrap'>
<?=$text['label-use_rtp_timer']?>: <?php echo $text['label-use_rtp_timer']?>:
</td> </td>
<td class='vtable' align='left'> <td class='vtable' align='left'>
<select class='formfld' name='use_rtp_timer'> <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='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'"; ?>><?=$text['label-false']?></option> <option value='false' <?php if($profile['use_rtp_timer'] == "false") echo "selected='selected'"; ?>><?php echo $text['label-false']?></option>
</select> </select>
<br /> <br />
<?=$text['description-use_rtp_timer']?> <?php echo $text['description-use_rtp_timer']?>
</td> </td>
</tr> </tr>
<tr> <tr>
<td class='vncell' valign='top' align='left' nowrap='nowrap'> <td class='vncell' valign='top' align='left' nowrap='nowrap'>
<?=$text['label-vad']?>: <?php echo $text['label-vad']?>:
</td> </td>
<td class='vtable' align='left'> <td class='vtable' align='left'>
<select class='formfld' name='vad'> <select class='formfld' name='vad'>
<option value='none' <?php if($profile['vad'] == "none") echo "selected='selected'"; ?>><?=$text['option-vad_none']?></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'"; ?>><?=$text['option-vad_in']?></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'"; ?>><?=$text['option-vad_out']?></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'"; ?>><?=$text['option-vad_both']?></option> <option value='both' <?php if($profile['vad'] == "both") echo "selected='selected'"; ?>><?php echo $text['option-vad_both']?></option>
</select> </select>
<br /> <br />
<?=$text['description-vad']?> <?php echo $text['description-vad']?>
</td> </td>
</tr> </tr>
<tr> <tr>
<td class='vncell' valign='top' align='left' nowrap='nowrap'> <td class='vncell' valign='top' align='left' nowrap='nowrap'>
<?=$text['label-candidate_acl']?>: <?php echo $text['label-candidate_acl']?>:
</td> </td>
<td class='vtable' align='left'> <td class='vtable' align='left'>
<input class='formfld' type='text' name='candidate_acl' maxlength='255' value="<?php echo $profile['candidate_acl'];?>"> <input class='formfld' type='text' name='candidate_acl' maxlength='255' value="<?php echo $profile['candidate_acl'];?>">
<br /> <br />
<?=$text['description-candidate_acl']?> <?php echo $text['description-candidate_acl']?>
</td> </td>
</tr> </tr>
<tr> <tr>
<td class='vncell' valign='top' align='left' nowrap='nowrap'> <td class='vncell' valign='top' align='left' nowrap='nowrap'>
<?=$text['label-local_network_acl']?>: <?php echo $text['label-local_network_acl']?>:
</td> </td>
<td class='vtable' align='left'> <td class='vtable' align='left'>
<input class='formfld' type='text' name='local_network_acl' maxlength='255' value="<?php echo $profile['local_network_acl'];?>"> <input class='formfld' type='text' name='local_network_acl' maxlength='255' value="<?php echo $profile['local_network_acl'];?>">
<br /> <br />
<?=$text['description-local_network_acl']?> <?php echo $text['description-local_network_acl']?>
</td> </td>
</tr> </tr>
</table> </table>
@@ -258,31 +258,31 @@ function hide_advanced_config() {
</tr> </tr>
<tr> <tr>
<td class='vncellreq' valign='top' align='left' nowrap='nowrap'> <td class='vncellreq' valign='top' align='left' nowrap='nowrap'>
<?=$text['label-enabled']?>: <?php echo $text['label-enabled']?>:
</td> </td>
<td class='vtable' align='left'> <td class='vtable' align='left'>
<select class='formfld' name='enabled'> <select class='formfld' name='enabled'>
<option value='true' <?php if($profile['enabled'] == "true") echo "selected='selected'"; ?>><?=$text['label-true']?></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'"; ?>><?=$text['label-false']?></option> <option value='false' <?php if($profile['enabled'] == "false") echo "selected='selected'"; ?>><?php echo $text['label-false']?></option>
</select> </select>
<br /> <br />
<?=$text['description-enabled']?> <?php echo $text['description-enabled']?>
</td> </td>
</tr> </tr>
<tr> <tr>
<td class='vncell' valign='top' align='left' nowrap='nowrap'> <td class='vncell' valign='top' align='left' nowrap='nowrap'>
<?=$text['label-description']?>: <?php echo $text['label-description']?>:
</td> </td>
<td class='vtable' align='left'> <td class='vtable' align='left'>
<input class='formfld' type='text' name='description' value='<?php echo $profile['description'];?>'> <input class='formfld' type='text' name='description' value='<?php echo $profile['description'];?>'>
<br /> <br />
<?=$text['description-description']?> <?php echo $text['description-description']?>
</td> </td>
</tr> </tr>
<tr> <tr>
<td colspan='2' align='right'> <td colspan='2' align='right'>
<input type='hidden' name='profile_id' value='<?php echo $profile['xmpp_profile_uuid']; ?>'> <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> </td>
</tr> </tr>
</table> </table>
+12 -12
View File
@@ -2,8 +2,8 @@
<table width="100%" border="0" cellpadding="6" cellspacing="0"> <table width="100%" border="0" cellpadding="6" cellspacing="0">
<tr> <tr>
<td align='left'><b><?=$text['header-xmpp']?></b><br> <td align='left'><b><?php echo $text['header-xmpp']?></b><br>
<?=$text['description-xmpp-list']?> <?php echo $text['description-xmpp-list']?>
</td> </td>
</tr> </tr>
</table> </table>
@@ -11,14 +11,14 @@
<table width='100%' border='0' cellpadding='0' cellspacing='0'> <table width='100%' border='0' cellpadding='0' cellspacing='0'>
<tr> <tr>
<th><?=$text['label-profile_name']?></th> <th><?php echo $text['label-profile_name']?></th>
<th><?=$text['label-context']?></th> <th><?php echo $text['label-context']?></th>
<th><?=$text['label-status']?></th> <th><?php echo $text['label-status']?></th>
<th><?=$text['label-enabled']?></th> <th><?php echo $text['label-enabled']?></th>
<th><?=$text['label-description']?></th> <th><?php echo $text['label-description']?></th>
<td align='right' width='42'> <td align='right' width='42'>
<?php if (permission_exists('xmpp_add')) { ?> <?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 } ?> <?php } ?>
</td> </td>
</tr> </tr>
@@ -38,11 +38,11 @@ foreach($profiles_array as $profile){
<td class='<?php echo $row_style[$c]; ?>'><?php echo $profile['description']; ?>&nbsp;</td> <td class='<?php echo $row_style[$c]; ?>'><?php echo $profile['description']; ?>&nbsp;</td>
<td align='right' width='42'> <td align='right' width='42'>
<?php if (permission_exists('xmpp_edit')) { ?> <?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 } ?>
<?php if (permission_exists('xmpp_delete')) { ?> <?php if (permission_exists('xmpp_delete')) { ?>
<a href='profile_delete.php?id=<?php echo $profile['xmpp_profile_uuid']; ?>' onclick="return confirm('<?=$text['confirm-delete']?>')" <a href='profile_delete.php?id=<?php echo $profile['xmpp_profile_uuid']; ?>' onclick="return confirm('<?php echo $text['confirm-delete']?>')"
alt='<?=$text['button-delete']?>'><?php echo $v_link_label_delete; ?></a> alt='<?php echo $text['button-delete']?>'><?php echo $v_link_label_delete; ?></a>
<?php } ?> <?php } ?>
</td> </td>
</tr> </tr>
@@ -53,7 +53,7 @@ if ($c==0) { $c=1; } else { $c=0; }
<tr> <tr>
<td colspan='6' align='right' width='42'> <td colspan='6' align='right' width='42'>
<?php if (permission_exists('xmpp_add')) { ?> <?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 } ?> <?php } ?>
</td> </td>
</tr> </tr>