Browse AI Field GuideForum Podcast
All ThreadsLeaderboard
  1. Discussions

    1. Popular This Week
    2. Popular All Time
    3. Solved
    4. Unsolved
    5. No Replies Yet

Ahmed Alaa's avatar

What's the best way to design products and Collections in E Comerce System ?

I'm working on building an E-commerce system that deals with two types of goods either a single product or collections (one entity contains multiple products I created 3 tables products, collections, and collection_product. is this a good design? And furthermore, I want to have a section for related products (or goods because it'll contain both products and collections) and com

Ahmed Alaa's avatar
Ahmed Alaa's avatar jlrdw2yrs agoEloquent
1
1
Last reply by jlrdw 2yrs ago
faizi_856's avatar

SEO metas in react

I have ecommerce website developed in reactjs with APIs from laravel app. I used react-helmet to show metas(title, keywords etc.) on every page dynamically. Metas do appear if i browse my website in browser . But if I check url through any toolkit like https://metatags.io/, it shows static meta title added in index.html file. Can anybody please guide me as i am struggling a lo

faizi_856's avatar
faizi_856's avatar neiljiohu2yrs agoReact
11
8
Last reply by neiljiohu 2yrs ago
Nageeb_Dariwsh's avatar

Create Child Before Parent in laravel 10

i am building e-commerce website, i am using laravel to making api, i have Product Controller , it has fileds: title, description and images, and i make controller for images , so every product has its own images, and i made relationship : <?php namespace App\Models; use Illuminate\Database\Eloquent\Factories\HasFactory; use Illuminate\Database\Eloquent\Model; class Produ

Nageeb_Dariwsh's avatar
Nageeb_Dariwsh's avatar Nageeb_Dar...2yrs agoLaravel
4
1
Last reply by Nageeb_Dariwsh 2yrs ago
mikaeledstrom's avatar

Best practice settings for atomic cache lock in Laravel?

I am trying to learn about atomic locks to prevent race conditions in our e-commerce Laravel app. I believe there are these 2 possible numeric settings; maximum lock duration, e.g. 20 here "\Cache::lock('foo', 20)" block time when LockTimeoutException should occur, e.g. 10 here "->block(10" Is there a considered best practice of 1) and 2) If you use it

mikaeledstrom's avatar
mikaeledstrom's avatar mikaeledst...2yrs agoLaravel
0
1
kinggs's avatar

Best strategy for hosting assets

Hello. I'm currently managing an ecommerce store built on Laravel featuring thousands of products. When adding a product, we store the image, create multiple sizes, watermark them and host them all in DigitalOcean Spaces. This causes massive headaches with maintainability, for example if we want to add a new image size or a watermark. Is there a better way, from a maintenance p

kinggs's avatar
kinggs's avatar martinbean2yrs agoDevOps
3
1
Last reply by martinbean 2yrs ago
lalitesh's avatar

Suggestion on a tech stack for an auction app

Hello Experts, I have built a marketplace ecommerce application on Laravel & inertiajs ( with vuejs ) stack and now need to add another module i.e. auction. Could I have few suggestions with pros & cons, for what other stack should I use to build the real-time auction module? I have read about Laravel Echo, socket.io & pusherjs but unsure which of them should be the

lalitesh's avatar
lalitesh's avatar ianhobbs7mos agoLaravel
3
1
Last reply by ianhobbs 7mos ago
TimiAde's avatar

Laravel Vuejs e commerce project

Is there any course i can learn how to build an ecommerce site with laravel and vuejs using apis

TimiAde's avatar
TimiAde's avatar Tray22yrs agoGeneral
2
1
Last reply by Tray2 2yrs ago
faust's avatar

Optimal project folder structure for Laravel + Vue SPA

Hello I recently got into Vue 3 as my first frontend framework and going through a few courses and tutorials, I noticed various ways different people structure their projects. Some create two folders (frontend - backend) and initialize Laravel/Vue separately, some create a Laravel project and inside it create a Vue folder and initialize it there, some simply create a folder ins

faust's avatar
faust's avatar faust2yrs agoVue
2
1
Last reply by faust 2yrs ago
MahmoudAdelAli's avatar

Find a id of nested relation

Hi , i have laravel e-commerce with customer table and order table and order_details table the customer has many orders and each order has a order_details i want when a user enter the product view - if he order this product before he got a link to review it so now i want to get order_details id to send it with this link so i write this code auth('customer')->user()->ord

MahmoudAdelAli's avatar
MahmoudAdelAli's avatar vincent150...2yrs agoCode Review
3
1
Last reply by vincent15000 2yrs ago
amiable-iguana's avatar

Undo Seeded Data

I have an e-commerce application, and I have mistakenly seeded some incorrect data that has been run on production database. What is the best practice to correct this data? I have some new categories that I need to add and some need renaming, and I also have some products that were generated by factories which need to be deleted. My plan is to update the category seeder, and de

amiable-iguana's avatar
amiable-iguana's avatar Snapey2yrs agoLaravel
5
1
Last reply by Snapey 2yrs ago
Naman178's avatar

Laravel SEO

I have a Laravel-based e-commerce site focused on wallet products, and I'm seeking tips or tutorials to enhance its SEO and increase its visibility in search results. Any assistance or guidance would be greatly appreciated.

Naman178's avatar
Naman178's avatar Naman1782yrs agoTips
5
51
Last reply by Naman178 2yrs ago
Shivamyadav's avatar

Why i am getting this error? In PHP

This is the my index.php file code <?php echo $_SERVER['REQUEST_URI']; $uri = parse_url($_SERVER['REQUEST_URI'])['path']; $routes = [ '/' => '/index.php', '/register' => '/register.php', '/login' => '/forms/login/login.php', '/logout' => '/forms/logout/logout.php', '/admin/profile' => '/forms/admin/index.php', '/contact' => 'control

Shivamyadav's avatar
Shivamyadav's avatar jlrdw3yrs agoLaravel
12
1
Last reply by jlrdw 3yrs ago
Marre86's avatar

Conflicting session middlewares for 'web' and 'api'

I am working on ecommerce Laravel project. I decided to use darryldecode Cart package for my Cart. The problem is that it stores its data in session. And it works smoothly as far as I deal with 'web' part of my app. But when I implement my API, I need to add Illuminate\Session\Middleware\StartSession::class, in my Kernel.php, in'api' middlewareGroups, because otherwise data isn

Marre86's avatar
Marre86's avatar Snapey3yrs agoLaravel
4
1
Last reply by Snapey 3yrs ago
einchewon's avatar

How would you structure a system with multiple bussiness "regions"?

For example, an e-commerce site, where there are a "region" for the sellers, with feature align to managing products or selling analytic. And a front-facing "region" for regular clients to browse the products, have a cart, bookmark or follow products or brands https://routerlogin.uno/ . When there are 2 (or more) distinct regions for different functionality

einchewon's avatar
einchewon's avatar Ben Taylor3yrs agoFeedback
1
1
Last reply by Ben Taylor 3yrs ago
colinlongworth's avatar

Converting UTC to an arbitrary timezone for reporting

I have a system which recieves a webhook from an ecommerce system. The Laravel system is configured to use UTC. The database is PostgreSQL. The webhook is used to create an Order model. To align the creation date, I use the webhook date e.g. $order->created_at = $webhook->created_at; $order->save(); where the webhook would have the format: "created_at": &qu

colinlongworth's avatar
colinlongworth's avatar LaryAI3yrs agoGeneral
1
1
Last reply by LaryAI 3yrs ago
Sam's avatar

Showing a basket outside or template

Hi folks, So I have a bit of a project im working on which involves developing a e-commerce like functionality. I have designed and implemented a 'slide in' mini-basket. I then have a productView template inside a 'Site' layout. Within the productView template is a Add to Basket button, how can I get the basket to trigger and open from this button - would I need to use somethin

Sam's avatar
Sam's avatar Sam3yrs agoInertia
3
1
Last reply by Sam 3yrs ago
slacky's avatar

laravel product recommendations

Hello guys i am developing product recommendation feature for ecommerce system, is there any package or algorithm you suggest

slacky's avatar
slacky's avatar slacky3yrs agoTips
2
1
Last reply by slacky 3yrs ago
alancgdw's avatar

N+1 problem relationships using repeated tables

Hi, I've been trying to figure out how to properly eager load and solve a N+1 problem I'm having in a ecommerce project. I'm using the Laravel N+1 Query Detector, and when loading the cart page, it show's this alert: Found the following N+1 queries in this request: Model: App\Models\Product => Relation: App\Models\ProductAttribute - You should add "with('AppModelsProduc

alancgdw's avatar
alancgdw's avatar alancgdw3yrs agoEloquent
19
4
Last reply by alancgdw 3yrs ago
peterdickins's avatar

Calling a scope function twice not unique table/alias mysql error

Hi, I have an ecommerce application and have the following models: Sku and Variation. It's a many to many relationship: class Sku extends Model { public function variations(): BelongsToMany { return $this->belongsToMany(Variation::class) ->using(VariationSku::class) ->withPivot('value'); } public function product(): Belo

peterdickins's avatar
peterdickins's avatar peterdicki...3yrs agoEloquent
1
1
Last reply by peterdickins 3yrs ago
QI's avatar

How to create fast advanced search with big database?

I am looking at implementing the "Advanced Search" from Codyhouse (Laravel 9, vue.js) https://codyhouse.co/ds/components/app/advanced-search The search should allow to find everything from thousands of E-Commerce items, Blog articles, Users, Collections, and perhaps even Support docs. Now I wonder how you would approach this task as searching so many tables and thous

QI's avatar
QI's avatar LaryAI3yrs agoGeneral
1
1
Last reply by LaryAI 3yrs ago
NoLAstNamE's avatar

Cart implementation

I am planning on making my own E-commerce platform just to serve as a practice project to improve my coding skills in Laravel. How would you implement or write a Cart logic? this is a simple app and it doesn't need to have an API. Looking forward to your ideas!

NoLAstNamE's avatar
NoLAstNamE's avatar benjamin15...3yrs agoLaravel
2
1
Last reply by benjamin1509 3yrs ago
omrto's avatar

How to model inventory and products for manufacturer/retailer

I'm looking for some conceptual advice on database design and modeling in my Laravel project. I work for a manufacturer of portable buildings and metal roofing supplies. We sell products in 3 different ways: buy and resale manufacture metal roofing panels and trim (one stage production process) manufacture portable buildings (4 stage production process) I'm creating a custom,

omrto's avatar
omrto's avatar sosaheri3yrs agoLaravel
2
1
Last reply by sosaheri 3yrs ago
ufodisko's avatar

Best way to create a simple points system (not rewards)?

This "points system" is not an e-commerce rewards system. I'll assign 3 types of points when the user subscribes to a plan and then start deducting points based on the user's app usage. I was thinking of creating a separate table called points that will hold the user's points. Points: id, points1, points2, points3, user_id And then I'll start removing points by modif

ufodisko's avatar
ufodisko's avatar ufodisko3yrs agoLaravel
2
1
Last reply by ufodisko 3yrs ago
kingsleyuchenna's avatar

Store all phone numbers in one table

I am trying this concept I don't know if it is a wrong idea. So, I want to build an e-commerce site on my site I will have site contact (with phone numbers, emails, addresses etc), users shipping addresses, and I might have other places with phone numbers, emails, and addresses. So, my idea is to create a phone_numbers table to store all the numbers on the site, target columns

kingsleyuchenna's avatar
kingsleyuchenna's avatar whoisthiss...3yrs agoEloquent
3
4
Last reply by whoisthisstud 3yrs ago
Devedge's avatar

Getting unique product results with Eloquent (ignoring variations)?

Hi, I'm hoping someone can help me with this. I've been provided with ecommerce Excel spreadsheets which contain thousands of products. I've got the import working using the Maatwebsite Excel package but have run into an issue with returning paginated results which I need to return only the first of each product but not the other variations. So, in my database I have the sku of

Devedge's avatar
Devedge's avatar Sinnbeck3yrs agoEloquent
7
1
Last reply by Sinnbeck 3yrs ago
ljwjulian's avatar

having problem with send data and redirect in Laravel 9

I am trying to build an e-commerce site using Laravel 9 with breeze starter kit. And now working on the order process but something I don't understand happening. On the order page, I sent form data to Controller using Axios. But then after got the result, the page reloaded with the form data as get parameters, like this. I sent post data on https://my.doman/order/123/4 The page

ljwjulian's avatar
ljwjulian's avatar ljwjulian3yrs agoLaravel
2
1
Last reply by ljwjulian 3yrs ago
aknEvrnky's avatar

best way to store guest users' data

Hi folks, currently I'm working on an e-commerce project. I need to store non signed in people's data such as Cart products, address, etc. My current workflow is like this: Whenever user adds an item to basket, save it to cookie with base64 encoded. User may enter address and sender informations. Get cookie, resolve it, and merge it with new data. then store it in cookie with b

aknEvrnky's avatar
aknEvrnky's avatar aknEvrnky3yrs agoDesign
2
1
Last reply by aknEvrnky 3yrs ago
HannahSofia12's avatar

Errors on my website

I have recently created an e-commerce website using coding that I learned from your site. However, I am currently facing an issue where users of the website are encountering a 404 error message after spending a few minutes on the website page. I am not sure if this is an error caused by my coding, but I would like to get a better understanding of what might be causing this issu

HannahSofia12's avatar
HannahSofia12's avatar Sinnbeck3yrs agoCode Review
3
1
Last reply by Sinnbeck 3yrs ago
Saad Elkammah's avatar

Email Verification for other guards in Laravel breeze

I am developing an e-commerce website and have 3 guards where I need to make authentication based on breeze package for the first guard(user) it works well by default, and I need to implement authentication on other guards, then I face problems with verifying email,After registration of seller for example I have been redirected to home page directly without having [verify-email

Saad Elkammah's avatar
Saad Elkammah's avatar Saad Elkam...3yrs agoLaravel
0
1
vickypandey's avatar

Undefined array key "image" while updating data

Hello, I have a problem with my laravel project (I'm quite new to Laravel). So I'm creating an e-commerce website and everything was fine until i decided to update my slider data and image to my slider. Now when I am submitting my form i have an error: Undefined array key "image". public function update(SliderFormRequest $request, Slider $slider) { $validatedData = $r

vickypandey's avatar
vickypandey's avatar vickypande...3yrs agoLaravel
4
1
Last reply by vickypandey 3yrs ago
deicool's avatar

CodeIgniter to Laravel Migration

Hello I am a newbie. I have a ecommerce website in CodeIgniter. I would like to migrate it to Laravel. Is there a tool for the same? Please advise. Thanks.

deicool's avatar
deicool's avatar Sinnbeck3yrs agoLaravel
3
1
Last reply by Sinnbeck 3yrs ago
Chris R.'s avatar

Storing translation data - JSON column vs separate table

There are few topics out there, but some are old and i havent found good answer yet. There are two packages for Laravel which has a different approach to store translation data to database: spatie/laravel-translatable - stores data to json column astrotomic/laravel-translatable - stores data to separate table Im sure theres not much difference in small website, but lets talk

Chris R.'s avatar
Chris R.'s avatar illuminati...3yrs agoGeneral
1
1
Last reply by illuminatixs 3yrs ago
Yablochnyi's avatar

Why is the cycle duplicated?

Good afternoon! I got an old project from the archive, I did not write it. Locally I ran it, when choosing a category of posts, they are duplicated. Please advise how to fix this problem. A project was written on lumen, there is not enough information on the Internet that could help me with my poor knowledge. There is a form in which I select post categories <form class=&quo

Yablochnyi's avatar
Yablochnyi's avatar Yablochnyi3yrs agoLumen
0
1
CODE-AXION's avatar

i am confused if i should use product_category pivot table or use tags table and product_tags table

i have an ecommerce application where i have categories and subcategories now the problem is for eg:- i have a category calls Clothes which have subcategories Men, Women and Kids and each subcategory has its own subcategories like men hoodies, men jeans etc... but i want to show men hoodies in black hoodies category too etc... so i have 2 options either make 1) product_category

CODE-AXION's avatar
CODE-AXION's avatar Nihir3yrs agoLaravel
3
1
Last reply by Nihir 3yrs ago
priyalaks's avatar

Login Controller - Add few checks

In my Ecommerce project , I am trying to check if the current user has any items in his cart with the help of session id. So When he adds items to cart and then tries to login - the session needs to be updated on the cart to preserve his cart items. In order to achieve this I need to add few checks during login as the Session gets regenerated - so where should I add my Cart Lo

priyalaks's avatar
priyalaks's avatar priyalaks3yrs agoLaravel
1
1
Last reply by priyalaks 3yrs ago
Sam's avatar

Routing - no prefix for category/product

Hi all, Just wondering if there's a more succinct way of handling my current situation. So we are in the process of redeveloping a large e-commerce website from procedural. So the routing is currently as follows: www.website.com/category-slug www.website.com/product-slug Both currently share a verryyyy long procedural file to lookup and work out whether it's a category that sho

Sam's avatar
Sam's avatar MichalOrav...3yrs agoLaravel
1
1
Last reply by MichalOravec 3yrs ago
Cainy's avatar

Implementing Payment Drivers

Dear Laravel community, I am currently working on a fully custom e-commerce site. I am just not quite sure how to implement the payments. The problem here is that I have to write my own API-drivers for multiple different payment providers. So we have some payment methods that are provided by provider A and some by provider B. I thought I'd make an abstract class PaymentDriver a

Cainy's avatar
Cainy's avatar martinbean3yrs agoLaravel
5
1
Last reply by martinbean 3yrs ago
Kris01's avatar

Laravel to Firebase

Hey guys, How much time would it take to transfer a web aplication, an ecommerce for example, something more complex, from Laravel to Firebase?

Kris01's avatar
Kris01's avatar Sinnbeck3yrs agoCode Review
8
1
Last reply by Sinnbeck 3yrs ago
Neethu Ah's avatar

Laravel with leader system connection

Is it possible to connect a ecommerce website to leader system for purchasing.

Neethu Ah's avatar
Neethu Ah's avatar Neethu Ah3yrs agoFeedback
2
1
Last reply by Neethu Ah 3yrs ago
aosdev's avatar

Which multilanguage approach fits for my database?

Hey guys, I'm really confused about making my new project's db multilanguage supported. I was using json for all fields but when i test json fields i see the performance is decreasing enormously when i add like 500k records. I have a e-commerce project and i am trying to use multilanguage in my db. I have tables like; Products id title description seo_title seo_description seo

aosdev's avatar
aosdev's avatar kokoshneta3yrs agoDesign
3
1
Last reply by kokoshneta 3yrs ago
luayjal's avatar

I have a problem in google analytics with the price of the product

I have a problem in google analytics with the price of the product when I make a purchase event the price does not appear but when I follow the debug view I show the price I attached the images for this https://i.stack.imgur.com/UHq7D.png , https://i.stack.imgur.com/4Qo1W.png but when I went to report to E-commerce purchases page and see the product item I can't see the pr

luayjal's avatar
luayjal's avatar Sairahcaz1yr agoServers
1
1
Last reply by Sairahcaz 1yr ago
Salman98's avatar

trying to access array offset on value of type null ['subtotal']

Hello Guys i've been following this Laravel/livewire E-Commerce series and i ecountered this frustrating error. Everything seems to be oky with the code but each time i click on the place order button from my checkout page, it raises a "trying to access array offset on value of type null ['subtotal']". i really dont know what to do. i am kinda a newbie. will really ap

Salman98's avatar
Salman98's avatar tykus3yrs agoLaravel
1
1
Last reply by tykus 3yrs ago
priyalaks's avatar

Multiple Combination of Product and Its Variation

For my e-commerce website , I am trying to multiple combination of a product variant . For Example : Product : Shirt Combination of the Variant : Size and Color Product : Mobile Phone Combination of the Variant : RAM , Storage Capacity , Colors Product : Fruits Combination of the Variant : Weight and keeps on varying based on each product - so how could I dynamically uplo

priyalaks's avatar
priyalaks's avatar martinbean3yrs agoTips
7
1
Last reply by martinbean 3yrs ago
Salman98's avatar

@if(Session::has('checkout'))

Hello Guys I've been following this Laravel/livewire E-Commerce series and I encountered this frustrating error. Everything seems to be okay with the code. I just want to show the grand total. But I cannot see it on my page. There is no any error showing. Actually I am kind a newbie. Can I get a solution? And I don't have proper idea what the meaning of @if(Session::has('checko

Salman98's avatar
Salman98's avatar Aung Htet...3yrs agoLaravel
9
1
Last reply by Aung Htet Paing__ 3yrs ago
bicicura's avatar

Auth system. Breeze or Jestream

Hi! I'm starting an e-commerce project for a client. I want to use Breeze / Inertia / React.js scaffolding. Yet, I want to make sure if Laravel Breeze has all features a simple e-commerce site needs and if someone has already used it in production, I would be glad to hear your experience. :) I have experience with Breeze, used it in many projects but the catch is that the syste

bicicura's avatar
bicicura's avatar bicicura3yrs agoLaravel
4
1
Last reply by bicicura 3yrs ago
Salman98's avatar

"trying to access array offset on value of type null $order->subtotal = session()->get('checkout')['subtotal'];

Hello Guys i've been following this Laravel/livewire E-Commerce series and i ecountered this frustrating error. Everything seems to be oky with the code but each time i click on the place order button from my checkout page, it raises a "trying to access array offset on value of type null ['subtotal']". i really dont know what to do. i am kinda a newbie. will really ap

Salman98's avatar
Salman98's avatar Salman983yrs agoLaravel
5
1
Last reply by Salman98 3yrs ago
cancreate's avatar

Seprate Service Class for API & Web?

I'm working on an eCommerce project where I've a service class ShipperService.php. Inside that service class I've got 2 methods authenticate() & register(). Now shipper can only authenticate via API call the response of which will be in JSON but, when it comes to register() method the shipper can register via API call as well as admin can create an account for shipper the r

cancreate's avatar
cancreate's avatar martinbean3yrs agoLaravel
2
1
Last reply by martinbean 3yrs ago
MainLess's avatar

About the Refund Policy

Hello, there are different refund rights according to the laws of the country where I live. There is an unconditional free return right for 14 days. We have applied this process to our e-commerce system with Laravel, we can receive refunds, but the point I want to ask is this: How would it make sense for me to detect products that do not meet the 14 day requirement in the backe

MainLess's avatar
MainLess's avatar MohamedTam...3yrs agoGeneral
6
1
Last reply by MohamedTammam 3yrs ago
MooseSaid's avatar

Stripe payout

Does anyone know how to perform a payout action from your platform to a user? I'm building an e-commerce where users can sell products, after a successful customer payment, the user receives credit on his account. This part is working perfectly, now I want the user to be able to withdraw his money from the platform. Basically what I need is something that allows me to tell stri

MooseSaid's avatar
MooseSaid's avatar MooseSaid3yrs agoLaravel
17
1
Last reply by MooseSaid 3yrs ago
NadeemAkhter's avatar

API base website is better or not ??

We make a ERP solution for a ecommerce organization. Solution include ware house managemnt , POS management , website , admin portal All modules are linked with admin portal through API (curl on every request), We aspect average 2 , 3k users every time on website.. And on sales days its goes to 10 15k users. Is this system(API base) handle this stress ??

NadeemAkhter's avatar
NadeemAkhter's avatar jlrdw3yrs agoLaravel
4
1
Last reply by jlrdw 3yrs ago

Want us to email you occasionally with Laracasts news?

Nine out of ten doctors recommend Laracasts over competing brands. Come inside, see for yourself, and massively level up your development skills in the process.

Learn
BrowseSeriesCreatorSeriesLaravel PathLarabitsPlayground
Discuss
ForumPodcastSupport
Extras
Gift CertificatesApparelFAQiOS AppTerms
Social
X(Twitter)TikTokYoutube

© Laracasts 2026. All rights reserved. Yes, all of them. That means you, Todd.

Proudly hosted with Laravel Forge and DigitalOcean.

Want us to email you occasionally with Laracasts news?

Nine out of ten doctors recommend Laracasts over competing brands. Come inside, see for yourself, and massively level up your development skills in the process.

Learn
BrowseSeriesCreatorSeriesLaravel PathLarabitsPlayground
Discuss
ForumPodcastSupport
Extras
Gift CertificatesApparelFAQiOS AppTerms
Social
X(Twitter)TikTokYoutube

© Laracasts 2026. All rights reserved. Yes, all of them. That means you, Todd.

Proudly hosted with Laravel Forge and DigitalOcean.