When Protocol is HTTP, hide the RTSPDescribe line. Make it appear when Protocol is changed to RTSP

pull/1488/head
Isaac Connor 2016-02-12 13:52:59 -05:00
parent a2ae29dfbe
commit 5f217b48e0
1 changed files with 2 additions and 2 deletions

View File

@ -787,7 +787,7 @@ switch ( $tab )
elseif ( $newMonitor['Type'] == "Remote" )
{
?>
<tr><td><?php echo translate('RemoteProtocol') ?></td><td><?php echo buildSelect( "newMonitor[Protocol]", $remoteProtocols, "updateMethods( this )" ); ?></td></tr>
<tr><td><?php echo translate('RemoteProtocol') ?></td><td><?php echo buildSelect( "newMonitor[Protocol]", $remoteProtocols, "updateMethods( this );if(this.value=='RTSP'){\$('RTSPDescribe').show();}else{\$('RTSPDescribe').hide();}" ); ?></td></tr>
<?php
if ( empty($newMonitor['Protocol']) || $newMonitor['Protocol'] == "http" )
{
@ -851,7 +851,7 @@ switch ( $tab )
if ( $newMonitor['Type'] == "Remote" )
{
?>
<tr><td><?php echo translate('RTSPDescribe') ?>&nbsp;(<?php echo makePopupLink( '?view=optionhelp&amp;option=OPTIONS_RTSPDESCRIBE', 'zmOptionHelp', 'optionhelp', '?' ) ?>) </td><td><input type="checkbox" name="newMonitor[RTSPDescribe]" value="1"<?php if ( !empty($newMonitor['RTSPDescribe']) ) { ?> checked="checked"<?php } ?>/></td></tr>
<tr id="RTSPDescribe"<?php if ( $newMonitor['Protocol'] != 'RTSP' ) { echo ' style="display:none;"' } ) ?>><td><?php echo translate('RTSPDescribe') ?>&nbsp;(<?php echo makePopupLink( '?view=optionhelp&amp;option=OPTIONS_RTSPDESCRIBE', 'zmOptionHelp', 'optionhelp', '?' ) ?>) </td><td><input type="checkbox" name="newMonitor[RTSPDescribe]" value="1"<?php if ( !empty($newMonitor['RTSPDescribe']) ) { ?> checked="checked"<?php } ?>/></td></tr>
<?php
}
?>