Changeset 768882
- Timestamp:
- 09/09/2013 08:13:24 AM (13 years ago)
- Location:
- lineunbreaker/trunk
- Files:
-
- 4 edited
-
editor_plugin.js (modified) (1 diff)
-
editor_plugin_src.js (modified) (2 diffs)
-
isa-tinymce-lineunbreaker.php (modified) (1 diff)
-
readme.txt (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
lineunbreaker/trunk/editor_plugin.js
r612305 r768882 1 (function(){tinymce.create( 'tinymce.plugins.Lineunbreaker',{init:function(ed,url){ed.addCommand('mceLineunbreak',function(){var content=ed.selection.getContent();var contentClean=content.replace(/(\r\n|\n|\r|<br\s*[\/]?>)/gim,'');ed.selection.setContent(contentClean)});ed.addButton('lineunbreak',{title:'Removes linebreaks from selected text',cmd:'mceLineunbreak',image:url+'/img/lineunbreaker.gif'})},getInfo:function(){return{longname:'Lineunbreaker',author:'Andre Lohan',authorurl:'http://wordpress.org/extend/plugins/lineunbreaker/',infourl:'',version:"1.1"}}});tinymce.PluginManager.add('lineunbreaker',tinymce.plugins.Lineunbreaker)})();1 (function(){tinymce.create("tinymce.plugins.Lineunbreaker",{init:function(e,t){e.addCommand("mceLineunbreak",function(){var t=e.selection.getContent();var n=t.replace(/(\r\n|\n|\r|<br\s*[\/]?>)/gim,"");e.selection.setContent(n)});e.addButton("lineunbreak",{title:"Removes linebreaks from selected text",cmd:"mceLineunbreak",image:t+"/img/lineunbreaker.gif"})},getInfo:function(){return{longname:"Lineunbreaker",author:"Andre Lohan",authorurl:"http://wordpress.org/extend/plugins/lineunbreaker/",infourl:"",version:"1.2"}}});tinymce.PluginManager.add("lineunbreaker",tinymce.plugins.Lineunbreaker)})() -
lineunbreaker/trunk/editor_plugin_src.js
r612305 r768882 6 6 ed.addCommand('mceLineunbreak', function() { 7 7 var content = ed.selection.getContent(); 8 //if (window.console) console.log('content before: ' + content); 8 9 var contentClean = content.replace(/(\r\n|\n|\r|<br\s*[\/]?>)/gim, ''); 10 //contentClean = contentClean.replace(/<[\/]?p\s*[\/]?>/gim, ''); // paragraphs 11 //if (window.console) console.log('content after: ' + contentClean); 9 12 ed.selection.setContent(contentClean); 10 13 }); … … 25 28 authorurl : 'http://wordpress.org/extend/plugins/lineunbreaker/', 26 29 infourl : '', 27 version : "1. 1"30 version : "1.2" 28 31 }; 29 32 } -
lineunbreaker/trunk/isa-tinymce-lineunbreaker.php
r612305 r768882 4 4 Plugin URI: http://wordpress.org/extend/plugins/lineunbreaker/ 5 5 Description: Removes line breaks from selected text in visual editor. 6 Version: 1.1 6 Version: 1.1.1 7 7 Author: dc5ala 8 8 License: GPL2 9 9 */ 10 10 11 /* Copyright 201 2Andre Lohan (email : dc5ala@darc.de)11 /* Copyright 2013 Andre Lohan (email : dc5ala@darc.de) 12 12 13 13 This program is free software; you can redistribute it and/or modify -
lineunbreaker/trunk/readme.txt
r640995 r768882 3 3 Tags: tinymce, editor, newlines, linebreaks 4 4 Requires at least: 3.2 5 Tested up to: 3. 55 Tested up to: 3.6 6 6 Stable tag: 1.1 7 7 License: GPLv2 or later … … 26 26 = What kind of line breaks are getting removed? = 27 27 28 Newslines (backslash n), carriage returns (backslash r) and HTML `<br>` tags. 28 Newslines (backslash n), carriage returns (backslash r) and HTML `<br>` tags. Paragraphs remain untouched. 29 29 30 30 == Changelog == 31 32 = 1.1.1 = 33 * Updated compatible version information 31 34 32 35 = 1.1 =
Note: See TracChangeset
for help on using the changeset viewer.