- Remove steditor
- Add Markdown support in post submit form - Add post geolocalisation - Clean some old code - Fix Popup CSS - Add some new icons for the buttonspull/16/head
-
3loader.php
-
3096system/Markdown.php
-
211system/Widget/WidgetCommon.php
-
2system/Widget/widgets/About/About.php
-
30system/Widget/widgets/Bookmark/Bookmark.php
-
5system/Widget/widgets/Chat/chat.css
-
10system/Widget/widgets/ContactInfo/ContactInfo.php
-
2system/Widget/widgets/Feed/Feed.php
-
2system/Widget/widgets/ProfileData/ProfileData.php
-
3system/Widget/widgets/Roster/Roster.php
-
BINsystem/js/images/bold.png
-
BINsystem/js/images/center.png
-
BINsystem/js/images/h1.png
-
BINsystem/js/images/h2.png
-
BINsystem/js/images/h3.png
-
BINsystem/js/images/h4.png
-
BINsystem/js/images/help.gif
-
BINsystem/js/images/indent.png
-
BINsystem/js/images/italic.png
-
BINsystem/js/images/left.png
-
BINsystem/js/images/link.png
-
BINsystem/js/images/ol.png
-
BINsystem/js/images/outdent.png
-
BINsystem/js/images/paragraph.png
-
BINsystem/js/images/picture.png
-
BINsystem/js/images/right.png
-
BINsystem/js/images/ul.png
-
BINsystem/js/images/underline.png
-
30system/js/movim.js
-
207system/js/steditor.js
-
49themes/movim/css/forms.css
-
38themes/movim/css/style2.css
-
28themes/movim/css/submitform.css
-
BINthemes/movim/img/icons/button/arrow-left.png
-
BINthemes/movim/img/icons/button/arrow-right.png
-
BINthemes/movim/img/icons/button/chat.png
-
BINthemes/movim/img/icons/button/checkmark.png
-
BINthemes/movim/img/icons/button/close.png
-
BINthemes/movim/img/icons/button/comment.png
-
BINthemes/movim/img/icons/button/envelope.png
-
BINthemes/movim/img/icons/button/feed.png
-
BINthemes/movim/img/icons/button/image.png
-
BINthemes/movim/img/icons/button/link.png
-
BINthemes/movim/img/icons/button/location.png
-
BINthemes/movim/img/icons/button/loop.png
-
BINthemes/movim/img/icons/button/minus.png
-
BINthemes/movim/img/icons/button/pencil.png
-
BINthemes/movim/img/icons/button/plus.png
-
BINthemes/movim/img/icons/button/quill.png
-
BINthemes/movim/img/icons/button/remove.png
-
BINthemes/movim/img/icons/button/support.png
-
BINthemes/movim/img/icons/button/upload.png
-
1themes/movim/page.tpl
3096
system/Markdown.php
File diff suppressed because it is too large
View File
|
Before Width: 16 | Height: 16 | Size: 304 B |
|
Before Width: 16 | Height: 16 | Size: 234 B |
|
Before Width: 16 | Height: 16 | Size: 276 B |
|
Before Width: 16 | Height: 16 | Size: 304 B |
|
Before Width: 16 | Height: 16 | Size: 306 B |
|
Before Width: 16 | Height: 16 | Size: 293 B |
|
Before Width: 20 | Height: 20 | Size: 288 B |
|
Before Width: 16 | Height: 16 | Size: 353 B |
|
Before Width: 16 | Height: 16 | Size: 223 B |
|
Before Width: 16 | Height: 16 | Size: 209 B |
|
Before Width: 16 | Height: 16 | Size: 343 B |
|
Before Width: 16 | Height: 16 | Size: 357 B |
|
Before Width: 16 | Height: 16 | Size: 351 B |
|
Before Width: 16 | Height: 16 | Size: 236 B |
|
Before Width: 16 | Height: 16 | Size: 606 B |
|
Before Width: 16 | Height: 16 | Size: 209 B |
|
Before Width: 16 | Height: 16 | Size: 344 B |
|
Before Width: 16 | Height: 16 | Size: 273 B |
@ -1,207 +0,0 @@ |
|||
// +----------------------------------------------------------------+
|
|||
// | SimpleTextEditor 1.0 |
|
|||
// | Author: Cezary Tomczak [www.gosu.pl] |
|
|||
// | Free for any use as long as all copyright messages are intact. |
|
|||
// +----------------------------------------------------------------+
|
|||
|
|||
function SimpleTextEditor(id, objectId) { |
|||
if (!id || !objectId) { alert("SimpleTextEditor.constructor(id, objectId) failed, two arguments are required"); } |
|||
var self = this; |
|||
this.id = id; |
|||
this.objectId = objectId; |
|||
this.frame; |
|||
this.viewSource = false; |
|||
|
|||
this.path = "system/js/"; // with slash at the end
|
|||
this.cssFile = ""; |
|||
this.charset = "iso-8859-1"; |
|||
|
|||
this.editorHtml = ""; |
|||
this.frameHtml = ""; |
|||
|
|||
this.textareaValue = ""; |
|||
|
|||
this.browser = { |
|||
"ie": Boolean(document.body.currentStyle), |
|||
"gecko" : (navigator.userAgent.toLowerCase().indexOf("gecko") != -1) |
|||
}; |
|||
|
|||
this.init = function() { |
|||
if (document.getElementById && document.createElement && document.designMode && (this.browser.ie || this.browser.gecko)) { |
|||
// EDITOR
|
|||
if (!document.getElementById(this.id)) { alert("SimpleTextEditor "+this.objectId+".init() failed, element '"+this.id+"' does not exist"); return; } |
|||
this.textareaValue = document.getElementById(this.id).value; |
|||
var ste = document.createElement("div"); |
|||
document.getElementById(this.id).parentNode.replaceChild(ste, document.getElementById(this.id)); |
|||
ste.id = this.id+"-ste"; |
|||
ste.innerHTML = this.editorHtml ? this.editorHtml : this.getEditorHtml(); |
|||
// BUTTONS
|
|||
var buttons = ste.getElementsByTagName("td"); |
|||
for (var i = 0; i < buttons.length; ++i) { |
|||
if (buttons[i].className == "button") { |
|||
buttons[i].id = this.id+'-button-'+i; |
|||
//buttons[i].onmouseover = function() { this.className = "button"; }
|
|||
buttons[i].onmouseout = function() { this.className = this.className.replace(/button-hover(\s)?/, "button"); } |
|||
buttons[i].onclick = function(id) { return function() { this.className = "button-hover button-click"; setTimeout(function(){ document.getElementById(id).className = document.getElementById(id).className.replace(/(\s)?button-click/, ""); }, 100); } }(buttons[i].id); |
|||
} |
|||
} |
|||
// FRAME
|
|||
if (this.browser.ie) { |
|||
this.frame = frames[this.id+"-frame"]; |
|||
} else if (this.browser.gecko) { |
|||
this.frame = document.getElementById(this.id+"-frame").contentWindow; |
|||
} |
|||
this.frame.document.designMode = "on"; |
|||
this.frame.document.open(); |
|||
this.frame.document.write(this.frameHtml ? this.frameHtml : this.getFrameHtml()); |
|||
this.frame.document.close(); |
|||
insertHtmlFromTextarea(); |
|||
} |
|||
}; |
|||
|
|||
function lockUrls(s) { |
|||
if (self.browser.gecko) { return s; } |
|||
return s.replace(/href=["']([^"']*)["']/g, 'href="simpletexteditor://simpletexteditor/$1"'); |
|||
} |
|||
|
|||
function unlockUrls(s) { |
|||
if (self.browser.gecko) { return s; } |
|||
return s.replace(/href=["']simpletexteditor:\/\/simpletexteditor\/([^"']*)["']/g, 'href="$1"'); |
|||
} |
|||
|
|||
function insertHtmlFromTextarea() { |
|||
try { self.frame.document.body.innerHTML = lockUrls(self.textareaValue); } catch (e) { setTimeout(insertHtmlFromTextarea, 10); } |
|||
} |
|||
|
|||
this.getEditorHtml = function() { |
|||
var html = ""; |
|||
html += '<input type="hidden" id="'+this.id+'" name="'+this.id+'" value="" autofocus="autofocus">'; |
|||
html += '<table class="ste" cellspacing="0" cellpadding="0">'; |
|||
|
|||
html += '<div class="menueditor">'; |
|||
html += '<a class="button tiny merged left" onclick="'+this.objectId+'.execCommand(\'formatblock\', \'<h1>\');"><img src="'+this.path+'images/h1.png" alt="H1" title="H1" ></a>'; |
|||
html += '<a class="button tiny merged" onclick="'+this.objectId+'.execCommand(\'formatblock\', \'<h2>\');"><img src="'+this.path+'images/h2.png" alt="H2" title="H2" ></a>'; |
|||
html += '<a class="button tiny merged" onclick="'+this.objectId+'.execCommand(\'formatblock\', \'<h3>\');"><img src="'+this.path+'images/h3.png" alt="H3" title="H3" ></a>'; |
|||
html += '<a class="button tiny merged right" onclick="'+this.objectId+'.execCommand(\'formatblock\', \'<h4>\');"><img src="'+this.path+'images/h4.png" alt="H4" title="H4" ></a>'; |
|||
|
|||
html += '<a class="button tiny" style="margin-right: 5px;" onclick="'+this.objectId+'.execCommand(\'formatblock\', \'<p>\');"><img src="'+this.path+'images/paragraph.png" alt="Paragraph" title="Paragraph" ></a>'; |
|||
|
|||
html += '<a class="button tiny merged left" onclick="'+this.objectId+'.execCommand(\'bold\')"><img src="'+this.path+'images/bold.png" alt="Bold" title="Bold"></a>'; |
|||
html += '<a class="button tiny merged" onclick="'+this.objectId+'.execCommand(\'italic\')"><img src="'+this.path+'images/italic.png" alt="Italic" title="Italic"></a>'; |
|||
html += '<a class="button tiny merged right" onclick="'+this.objectId+'.execCommand(\'underline\')"><img src="'+this.path+'images/underline.png" alt="Underline" title="Underline"></a>'; |
|||
|
|||
html += '<a class="button tiny merged left" onclick="'+this.objectId+'.execCommand(\'justifyleft\')"><img src="'+this.path+'images/left.png" alt="Align Left" title="Align Left"></a>'; |
|||
html += '<a class="button tiny merged" onclick="'+this.objectId+'.execCommand(\'justifycenter\')"><img src="'+this.path+'images/center.png" alt="Center" title="Center"></a>'; |
|||
html += '<a class="button tiny merged right" onclick="'+this.objectId+'.execCommand(\'justifyright\')"><img src="'+this.path+'images/right.png" alt="Align Right" title="Align Right"></a>'; |
|||
|
|||
html += '<a class="button tiny merged left" onclick="'+this.objectId+'.execCommand(\'insertorderedlist\')"><img src="'+this.path+'images/ol.png" alt="Ordered List" title="Ordered List"></a>'; |
|||
html += '<a class="button tiny merged right" onclick="'+this.objectId+'.execCommand(\'insertunorderedlist\')"><img src="'+this.path+'images/ul.png" alt="Unordered List" title="Unordered List"></a>'; |
|||
|
|||
html += '<br /><a class="button tiny merged left" onclick="'+this.objectId+'.execCommand(\'outdent\')"><img src="'+this.path+'images/outdent.png" alt="Outdent" title="Outdent"></a>'; |
|||
html += '<a class="button tiny merged right" onclick="'+this.objectId+'.execCommand(\'indent\')"><img src="'+this.path+'images/indent.png" alt="Indent" title="Indent"></a>'; |
|||
|
|||
html += '<a class="button tiny merged left" onclick="'+this.objectId+'.execCommand(\'createlink\')"><img src="'+this.path+'images/link.png" alt="Insert Link" title="Insert Link"></a>'; |
|||
html += '<a class="button tiny merged right" onclick="'+this.objectId+'.execCommand(\'insertimage\')"><img src="'+this.path+'images/picture.png" alt="Insert Image" title="Insert Image"></a>'; |
|||
|
|||
html += '</div>'; |
|||
|
|||
html += '<tr><td class="frame"><iframe style="height: 50px;" id="'+this.id+'-frame" frameborder="0"></iframe></td></tr>'; |
|||
|
|||
html += '</table>'; |
|||
return html; |
|||
}; |
|||
|
|||
this.getFrameHtml = function() { |
|||
var html = ""; |
|||
html += '<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">'; |
|||
html += '<html><head>'; |
|||
html += '<meta http-equiv="Content-Type" content="text/html; charset='+this.charset+'">'; |
|||
html += '<title>SimpleTextEditor frame</title>'; |
|||
|
|||
html += '<style type="text/css">html,body { cursor: text; } body { margin: 0px; padding: 0; font-size: 12px; }</style>'; |
|||
html += '</head><body></body></html>'; |
|||
return html; |
|||
}; |
|||
|
|||
this.openWindow = function(url, width, height) { |
|||
var x = (screen.width/2-width/2); |
|||
var y = (screen.height/2-height/2); |
|||
window.open(url, "", "scrollbars=yes,width="+width+",height="+height+",screenX="+(x)+",screenY="+y+",left="+x+",top="+y); |
|||
}; |
|||
|
|||
this.toggleSource = function() { |
|||
var html, text; |
|||
if (this.browser.ie) { |
|||
if (!this.viewSource) { |
|||
html = this.frame.document.body.innerHTML; |
|||
this.frame.document.body.innerText = unlockUrls(html); |
|||
document.getElementById(this.id+"-buttons").style.visibility = "hidden"; |
|||
this.viewSource = true; |
|||
} else { |
|||
text = this.frame.document.body.innerText; |
|||
this.frame.document.body.innerHTML = lockUrls(text); |
|||
document.getElementById(this.id+"-buttons").style.visibility = "visible"; |
|||
this.viewSource = false; |
|||
} |
|||
} else if (this.browser.gecko) { |
|||
if (!this.viewSource) { |
|||
html = document.createTextNode(this.frame.document.body.innerHTML); |
|||
this.frame.document.body.innerHTML = ""; |
|||
this.frame.document.body.appendChild(html); |
|||
document.getElementById(this.id+"-buttons").style.visibility = "hidden"; |
|||
this.viewSource = true; |
|||
} else { |
|||
html = this.frame.document.body.ownerDocument.createRange(); |
|||
html.selectNodeContents(this.frame.document.body); |
|||
this.frame.document.body.innerHTML = html.toString(); |
|||
document.getElementById(this.id+"-buttons").style.visibility = "visible"; |
|||
this.viewSource = false; |
|||
} |
|||
} |
|||
document.getElementById(this.id+"-viewSource").checked = this.viewSource ? "checked" : ""; |
|||
document.getElementById(this.id+"-viewSource").blur(); |
|||
}; |
|||
|
|||
this.execCommand = function(cmd, value) { |
|||
if (cmd == "createlink" && !value) { |
|||
var url = prompt("Enter URL:", ""); |
|||
if (url) { |
|||
this.frame.focus(); |
|||
this.frame.document.execCommand("unlink", false, null); |
|||
if (this.browser.ie) this.frame.document.execCommand(cmd, false, "simpletexteditor://simpletexteditor/"+url); |
|||
else if (this.browser.gecko) this.frame.document.execCommand(cmd, false, url); |
|||
this.frame.focus(); |
|||
} |
|||
} else if (cmd == "insertimage" && !value) { |
|||
var imageUrl = prompt("Enter Image URL:", ""); |
|||
if (imageUrl) { |
|||
this.frame.focus(); |
|||
this.frame.document.execCommand(cmd, false, imageUrl); |
|||
this.frame.focus(); |
|||
} |
|||
} else { |
|||
this.frame.focus(); |
|||
this.frame.document.execCommand(cmd, false, value); |
|||
this.frame.focus(); |
|||
} |
|||
}; |
|||
|
|||
this.isOn = function() { |
|||
return Boolean(this.frame); |
|||
}; |
|||
|
|||
this.getContent = function() { |
|||
try { return unlockUrls(this.frame.document.body.innerHTML); } catch(e) { alert("SimpleTextEditor "+this.objectId+".getContent() failed"); } |
|||
}; |
|||
|
|||
this.submit = function() { |
|||
if (this.isOn()) { |
|||
if (this.viewSource) { this.toggleSource(); } |
|||
document.getElementById(this.id).value = this.getContent(); |
|||
} |
|||
}; |
|||
|
|||
this.clearContent = function() { |
|||
this.frame.document.body.innerHTML = ''; |
|||
}; |
|||
} |
|||
|
After Width: 12 | Height: 12 | Size: 127 B |
|
After Width: 12 | Height: 12 | Size: 127 B |
|
After Width: 12 | Height: 12 | Size: 231 B |
|
After Width: 12 | Height: 12 | Size: 157 B |
|
After Width: 12 | Height: 12 | Size: 161 B |
|
After Width: 12 | Height: 12 | Size: 179 B |
|
After Width: 12 | Height: 12 | Size: 219 B |
|
After Width: 12 | Height: 12 | Size: 326 B |
|
After Width: 12 | Height: 12 | Size: 221 B |
|
After Width: 12 | Height: 12 | Size: 281 B |
|
After Width: 12 | Height: 12 | Size: 252 B |
|
After Width: 12 | Height: 12 | Size: 285 B |
|
After Width: 12 | Height: 12 | Size: 105 B |
|
After Width: 12 | Height: 12 | Size: 260 B |
|
After Width: 12 | Height: 12 | Size: 148 B |
|
After Width: 12 | Height: 12 | Size: 270 B |
|
After Width: 12 | Height: 12 | Size: 216 B |
|
After Width: 12 | Height: 12 | Size: 248 B |
|
After Width: 12 | Height: 12 | Size: 183 B |