Laravel 8 integred databending in JS
JavaScript
1
Posts
1
Posters
1
Views
1
Watching
-
I want to load image dynamically from database in popup form
how to receive or integred databending in JS script with laravel8 ?
function getValues(){
document.getElementById('txt1').value=imageName; /*imageName=toto.jpg*/
var path = '{{asset(storage/images/imageName)}}' ;
document.getElementById('img').src=path ;
}In HTML <<
ERROR <<
Use of undefined constant storage - assumed 'storage' (this will throw an Error in a future version of PHP) (View: C:\xampp\htdocs\Ecommerce-Front\resources\views\popup.blade.php)