source: branches/2.1/plugins/LocalFilesEditor/admin.tpl @ 6364

Last change on this file since 6364 was 6364, checked in by plg, 14 years ago

remove all svn:mergeinfo properties

  • Property svn:eol-style set to LF
File size: 3.7 KB
Line 
1{html_head}<link rel="stylesheet" type="text/css" href="{$LOCALEDIT_PATH}locfiledit.css">{/html_head}
2{known_script id="editarea" src=$LOCALEDIT_PATH|@cat:"editarea/edit_area_full.js"}
3<script type="text/javascript">
4var editarea = "{$LOAD_EDITAREA}";
5
6function loadEditarea() {ldelim}
7  editAreaLoader.init({ldelim}
8    id: "text"
9    {foreach from=$EDITAREA_OPTIONS key=option item=value}
10    , {$option}: {$value|editarea_quote}
11    {/foreach}
12  });
13  jQuery("#showedit").hide();
14  jQuery("#hideedit").show();
15  jQuery.post("plugins/LocalFilesEditor/update_config.php", {ldelim} editarea: "on"});
16}
17
18function unloadEditarea() {ldelim}
19  editAreaLoader.delete_instance("text");
20  jQuery("#hideedit").hide();
21  jQuery("#showedit").show();
22  jQuery.post("plugins/LocalFilesEditor/update_config.php", {ldelim} editarea: "off"});
23}
24</script>
25
26<div class="titrePage">
27  <h2>LocalFiles Editor</h2>
28</div>
29
30<form method="post" class="properties" action="{$F_ACTION}" ENCTYPE="multipart/form-data" name="form">
31
32<div id="LocalFilesEditor">
33
34<input type="hidden" value="{$zone_edit.EDITED_FILE}" name="edited_file"/>
35
36{if isset ($create_tpl)}
37  <table>
38    <tr>
39      <td style="text-align: right;">{'locfiledit_new_filename'|@translate}</td>
40      <td style="text-align: left;"><input type="text" size="55" maxlength="50" value="{$create_tpl.NEW_FILE_NAME}" name="tpl_name"/></td>
41    </tr>
42    <tr>
43      <td style="text-align: right;">{'locfiledit_parent_directory'|@translate}</td>
44      <td style="text-align: left;">{html_options name=tpl_parent options=$create_tpl.PARENT_OPTIONS selected=$create_tpl.PARENT_SELECTED}</td>
45    </tr>
46    <tr>
47      <td style="text-align: right;">{'locfiledit_model'|@translate}</td>
48      <td style="text-align: left;">{html_options name=tpl_model options=$create_tpl.MODEL_OPTIONS selected=$create_tpl.MODEL_SELECTED}</td>
49    </tr>
50  </table>
51<br><br>
52<input class="submit" type="submit" value="{'Submit'|@translate}" name="create_tpl" />
53{/if}
54
55{if isset ($css_lang_tpl)}
56{html_options name=file_to_edit options=$css_lang_tpl.OPTIONS selected=$css_lang_tpl.SELECTED}
57<input class="submit" type="submit" value="{'locfiledit_edit'|@translate}" name="edit" />
58<br><br>
59  {if isset ($css_lang_tpl.NEW_FILE_URL)}
60  <span class="{$css_lang_tpl.NEW_FILE_CLASS}">
61  <a href="{$css_lang_tpl.NEW_FILE_URL}">{'locfiledit_new_tpl'|@translate}</a>
62  </span>
63  {/if}
64{/if}
65
66{foreach from=$show_default item=file name=default_loop}
67<span class="top_right">
68<a href="{$file.SHOW_DEFAULT}" onclick="window.open( this.href, 'local_file', 'location=no,toolbar=no,menubar=no,status=no,resizable=yes,scrollbars=yes,width=800,height=600' ); return false;">{'locfiledit_show_default'|@translate} "{$file.FILE}"</a>
69</span>
70{if !($smarty.foreach.default_loop.last)}<br>{/if}
71{/foreach}
72
73{if isset ($zone_edit)}
74<b>{$zone_edit.FILE_NAME}</b>
75
76<textarea rows="30" cols="90" name="text" id="text">{$zone_edit.CONTENT_FILE}</textarea>
77<div id="editarea_buttons">
78<a href="javascript:loadEditarea();" id="showedit">[{'locfiledit_enable_editarea'|@translate}]</a>
79<a href="javascript:unloadEditarea();" id="hideedit">[{'locfiledit_disable_editarea'|@translate}]</a>
80</div>
81
82<br>
83
84<input class="submit" type="submit" value="{'locfiledit_save_file'|@translate}" name="submit" {$TAG_INPUT_ENABLED}/>
85{if isset ($restore)}
86<input class="submit" type="submit" value="{'locfiledit_restore'|@translate}" name="restore" onclick="return confirm('{'locfiledit_restore_confirm'|@translate|escape:'javascript'}');" {$TAG_INPUT_ENABLED}/>
87{/if}
88
89{if isset ($restore_infos)}
90<br><br>
91{'locfiledit_save_bak'|@translate}
92{/if}
93
94{/if}
95</div>
96</form>
97
98<script type="text/javascript">
99jQuery("#editarea_buttons").show();
100if ((editarea == "on") && (document.getElementById("text") != null)) loadEditarea();
101</script>
Note: See TracBrowser for help on using the repository browser.