1 | {html_head} |
---|
2 | <link rel="stylesheet" type="text/css" href="{$LOCALEDIT_PATH}locfiledit.css"> |
---|
3 | <style type="text/css">#headbranch, #theHeader, #copyright {ldelim} display: none; }</style> |
---|
4 | {/html_head} |
---|
5 | {known_script id="jquery" src=$ROOT_URL|@cat:"template-common/lib/jquery.packed.js"} |
---|
6 | {known_script id="editarea" src=$LOCALEDIT_PATH|@cat:"editarea/edit_area_full.js"} |
---|
7 | <script type="text/javascript"> |
---|
8 | var editarea = "{$LOAD_EDITAREA}"; |
---|
9 | |
---|
10 | function loadEditarea() {ldelim} |
---|
11 | editAreaLoader.init({ldelim} |
---|
12 | id: "text" |
---|
13 | {foreach from=$EDITAREA_OPTIONS key=option item=value} |
---|
14 | , {$option}: {$value|editarea_quote} |
---|
15 | {/foreach} |
---|
16 | }); |
---|
17 | jQuery("#showedit").hide(); |
---|
18 | jQuery("#hideedit").show(); |
---|
19 | } |
---|
20 | |
---|
21 | function unloadEditarea() {ldelim} |
---|
22 | editAreaLoader.delete_instance("text"); |
---|
23 | jQuery("#hideedit").hide(); |
---|
24 | jQuery("#showedit").show(); |
---|
25 | } |
---|
26 | </script> |
---|
27 | |
---|
28 | <div id="LocalFilesEditor"> |
---|
29 | <h1>{$TITLE}</h1> |
---|
30 | |
---|
31 | <textarea id="text" rows="30" cols="90">{$DEFAULT_CONTENT}</textarea> |
---|
32 | |
---|
33 | <div id="editarea_buttons"> |
---|
34 | <a href="javascript:loadEditarea();" id="showedit">[{'locfiledit_enable_editarea'|@translate}]</a> |
---|
35 | <a href="javascript:unloadEditarea();" id="hideedit">[{'locfiledit_disable_editarea'|@translate}]</a> |
---|
36 | </div> |
---|
37 | |
---|
38 | </div> |
---|
39 | |
---|
40 | <script type="text/javascript"> |
---|
41 | jQuery("#editarea_buttons").show(); |
---|
42 | if (editarea == "on") loadEditarea(); |
---|
43 | </script> |
---|