Using jQuery from Orchard module page

后端 未结 1 870
说谎
说谎 2020-12-30 06:43

I\'m trying to modify the Orchard.Search part with the search form and button to look and behave as I want. For this I need to use some jQuery features.

I a

相关标签:
1条回答
  • 2020-12-30 07:39

    Well, that script of yours needs to appear after the inclusion of jQuery, otherwise $ is meaningless. You can add your script by surrouding it with @using(Script.Foot) { ...}:

    @using(Script.Foot()) {
        <script type ="text/javascript">
        //<![CDATA[
        $(document).ready(function () { 
            alert('page loaded');
        });
        //]]>
        </script>
    }
    
    0 讨论(0)
提交回复
热议问题