<script type="text/javascript" src="https://code.jquery.com/jquery-3.1.1.min.js"></script>
    <script>
        function test(){
            if ($(this).text().indexOf("■") != -1){
                $(this).addClass("subtitle")
            }
            if ($(this).text().indexOf("●") != -1){
                $(this).addClass("subtitlesec")
            }
        }
        $(document).ready(function(){
           $("p").each(test)

        });

    </script>

很蠢啊,以后慢慢再改好了

这是我自己用的!!!

相关文章:

  • 2022-01-27
  • 2021-09-12
  • 2022-12-23
  • 2021-12-04
  • 2022-12-23
  • 2021-12-04
  • 2021-08-03
  • 2021-12-03
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2021-11-08
  • 2022-12-23
  • 2021-12-23
  • 2022-12-23
  • 2022-02-09
相关资源
相似解决方案