js_basic_site_functions

NAML documentation   Watch a video
   Usages of this macro
... in javascript_library.naml
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
<macro name="js_basic_site_functions" requires="servlet">
    <![CDATA[
    Nabble.online = function(id) {
        $('img.online'+id).show();
    };
 
    Nabble.openMsg = function(id) {
        return Nabble.getCookie(id) == null;
    };
 
    Nabble.toggleMsg = function(id, hide) {
        if (hide)
            Nabble.setPersistentCookie(id, 'closed');
        else
            Nabble.deleteCookie(id);
    };
    ]]>
</macro>