/** * Copyright (c) 2014-2016, CKSource - Frederico Knabben. All rights reserved. * Licensed under the terms of the MIT License (see LICENSE.md). * * The abbr plugin dialog window definition. * * Created out of the CKEditor Plugin SDK: * http://docs.ckeditor.com/#!/guide/plugin_sdk_sample_1 */ // Our dialog definition. CKEDITOR.dialog.add( 'geshiDialog', function( editor ) { var radio, ckg_geshi_langopts = new Array(); var href, id,geshi_dialog, t_display,s_display; var getHref = function() { var data = window.location.pathname; var qs = window.location.search; var matches = data.match(/\/(.*?)\/(doku.php)?\/?(.*)/); if(qs_match = qs.match(/id=([\w:_\.]+)\b/)) { //none id = qs_match[1]; href = matches[0]; } else if(!matches[2]) { id = matches[3]; href = matches[1] + '/doku.php'; } else { id = matches[3]; href = matches[2] + '/doku.php'; } if(!href) href='doku.php'; if(!id) id = 'start'; return {'href':href, 'id':id}; }; var downloadable_header = function(type,fname) { var id = 'start'; var file = fname ? fname: 'temp.' + type; var href_vals = getHref(); return '
'; }; var downloadable_footer = function() { return "