views

NAML documentation   Watch a video
   Usages of this macro
The source code below doesn't have navigation links because no usage has been compiled yet. Navigation links depend on how and where the macro is used, so first you may try finding all usages of "views".
... in utilities.naml
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
<macro name="views" requires="node" parameters="show_text">
    <n.if.equal value1="[n.show_text/]" value2="true">
        <then>
            <span id="v[n.id/]" style="display:none">1 <t>view</t>|%1 <t>views</t></span>
        </then>
        <else>
            <span id="v[n.id/]" style="display:none"></span>
        </else>
    </n.if.equal>
    <n.put_in_head.>
        <script type="text/javascript">
            Nabble.nViews = function(id, views) {
                var $v = $('#v'+id);
                var pos = views=='1'?0:1;
                var t = $v.html()? $v.html().split('|')[pos]:'';
                $v.html(t == ''? views : t.replace(/%1/g,views)).show();
            };
        </script>
    </n.put_in_head.>
    <n.call_later value="[n.id/]" param="views"/>
</macro>