zoukankan      html  css  js  c++  java
  • HTML条件注释和javascript条件注释

    <!--[if IE]>
    This content is actually inside an HTML comment.
    It will only be displayed in IE.
    <![endif--]>
    <!--[if IE6]>
    This content is actually only be displayed by IE 6 and later.
    <![endif]-->
    <!--[if !IE]><-->
    This is normal HTML content,but IE will not display it because of
    the comment above and the comment below.
    <!--><![endif]-->

    This is normal content,displayed by all browsers.
    <script>
    /*@cc_on

     @if(@_jscript)
      //This code is inside a JS comment but is executed in IE.
      //This code is inside a conditional comment,which is also a
      //regular Javascript comment.IE runs it but other browsers ignore it.
      alert("You are using Internet Explorer");
     @else*/
      //This code is no longer inside a Javascript comment,but is still
      //inside the IE conditional comment. This means that all browsers
      //excepte IE will run this code.
      alert("you are not using Internet Explorer");
     /*@end
     @*/
     </script>

    有些用处,但非标准。

  • 相关阅读:
    python端口扫描
    python模块-platform
    Mysql注入root权限直接写一句话马
    meterpreter使用
    msfpayload反弹shell
    sql_injection之post注入
    初涉sqlmap
    sql_injection之基本get注入
    利用SSLStrip截获https协议--抓取邮箱等密码
    简析CSRF
  • 原文地址:https://www.cnblogs.com/qishichang/p/1183404.html
Copyright © 2011-2022 走看看