| Server IP : 54.36.91.62 / Your IP : 216.73.217.111 Web Server : Apache System : Linux webm013.cluster127.gra.hosting.ovh.net 5.15.206-ovh-vps-grsec-zfs-classid #1 SMP Fri May 15 02:41:25 UTC 2026 x86_64 User : coopiak ( 151928) PHP Version : 8.3.23 Disable Function : _dyuweyrj4,_dyuweyrj4r,dl MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : OFF | Pkexec : OFF Directory : /home/coopiak/amisdesseniors-fr/annonces/components/com_jlexreview/assets/ |
Upload File : |
/**
* Package: JLex Review -Javascript
* Version: 2.0.0
* Author: JLexArt.com
* License: GPL2 or later
*/
function JLexProfile ($,uid,token) {
var o=this;
this.clearThumb=function(social){
var d={
option:'com_jlexreview',
view:'profile',
task:'clearthumb',
s:social?1:0
};
$.post('index.php',d,function(r){
if (r.status==200) {
// Clear thumb and return default image
$('img#profilePicture').attr('src',r.src);
return true;
}
alert(r.msg);
},'json');
}
this.changeThumb=function() {
// Create Vitual form
var url = 'index.php?option=com_jlexreview&view=profile&task=change';
var html='<div id="form_jlexprofile" style="display:none">';
html+='<form method="post" enctype="multipart/form-data" action="'+url+'" target="_formpforile">';
html+='<input type="file" name="thumb" />';
html+='<input type="hidden" name="msg" value="_trick" />';
html+='</form>';
html+='<iframe name="_formpforile" src="about:blank"></iframe></div>';
if ($('#form_jlexprofile').length) {
$('#form_jlexprofile').off();
$('#form_jlexprofile *').off();
$('#form_jlexprofile').remove();
}
$('body').append(html);
// Bind event
$('#form_jlexprofile [type=file]').trigger('click');
$('#form_jlexprofile').on('change','[type=file]',function(){
$('#form_jlexprofile form').submit();
});
}
this.previewThumb=function(data) {
if (data.status==200) {
$('img#profilePicture').attr('src',data.src);
return true;
}
if (data.msg) {
alert (data.msg);
return;
}
alert ('Appear some error when upload your avatar. Try again later');
}
}