mirror of
https://github.com/torrentpier/torrentpier
synced 2025-08-19 13:01:12 -07:00
Quote selected
Фикс цитаты выделенного.
This commit is contained in:
parent
9fd88dbb12
commit
fc063b8fc3
1 changed files with 5 additions and 0 deletions
|
@ -78,6 +78,11 @@ BBCode.prototype = {
|
||||||
getSelection: function() {
|
getSelection: function() {
|
||||||
var w = window;
|
var w = window;
|
||||||
var text='', range;
|
var text='', range;
|
||||||
|
if (w.getSelection) {
|
||||||
|
text = w.getSelection();
|
||||||
|
} else {
|
||||||
|
return [null, null];
|
||||||
|
}
|
||||||
if (text == '') text = this.stext;
|
if (text == '') text = this.stext;
|
||||||
text = ""+text;
|
text = ""+text;
|
||||||
text = text.replace("/^\s+|\s+$/g", "");
|
text = text.replace("/^\s+|\s+$/g", "");
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue