private mail buttons
This commit is contained in:
parent
e07d83e431
commit
38d50cabd4
@ -113,6 +113,7 @@ function mail_content(&$a) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
$channel = $a->get_channel();
|
$channel = $a->get_channel();
|
||||||
|
|
||||||
head_set_icon($channel['xchan_photo_s']);
|
head_set_icon($channel['xchan_photo_s']);
|
||||||
|
|
||||||
$cipher = get_pconfig(local_user(),'system','default_cipher');
|
$cipher = get_pconfig(local_user(),'system','default_cipher');
|
||||||
@ -163,13 +164,16 @@ function mail_content(&$a) {
|
|||||||
|
|
||||||
$tpl = get_markup_template('msg-header.tpl');
|
$tpl = get_markup_template('msg-header.tpl');
|
||||||
|
|
||||||
$a->page['htmlhead'] .= replace_macros($tpl, array(
|
$header = replace_macros($tpl, array(
|
||||||
'$baseurl' => $a->get_baseurl(true),
|
'$baseurl' => $a->get_baseurl(true),
|
||||||
'$editselect' => (($plaintext) ? 'none' : '/(profile-jot-text|prvmail-text)/'),
|
'$editselect' => (($plaintext) ? 'none' : '/(profile-jot-text|prvmail-text)/'),
|
||||||
'$nickname' => $channel['channel_address'],
|
'$nickname' => $channel['channel_address'],
|
||||||
'$linkurl' => t('Please enter a link URL:'),
|
'$linkurl' => t('Please enter a link URL:'),
|
||||||
'$expireswhen' => t('Expires YYYY-MM-DD HH:MM')
|
'$expireswhen' => t('Expires YYYY-MM-DD HH:MM')
|
||||||
));
|
));
|
||||||
|
|
||||||
|
$a->page['htmlhead'] .= $header;
|
||||||
|
|
||||||
|
|
||||||
$preselect = (isset($a->argv[2])?array($a->argv[2]):false);
|
$preselect = (isset($a->argv[2])?array($a->argv[2]):false);
|
||||||
$prename = $preurl = $preid = '';
|
$prename = $preurl = $preid = '';
|
||||||
@ -276,7 +280,7 @@ function mail_content(&$a) {
|
|||||||
$tpl = get_markup_template('msg-header.tpl');
|
$tpl = get_markup_template('msg-header.tpl');
|
||||||
|
|
||||||
$a->page['htmlhead'] .= replace_macros($tpl, array(
|
$a->page['htmlhead'] .= replace_macros($tpl, array(
|
||||||
'$nickname' => $channel['channel_addr'],
|
'$nickname' => $channel['channel_address'],
|
||||||
'$baseurl' => $a->get_baseurl(true),
|
'$baseurl' => $a->get_baseurl(true),
|
||||||
'$editselect' => (($plaintext) ? 'none' : '/(profile-jot-text|prvmail-text)/'),
|
'$editselect' => (($plaintext) ? 'none' : '/(profile-jot-text|prvmail-text)/'),
|
||||||
'$linkurl' => t('Please enter a link URL:'),
|
'$linkurl' => t('Please enter a link URL:'),
|
||||||
|
@ -8,6 +8,7 @@ require_once('include/photos.php');
|
|||||||
|
|
||||||
function wall_upload_post(&$a) {
|
function wall_upload_post(&$a) {
|
||||||
|
|
||||||
|
|
||||||
$using_api = ((x($_FILES,'media')) ? true : false);
|
$using_api = ((x($_FILES,'media')) ? true : false);
|
||||||
|
|
||||||
if($using_api) {
|
if($using_api) {
|
||||||
|
@ -52,10 +52,10 @@ else
|
|||||||
'prvmail-upload-wrapper',
|
'prvmail-upload-wrapper',
|
||||||
{ action: 'wall_upload/{{$nickname}}',
|
{ action: 'wall_upload/{{$nickname}}',
|
||||||
name: 'userfile',
|
name: 'userfile',
|
||||||
onSubmit: function(file,ext) { $('#profile-rotator').spin('tiny'); },
|
onSubmit: function(file,ext) { $('#prvmail-rotator').spin('tiny'); },
|
||||||
onComplete: function(file,response) {
|
onComplete: function(file,response) {
|
||||||
addeditortext(response);
|
addmailtext(response);
|
||||||
$('#profile-rotator').spin(false);
|
$('#prvmail-rotator').spin(false);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
@ -64,23 +64,23 @@ else
|
|||||||
'prvmail-attach-wrapper',
|
'prvmail-attach-wrapper',
|
||||||
{ action: 'wall_attach/{{$nickname}}',
|
{ action: 'wall_attach/{{$nickname}}',
|
||||||
name: 'userfile',
|
name: 'userfile',
|
||||||
onSubmit: function(file,ext) { $('#profile-rotator').spin('tiny'); },
|
onSubmit: function(file,ext) { $('#prvmail-rotator').spin('tiny'); },
|
||||||
onComplete: function(file,response) {
|
onComplete: function(file,response) {
|
||||||
addeditortext(response);
|
addmailtext(response);
|
||||||
$('#profile-rotator').spin(false);
|
$('#prvmail-rotator').spin(false);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
function jotGetLink() {
|
function prvmailJotGetLink() {
|
||||||
reply = prompt("{{$linkurl}}");
|
reply = prompt("{{$linkurl}}");
|
||||||
if(reply && reply.length) {
|
if(reply && reply.length) {
|
||||||
$('#profile-rotator').spin('tiny');
|
$('#prvmail-rotator').spin('tiny');
|
||||||
$.get('parse_url?url=' + reply, function(data) {
|
$.get('parse_url?url=' + reply, function(data) {
|
||||||
addeditortext(response);
|
addmailtext(data);
|
||||||
$('#profile-rotator').spin(false);
|
$('#prvmail-rotator').spin(false);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -103,15 +103,15 @@ else
|
|||||||
event.target.textContent = reply;
|
event.target.textContent = reply;
|
||||||
event.preventDefault();
|
event.preventDefault();
|
||||||
if(reply && reply.length) {
|
if(reply && reply.length) {
|
||||||
$('#profile-rotator').spin('tiny');
|
$('#prvmail-rotator').spin('tiny');
|
||||||
$.get('parse_url?url=' + reply, function(data) {
|
$.get('parse_url?url=' + reply, function(data) {
|
||||||
addeditortext(response);
|
addmailtext(data);
|
||||||
$('#profile-rotator').spin(false);
|
$('#prvmail-rotator').spin(false);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function addeditortext(data) {
|
function addmailtext(data) {
|
||||||
if(plaintext == 'none') {
|
if(plaintext == 'none') {
|
||||||
var currentText = $("#prvmail-text").val();
|
var currentText = $("#prvmail-text").val();
|
||||||
$("#prvmail-text").val(currentText + data);
|
$("#prvmail-text").val(currentText + data);
|
||||||
|
@ -34,21 +34,21 @@
|
|||||||
<i id="prvmail-attach" class="icon-paper-clip jot-icons" title="{{$attach}}"></i>
|
<i id="prvmail-attach" class="icon-paper-clip jot-icons" title="{{$attach}}"></i>
|
||||||
</button>
|
</button>
|
||||||
|
|
||||||
<button id="prvmail-link-wrapper" class="btn btn-default btn-sm" >
|
<button id="prvmail-link-wrapper" class="btn btn-default btn-sm" onclick="prvmailJotGetLink(); return false;" >
|
||||||
<i id="prvmail-link" class="icon-link jot-icons" title="{{$insert}}" onclick="jotGetLink(); return false;"></i>
|
<i id="prvmail-link" class="icon-link jot-icons" title="{{$insert}}" ></i>
|
||||||
</button>
|
</button>
|
||||||
{{if $feature_expire}}
|
{{if $feature_expire}}
|
||||||
<button id="prvmail-expire-wrapper" class="btn btn-default btn-sm" >
|
<button id="prvmail-expire-wrapper" class="btn btn-default btn-sm" onclick="prvmailGetExpiry();return false;" >
|
||||||
<i id="prvmail-expires" class="icon-eraser jot-icons" title="{{$expires}}" onclick="prvmailGetExpiry();return false;"></i>
|
<i id="prvmail-expires" class="icon-eraser jot-icons" title="{{$expires}}" ></i>
|
||||||
</button>
|
</button>
|
||||||
{{/if}}
|
{{/if}}
|
||||||
{{if $feature_encrypt}}
|
{{if $feature_encrypt}}
|
||||||
<button id="prvmail-encrypt-wrapper" class="btn btn-default btn-sm" >
|
<button id="prvmail-encrypt-wrapper" class="btn btn-default btn-sm" onclick="red_encrypt('{{$cipher}}','#prvmail-text',$('#prvmail-text').val());return false;">
|
||||||
<i id="prvmail-encrypt" class="icon-key jot-icons" title="{{$encrypt}}" onclick="red_encrypt('{{$cipher}}','#prvmail-text',$('#prvmail-text').val());return false;"></i>
|
<i id="prvmail-encrypt" class="icon-key jot-icons" title="{{$encrypt}}" ></i>
|
||||||
</button>
|
</button>
|
||||||
{{/if}}
|
{{/if}}
|
||||||
<div id="prvmail-rotator-wrapper" >
|
<div id="prvmail-rotator-wrapper" >
|
||||||
<img id="prvmail-rotator" src="images/rotator.gif" alt="{{$wait}}" title="{{$wait}}" style="display: none;" />
|
<div id="prvmail-rotator"></div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div id="prvmail-end"></div>
|
<div id="prvmail-end"></div>
|
||||||
|
Reference in New Issue
Block a user