trying to fix upload image

This commit is contained in:
CHIEFSOFT\ameye
2023-12-13 09:12:02 -05:00
parent ef3f163cf4
commit d6aad03575
3 changed files with 25 additions and 7 deletions
@@ -13,7 +13,7 @@
<ion-content class="ion-padding">
<div class="boxed_contents">
<div class="profile">
<div class="bg_image back_image" [style.backgroundImage]="'url('+profilePicture+')'">
<div class="bg_image back_image" id="profile_pic" [style.backgroundImage]="'url('+profilePicture+')'">
<div class="icon">
<ion-icon name="camera" (click)="startCamera()"></ion-icon>
</div>
@@ -41,6 +41,15 @@ export class EditProfilePage implements OnInit {
this.email = this.sessionDataProviderService.email;
this.online_name = this.sessionDataProviderService.online_name;
this.profilePicture = this.sessionDataProviderService.profilePicture(this.sessionDataProviderService.session, this.sessionDataProviderService.member_uid);
setInterval(()=>{
var myIframe=document.getElementById('profile_pic');
myIframe.style.backgroundImage=myIframe.style.backgroundImage;
//document.getElementById("profile_pic").style.background="'url('"+this.profilePicture+"')'"; ///this.profilePicture;
}, 5000);
// document.getElementById("profile_pic").reload(true);
}
onBack() {
@@ -167,6 +176,10 @@ export class EditProfilePage implements OnInit {
uploadResult => {
this.uploadResult = uploadResult;
console.log("this.wrenchService.uploadFile RETURN DATA->", this.uploadResult);
this.profilePicture = this.sessionDataProviderService.profilePicture(this.sessionDataProviderService.session, this.sessionDataProviderService.member_uid);
//this.ngOnInit(); // trying this
//debugger;
document.getElementById("profile_pic").style.backgroundImage="'url('"+this.profilePicture+"')'"; ///this.profilePicture;
}
);