X-Git-Url: http://git.shiar.net/minimedit.git/blobdiff_plain/46a7191a045681321aad07b94de13fd6e43c74f6..19f57ab41e51c2598a0f8bd91d722c1fe9b5edfe:/edit.js?ds=sidebyside diff --git a/edit.js b/edit.js index 898116f..dee1038 100644 --- a/edit.js +++ b/edit.js @@ -2,7 +2,7 @@ CKEDITOR.plugins.add('inlinesave', { init: function(editor) { editor.addCommand( 'inlinesave', { exec: function (editor) { - var pagename = window.location.pathname.replace(/\.html$/, '').replace(/\/$/, '/index'); + var pagename = window.location.pathname.replace(/\.php$/, '').replace(/\/$/, '/index'); var data = 'body='+encodeURIComponent(editor.getData()); ajaxpost = new XMLHttpRequest(); ajaxpost.open('POST', '/edit.php'+pagename, true); @@ -48,11 +48,12 @@ CKEDITOR.on('instanceCreated', function (event) { config.entities = false; // keep unicode config.filebrowserImageUploadUrl = '/edit.php?type=img'; config.forcePasteAsPlainText = true; + config.contentsCss = '/excelsior.css'; config.toolbar = [ ['Inlinesave', '-', 'ShowBlocks', 'Sourcedialog', '-', 'Undo', 'Redo'], ['Format'], ['BulletedList', 'NumberedList', '-', 'Blockquote'], - ['Bold', 'Italic', 'Underline', 'Strike', 'RemoveFormat', '-', 'Link'], + ['Bold', 'Italic', 'Underline', 'Strike', 'RemoveFormat', '-', 'Anchor', 'Link'], ['HorizontalRule', 'Table', 'Image'], ];