X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=view%2Fjot-header.tpl;h=22e425463c618bdd524c0fdcb0baf3c944a0ff5d;hb=dfd3cef734be3bc1bf2d16dfe8b2f71d6aff18a7;hp=8505b53bc247a56a0fb03f35f362f868e572075b;hpb=a93f5627c1cb05f2f2c14cc390d38799eaf461e8;p=friendica.git
diff --git a/view/jot-header.tpl b/view/jot-header.tpl
index 8505b53bc2..22e425463c 100644
--- a/view/jot-header.tpl
+++ b/view/jot-header.tpl
@@ -1,23 +1,47 @@
-
-
+
@@ -38,7 +62,6 @@ tinyMCE.init({
});
-
function jotGetLink() {
reply = prompt("Please enter a link URL:");
if(reply && reply.length) {
@@ -50,53 +73,24 @@ tinyMCE.init({
}
}
- var src = null;
-
- $(document).ready(function() {
- if($('#live-network').length) { src = 'net'; setTimeout(liveUpdate, 30000); }
- if($('#live-profile').length) { src = 'wall'; setTimeout(liveUpdate, 30000); }
- });
+ function linkdropper(event) {
+ var linkFound = event.dataTransfer.types.contains("text/uri-list");
+ if(linkFound)
+ event.preventDefault();
+ }
- function liveUpdate() {
- if(src == null) { return; }
- if($('.comment-edit-text-full').length) {
- setTimeout(liveUpdate, 30000);
- return;
+ 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();
+ });
}
-
-// $.get("live_update",function(data)
-// {
-// $(data).find('result').each(function() {
-// var net = $(this).find('net').text();
-// if(net == 0) { net = ''; }
-// $('#net-update').html(net);
-// var home = $(this).find('home').text();
-// if(home == 0) { home = ''; }
-// $('#home-update').html(home);
-// var mail = $(this).find('mail').text();
-// if(mail == 0) { mail = ''; }
-// $('#mail-update').html(mail);
-// var intro = $(this).find('intro').text();
-// if(intro == 0) { intro = ''; }
-// $('#notify-update').html(intro);
-// });
-// }) ;
-
- setTimeout(liveUpdate,30000);
}
-
-
-
-
\ No newline at end of file