Category : image

Im trying to display an image using api axios , the api is retrieving the path image from database but the image is not loading import axios from ‘axios’; class Products extends Component { state={ products:[], }; componentDidMount() { axios.get(`http://localhost/CraveByMarwa/public/api/products`) .then(res => { const products = res.data; this.setState({ products }); }) } render() { return ..

Read more

database id. project_id. type. images 1. 23. frontend 3344.png 2. 23. frontend. 3326.png 3. 23. er diagram 4290.png 4. 23 wireframe. 995.png 5. 23. wireframe. 8875.png view blade @foreach($project_data as $project) <td> <a title="delete" href="javascript:void(0);" class="confirmDelete" name="project_data" record="delete_project" recordid="{{$project[‘id’]}}" style="color: red"><i class="fas fa-trash"></i></a> </td> @endforeach route Route::get(‘delete_project/{id}’,’[email protected]’); controller public function deleteProject($id){ $project_items = ProjectImages::select(‘images’)->where(‘project_id’,$id)->first(); $project_image_path_front ..

Read more

This is the body code which is sending data to script. @foreach($products as $product) @if($product->category == "Starters") <div class="food-item white"> <div class="row"> <div class="col-xs-12 col-sm-12 col-lg-8"> <div class="rest-logo pull-left"> <a class="restaurant-logo pull-left" href="#"><img src="images/{{$product->image}}" alt="Food logo"></a> </div> <!– end:Logo –> <div class="rest-descr"> <h6><a href="#">{{$product->name}}</a></h6> <p> Burgers, American, Sandwiches, Fast Food, BBQ</p> </div> <!– end:Description –> ..

Read more

I am new in Laravel and I want to make a CRUD with cars and foe every car to save multiple images in database. I have the first table name cars like this: Schema::create(‘cars’, function (Blueprint $table) { $table->id(); $table->string(‘model’); $table->integer(‘seats’); $table->string(‘fuel’); $table->integer(‘year’); $table->string(‘color’); $table->string(‘gearbox’); $table->integer(‘price’); $table->string(‘coinType’); $table->timestamps(); }); and I have the second table ..

Read more

***I want upload image to server and display it in the list. I expect to use the same function ‘addProduct’ to store image (title & description were successfull). Got file is empty message in the backend. I have googled a lot, nothing solved my problem. Sorry I am not experienced in programming. thanks for help ..

Read more

I started creating an e-commerce platform and I’m stuck with a problem I can’t solve for 2 days.. It’s probably something obvious but I just can’t find the solution for this. Could you help me with this, please? I get this error: Missing required parameters for [Route: images.update] [URI: dashboard/images/{image}]. (View: C:xampphtdocsecommerceecommerceresourcesviewswebsiteadminproduct_imageupdate.blade.php) update.blade.php @extends(‘website.admin.layouts.main’) @section(‘content’) ..

Read more

here my code : Storage::disk(‘public’)->putFileAs(‘/img/uploads/specialties’, new File($validatedData[‘image_file’]); In local mode, when i upload an image, they are going into /public/storage/img/uploads/specialties but in production they are going to /storage/app/public/img/uploads/specialties What i tried : $ php artisan storage:link without success. Anyone know how to change where uploaded files going in production ? Thanks ! Sourc..

Read more

In one of my blade views, I am trying to display an image by doing: <img src="<?php echo asset("storage/uploads/iotpark/warranty/$currentFile")?>"></img> The image is stored in my-website.com>public>storage>uploads>iotpark>warranty. However, when visiting the page on my browser, the image is not loaded and when inspecting in Chrome’s console, the following error is shown: GET https://my-website.com/storage/uploads/iotpark/warranty/48_00C1D156_1602499479.jpg 403 (Forbidden) I have ..

Read more