aboutsummaryrefslogtreecommitdiff
path: root/data/stuff/tinymce-4.3.7/plugins/example
diff options
context:
space:
mode:
authorPaul Duncan <pabs@pablotron.org>2016-04-03 02:27:10 -0400
committerPaul Duncan <pabs@pablotron.org>2016-04-03 02:27:10 -0400
commitfda56e40b460ab06b6abee98ae1bc7d5f5847c9f (patch)
tree29c3ddbf0ae3d47370019fb969920b07f27fc015 /data/stuff/tinymce-4.3.7/plugins/example
parentb53fb6a4edc0e7b8a6cbfa1f6ca9db4e1895add6 (diff)
downloadold-guff-fda56e40b460ab06b6abee98ae1bc7d5f5847c9f.tar.bz2
old-guff-fda56e40b460ab06b6abee98ae1bc7d5f5847c9f.zip
add tinymce
Diffstat (limited to 'data/stuff/tinymce-4.3.7/plugins/example')
-rw-r--r--data/stuff/tinymce-4.3.7/plugins/example/dialog.html8
-rw-r--r--data/stuff/tinymce-4.3.7/plugins/example/plugin.min.js1
2 files changed, 9 insertions, 0 deletions
diff --git a/data/stuff/tinymce-4.3.7/plugins/example/dialog.html b/data/stuff/tinymce-4.3.7/plugins/example/dialog.html
new file mode 100644
index 0000000..565f06f
--- /dev/null
+++ b/data/stuff/tinymce-4.3.7/plugins/example/dialog.html
@@ -0,0 +1,8 @@
+<!DOCTYPE html>
+<html>
+<body>
+ <h3>Custom dialog</h3>
+ Input some text: <input id="content">
+ <button onclick="top.tinymce.activeEditor.windowManager.getWindows()[0].close();">Close window</button>
+</body>
+</html> \ No newline at end of file
diff --git a/data/stuff/tinymce-4.3.7/plugins/example/plugin.min.js b/data/stuff/tinymce-4.3.7/plugins/example/plugin.min.js
new file mode 100644
index 0000000..88687c7
--- /dev/null
+++ b/data/stuff/tinymce-4.3.7/plugins/example/plugin.min.js
@@ -0,0 +1 @@
+tinymce.PluginManager.add("example",function(a,b){a.addButton("example",{text:"My button",icon:!1,onclick:function(){a.windowManager.open({title:"Example plugin",body:[{type:"textbox",name:"title",label:"Title"}],onsubmit:function(b){a.insertContent("Title: "+b.data.title)}})}}),a.addMenuItem("example",{text:"Example plugin",context:"tools",onclick:function(){a.windowManager.open({title:"TinyMCE site",url:b+"/dialog.html",width:600,height:400,buttons:[{text:"Insert",onclick:function(){var b=a.windowManager.getWindows()[0];a.insertContent(b.getContentWindow().document.getElementById("content").value),b.close()}},{text:"Close",onclick:"close"}]})}})}); \ No newline at end of file