{* Smarty *}

{literal}
<script type="text/javascript">
//<![CDATA[

$(function() {
  AltButtons();
});
  
$(function() {
  $("input[name='traceroute_name']").css("width","300px");
});

function showResponseFormTracerouteAdd(responseText){
  DialogStandartOpen('TracerouteResultFrm', responseText, 'Результат.');
}

$(function(){
  var options = {
    success: showResponseFormTracerouteAdd,
    timeout: 36000
  };
  $("#FormTracerouteAdd").validate({
    submitHandler: function(form) {
      $(form).ajaxSubmit(options);
    },
    rules : {
      "traceroute_name" : {
        required : true
      },
      "traceroute_nunber" : {
        required : true,
        number: true
      }
    },
    errorPlacement: function(error, element) {
      var er = element.attr("name");
      error.appendTo($("label[for='" + er + "']").next() );
    }
  });
});
//]]>
</script>
{/literal}

<form action="{$MS_SP->Sp_PathTop}{$MS_SP->Sp_PathToSite}/AjaxServer/TracerouteGet.ajax.php" method="post" name="FormTracerouteAdd" id="FormTracerouteAdd">
  <table>
    <tr>
      <td><label for="traceroute_name">Адрес <span class="ui-state-error">* </span>:&nbsp;</label><span></span></td>
      <td><input type="text" id="traceroute_name" name="traceroute_name" value="" /></td>
    </tr>
    <tr>
      <td colspan="2">
        <span class="ui-state-error"> * </span>поля обязательные для заполнения
      </td>
    </tr>
    <tr>
      <td colspan="2" class="MsFormSubmit"><input class="AltButtons" name="FormSubmit" value="Выполнить" type="submit" /></td>
    </tr>
  </table>
</form>