diff options
Diffstat (limited to 'views')
-rw-r--r-- | views/editor.php | 34 | ||||
-rw-r--r-- | views/new-post.php | 10 | ||||
-rw-r--r-- | views/partials/appcache.php | 28 | ||||
-rw-r--r-- | views/partials/syndication-js.php | 3 |
4 files changed, 27 insertions, 48 deletions
diff --git a/views/editor.php b/views/editor.php index ac0f429..6d235c4 100644 --- a/views/editor.php +++ b/views/editor.php @@ -1,5 +1,5 @@ <!doctype html> -<html lang="en" manifest="appcache.manifest"> +<html lang="en"> <head> <title>Quill Editor</title> <meta charset="utf-8"> @@ -15,22 +15,22 @@ we want to exclude it for iPhone 5 to allow full screen apps --> <meta name="viewport" content="initial-scale=1.0,user-scalable=no,maximum-scale=1" media="(device-height: 568px)" /> - <link rel="stylesheet" href="/editor/medium-editor/css/medium-editor.min.css"> - <link rel="stylesheet" href="/editor/medium-editor/css/themes/default.min.css"> - <link rel="stylesheet" href="/editor/medium-editor/css/medium-editor-insert-plugin.min.css"> - <link rel="stylesheet" href="/editor/medium-editor/css/medium-editor-insert-plugin-frontend.min.css"> - <link href="/editor/font-awesome/css/font-awesome.css" rel="stylesheet"> - <link rel="stylesheet" href="/editor/style.css"> + <link rel="stylesheet" href="/editor-files/medium-editor/css/medium-editor.min.css"> + <link rel="stylesheet" href="/editor-files/medium-editor/css/themes/default.min.css"> + <link rel="stylesheet" href="/editor-files/medium-editor/css/medium-editor-insert-plugin.min.css"> + <link rel="stylesheet" href="/editor-files/medium-editor/css/medium-editor-insert-plugin-frontend.min.css"> + <link href="/editor-files/font-awesome/css/font-awesome.css" rel="stylesheet"> + <link rel="stylesheet" href="/editor-files/style.css"> - <script src="/editor/jquery-1.11.3.min.js"></script> - <script src="/editor/jquery-ui-1.11.4.custom/jquery-ui.min.js"></script> - <script src="/editor/jquery.fileupload.js"></script> - <script src="/editor/jquery.iframetransport.js"></script> + <script src="/editor-files/jquery-1.11.3.min.js"></script> + <script src="/editor-files/jquery-ui-1.11.4.custom/jquery-ui.min.js"></script> + <script src="/editor-files/jquery.fileupload.js"></script> + <script src="/editor-files/jquery.iframetransport.js"></script> - <script src="/editor/handlebars.min.js"></script> - <script src="/editor/medium-editor/js/medium-editor.min.js"></script> - <script src="/editor/medium-editor/js/medium-editor-insert-plugin.min.js"></script> - <script src="/editor/localforage/localforage.js"></script> + <script src="/editor-files/handlebars.min.js"></script> + <script src="/editor-files/medium-editor/js/medium-editor.min.js"></script> + <script src="/editor-files/medium-editor/js/medium-editor-insert-plugin.min.js"></script> + <script src="/editor-files/localforage/localforage.js"></script> <link rel="apple-touch-icon" sizes="57x57" href="/images/quill-icon-57.png"> <link rel="apple-touch-icon" sizes="72x72" href="/images/quill-icon-72.png"> @@ -43,7 +43,7 @@ <div class="toolbar"> <div class="toolbar-left"> - <span class="item"><a href="/"><img src="/editor/quill-logo-36.png" width="36" height="31" class="logo"></a></span> + <span class="item"><a href="/"><img src="/editor-files/quill-logo-36.png" width="36" height="31" class="logo"></a></span> <span class="item text"><span id="draft-status">Draft</span></span> </div> <div class="toolbar-right"> @@ -106,7 +106,7 @@ </div> </div> -<script src="/editor/editor.js"></script> +<script src="/editor-files/editor.js"></script> </body> </html>
\ No newline at end of file diff --git a/views/new-post.php b/views/new-post.php index be5dafb..2c8c9f9 100644 --- a/views/new-post.php +++ b/views/new-post.php @@ -38,7 +38,12 @@ if($this->syndication_targets) { echo '<ul>'; foreach($this->syndication_targets as $syn) { - echo '<li><button data-syndication="'.$syn['target'].'" class="btn btn-default btn-block"><img src="'.$syn['favicon'].'" width="16" height="16"> '.$syn['target'].'</button></li>'; + echo '<li>' + . '<button data-syndicate-to="'.(isset($syn['uid']) ? $syn['uid'] : $syn['target']).'" class="btn btn-default btn-block">' + . ($syn['favicon'] ? '<img src="'.$syn['favicon'].'" width="16" height="16"> ' : '') + . $syn['target'] + . '</button>' + . '</li>'; } echo '</ul>'; } else { @@ -181,9 +186,10 @@ $(function(){ $("#btn_post").click(function(){ + // Collect all the syndication buttons that are pressed var syndications = []; $("#syndication-container button.btn-info").each(function(i,btn){ - syndications.push($(btn).data('syndication')); + syndications.push($(btn).data('syndicate-to')); }); var category = csv_to_array($("#note_category").val()); diff --git a/views/partials/appcache.php b/views/partials/appcache.php deleted file mode 100644 index 2e76754..0000000 --- a/views/partials/appcache.php +++ /dev/null @@ -1,28 +0,0 @@ -CACHE MANIFEST - -# v25 - -/editor -/editor/style.css -/editor/medium-editor/css/medium-editor.min.css -/editor/medium-editor/css/themes/default.min.css -/editor/medium-editor/css/medium-editor-insert-plugin.min.css -/editor/medium-editor/css/medium-editor-insert-plugin-frontend.min.css -/editor/font-awesome/css/font-awesome.css -/editor/jquery-1.11.3.min.js -/editor/jquery-ui-1.11.4.custom/jquery-ui.min.js -/editor/jquery.fileupload.js -/editor/jquery.iframetransport.js -/editor/handlebars.min.js -/editor/medium-editor/js/medium-editor.min.js -/editor/medium-editor/js/medium-editor-insert-plugin.min.js -/editor/localforage/localforage.js -/editor/quill-logo-36.png -# /editor/editor.js -/editor/font-awesome/fonts/fontawesome-webfont.woff2?v=4.3.0 -/editor/font-awesome/fonts/fontawesome-webfont.woff?v=4.3.0 -/editor/font-awesome/fonts/fontawesome-webfont.ttf?v=4.3.0 - -NETWORK: -* - diff --git a/views/partials/syndication-js.php b/views/partials/syndication-js.php index bd657f3..088cb43 100644 --- a/views/partials/syndication-js.php +++ b/views/partials/syndication-js.php @@ -5,8 +5,9 @@ function reload_syndications() { $("#syndication-container").html('<ul></ul>'); for(var i in data.targets) { var target = data.targets[i].target; + var uid = data.targets[i].uid; var favicon = data.targets[i].favicon; - $("#syndication-container ul").append('<li><button data-syndication="'+target+'" class="btn btn-default btn-block"><img src="'+favicon+'" width="16" height="16"> '+target+'</button></li>'); + $("#syndication-container ul").append('<li><button data-syndicate-to="'+(uid ? uid : target)+'" class="btn btn-default btn-block">'+(favicon ? '<img src="'+favicon+'" width="16" height="16"> ':'')+target+'</button></li>'); } bind_syndication_buttons(); } else { |