diff options
author | Mike Macgirvin <mike@macgirvin.com> | 2010-08-02 19:06:36 -0700 |
---|---|---|
committer | Mike Macgirvin <mike@macgirvin.com> | 2010-08-02 19:06:36 -0700 |
commit | 93d0ef4042bdfe06b77cdbe56ec4e55143e4fc1e (patch) | |
tree | 87dad282e59c5472ee878f6faf0e96630c18c3c9 /view/jot-header.tpl | |
parent | 3fd4b4264ef8c418bbf78edaa02f7e4e32f5022e (diff) | |
download | volse-hubzilla-93d0ef4042bdfe06b77cdbe56ec4e55143e4fc1e.tar.gz volse-hubzilla-93d0ef4042bdfe06b77cdbe56ec4e55143e4fc1e.tar.bz2 volse-hubzilla-93d0ef4042bdfe06b77cdbe56ec4e55143e4fc1e.zip |
fixup image on wall
Diffstat (limited to 'view/jot-header.tpl')
-rw-r--r-- | view/jot-header.tpl | 37 |
1 files changed, 21 insertions, 16 deletions
diff --git a/view/jot-header.tpl b/view/jot-header.tpl index 34837d075..fc05a40be 100644 --- a/view/jot-header.tpl +++ b/view/jot-header.tpl @@ -1,7 +1,6 @@ -<script language="javascript" type="text/javascript" - src="$baseurl/tinymce/jscripts/tiny_mce/tiny_mce_src.js"></script> - <script language="javascript" type="text/javascript"> +<script language="javascript" type="text/javascript" src="$baseurl/tinymce/jscripts/tiny_mce/tiny_mce_src.js"></script> +<script language="javascript" type="text/javascript"> tinyMCE.init({ theme : "advanced", @@ -18,6 +17,7 @@ tinyMCE.init({ entity_encoding : "raw", add_unload_trigger : false, remove_linebreaks : false, + convert_urls: false, content_css: "$baseurl/view/custom_tinymce.css" }); @@ -31,7 +31,7 @@ tinyMCE.init({ name: 'userfile', onSubmit: function(file,ext) { $('#profile-rotator').show(); }, onComplete: function(file,response) { - tinyMCE.execCommand('mceInsertRawHTML',false,response); +alert(response); tinyMCE.execCommand('mceInsertRawHTML',false,response); $('#profile-rotator').hide(); } } @@ -39,7 +39,6 @@ tinyMCE.init({ }); - function jotGetLink() { reply = prompt("Please enter a link URL:"); if(reply && reply.length) { @@ -51,18 +50,24 @@ tinyMCE.init({ } } + function linkdropper(event) { + var linkFound = event.dataTransfer.types.contains("text/uri-list"); + if(linkFound) + event.preventDefault(); + } - + function linkdrop(event) { + var reply = event.dataTransfer.getData("text/uri-list"); + event.target.textContent = reply; + event.preventDefault(); + if(reply && reply.length) { + $('#profile-rotator').show(); + $.get('parse_url?url=' + reply, function(data) { + tinyMCE.execCommand('mceInsertRawHTML',false,data); + $('#profile-rotator').hide(); + }); + } + } </script> -<!-- - - relative_urls: false, - document_base_url : "$baseurl/", - external_image_list_url : "$baseurl/include/imagelist-js.php", - content_css : "$baseurl/view/tiny.css" - -}); -</script> --->
\ No newline at end of file |