Thank you great video! I had to make updates to make it work for TypeScript and all the types.. For the template code use: For the typescript code use: url: string|null|ArrayBuffer = './assets/banner1.jpg' onFileSelected(files: FileList | null) { if (files) { var reader = new FileReader() reader.readAsDataURL(files[0]) reader.onload = (event:Event) => { let fileReader = event.target as FileReader this.url = fileReader.result; } } }
Thanks for the video! HELPED ME A LOT IN MY STUDIES :) . For those using Angular 12 or 13 adjust onselectFile(event) use "any" onselectFile(event:any).
sir want to know how to display an image after complete load of angular module /component .. after complete loading only it should display until then visibility is hidden
You have to understand the difference between client side and server side. Angular is fronted means client side. You can write download attribute to download image but if you want to download in specific folder then server side programming require.
I am also facing the same issue… my issue is:- I have attached a file in the parent component and I have to show the preview of that file in a dialog pop up while clicking on view button…….till now I have made the dialog box that works on clicking the view button but I am facing problem to call that attached file in the dialog box………please help me
Thank you great video! I had to make updates to make it work for TypeScript and all the types.. For the template code use:
For the typescript code use:
url: string|null|ArrayBuffer = './assets/banner1.jpg'
onFileSelected(files: FileList | null) {
if (files) {
var reader = new FileReader()
reader.readAsDataURL(files[0])
reader.onload = (event:Event) => {
let fileReader = event.target as FileReader
this.url = fileReader.result;
}
}
}
Thanks for watching
Thanks for the video! HELPED ME A LOT IN MY STUDIES :) . For those using Angular 12 or 13 adjust onselectFile(event) use "any" onselectFile(event:any).
thank you bro
Thanks for the video. Help me a lot for the upload part.
thank you so much sir, this video helped in saving my job
My pleasure
Sir have to store this file to db in sql so what datatype have to choose in db
thank you sir really you saved me dil se salaam
Thanks for watching
sir want to know how to display an image after complete load of angular module /component .. after complete loading only it should display until then visibility is hidden
Initially visibility hidden and inside ngafterviewinit you have to write visibility visible
is it compatible with ionic/angular?
I haven’t worked on iconic. Try this code and check it.
You Are The Best.....
Thanks
Thank You SO Much, it has been easier than other ways I saw. I need this hehehe Thanks!
Welcome.
Thank you so much sir , this video is very informative for me...
You are welcome
sir, if user selects a video then it should preview video and if user selects photo then it should preview photo, how to do it please help.
You have to be show default image for video or any doc file.
Does it also show a preview when I try to upload a pdf file? I need to read the file and convert it into blob /base64 string to save it in db
You can show default image or icon for pdf.
@@CreativeDeveloper perfect, nice video btw 👌
@@MhmmDonuts do you have any link to convert image to blob by post and get it from backend i am using angular and django
@@MhmmDonuts Thanks for watching
Great sir. It is helpful
Thanks
awesome, this really helped me
My pleasure
Excellent
How can be saved in angular using ajax and laravel
You have to understand the difference between client side and server side. Angular is fronted means client side. You can write download attribute to download image but if you want to download in specific folder then server side programming require.
This is so good man thank you
My pleasure
can you please tell how to upload image in local angular folder
That you can’t do by fronted
thank you so much for making this video
Thanks
Thanks!
niceee video Can u make one about multi step form with angular please ? it will be amazing
Ok I will make a video on it
works good,
Please tell me how to send this uploaded image to other components. Please tell me. I am stucked at one point.
I am also facing the same issue… my issue is:- I have attached a file in the parent component and I have to show the preview of that file in a dialog pop up while clicking on view button…….till now I have made the dialog box that works on clicking the view button but I am facing problem to call that attached file in the dialog box………please help me
You have to pass the variable where I stored image data to other component
@@SanjayKumar-vd9gb I have written html where image will display. You have to write that html file inside your popup
How to get input field value like dis
Input field value means?
hmmm, it's hitting reader.onload but not updating the front end with the picture.
Didn’t get your doubt
I dont understand , where is the upload ? in which folder can i find it ?
This is frontend part only.you can't find upload folder. This is for showing purpose to the user that which image is going to upload.
Thank you so much!!!
My pleasure
sir how to update image in angular please make video on it
You have to write server side code means backend like node etc.
Thx very much ! Like !
Thanks for watching
it's so helpful
Thanks for watching
Thanks bro
Welcome
Thank you sir.
You are welcome
Make like this video more
Sure. Thanks for watching
Not getting preview
You did anything wrong. Please check the video again
thanks a lot sir
My pleasure
thank you sir
You are welcome
Sir we are waiting for new video please upload sir ❤️❤️❤️
I upload video regularly. Please watch and thanks for watching this video
Helped
My pleasure
thanks you!!!
You are welcome
where the image is uploaded?
I lost my web site where I uploaded image.
Thanks
Welcome
thank u
Welcome
Welcome
The content is old and it doesn't work !
thanks
Welcome
thank u
You are welcome
Thank you Sir