X-Git-Url: http://git.shiar.net/minimedit.git/blobdiff_plain/46a7191a045681321aad07b94de13fd6e43c74f6..aaa476ce6d0a8723725bcce2c388fdea5c1e98e1:/edit.js 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'], ];