Explorar o código

임시 비활성화

ect (or 2du) %!s(int64=8) %!d(string=hai) anos
pai
achega
26ec73384b
Modificáronse 2 ficheiros con 3 adicións e 5 borrados
  1. 0 2
      app.py
  2. 3 3
      func.py

+ 0 - 2
app.py

@@ -1741,7 +1741,6 @@ def edit(name = None):
             data = get_name + js_data[0] + '''
                     <form method="post" action="/edit/''' + url_pas(name) + action + '''">
                         ''' + js_data[1] + '''
-                        <hr>
                         <textarea id="content" rows="25" name="content">''' + html.escape(re.sub('\n$', '', data)) + '''</textarea>
                         <textarea style="display: none;" name="otent">''' + html.escape(re.sub('\n$', '', data_old)) + '''</textarea>
                         <hr>
@@ -1783,7 +1782,6 @@ def preview(name = None):
         data = js_data[0] + '''
                 <form method="post" action="/edit/''' + url_pas(name) + action + '''">
                     ''' + js_data[1] + '''
-                    <hr>
                     <textarea id="content" rows="25" name="content">''' + html.escape(request.form.get('content', None)) + '''</textarea>
                     <textarea style="display: none;" name="otent">''' + html.escape(request.form.get('otent', None)) + '''</textarea>
                     <hr>

+ 3 - 3
func.py

@@ -73,7 +73,7 @@ def load_lang(lang, data):
 
 def edit_help_button():
     # https://stackoverflow.com/questions/11076975/insert-text-into-textarea-at-cursor-position-javascript
-    js = '''<script>
+    '''<script>
                 function insertAtCursor(myField, myValue) {
                     if (document.selection) { 
                         document.getElementById(myField).focus();
@@ -90,9 +90,9 @@ def edit_help_button():
             </script>
         '''
 
-    js_button = '<a href="javascript:void(0);" onclick="insertAtCursor(\'content\', \'[[]]\');">(링크)</a> <a href="javascript:void(0);" onclick="insertAtCursor(\'content\', \'[macro()]\');">(매크로)</a> <a href="javascript:void(0);" onclick="insertAtCursor(\'content\', \'{{{#! }}}\');">(중괄호)</a>'
+    '<a href="javascript:void(0);" onclick="insertAtCursor(\'content\', \'[[]]\');">(링크)</a> <a href="javascript:void(0);" onclick="insertAtCursor(\'content\', \'[macro()]\');">(매크로)</a> <a href="javascript:void(0);" onclick="insertAtCursor(\'content\', \'{{{#! }}}\');">(중괄호)</a><hr>'
 
-    return [js, js_button]
+    return ['', '']
 
 def ip_warring(conn):
     curs = conn.cursor()