Skip to main content

All Questions

Tagged with
1 vote
1 answer
4k views

Cannot autowire service "App\Controller\MainController": argument "$session" of method "__construct()"

There is my MainController: <?php namespace App\Controller; use App\Entity\ShopCart; use App\Entity\ShopItem; use App\Repository\ShopItemRepository; use Doctrine\ORM\EntityManagerInterface; use ...
Anf_Fun's user avatar
  • 31
-1 votes
1 answer
761 views

How to make all my cart items have the same order ID when I check out?

I'm trying to build a website with shopping cart functionality using java servlet and mysql. When multiple items are added to the cart, the user can either buy them separately or check out all at once....
adria's user avatar
  • 15
1 vote
0 answers
1k views

how to change or update the quantity and total price?

This is my code in cart.php. I want to change or update the quantity according to the user want also the total price when updating the quantities but i dont know how to do it. How to fix this? I have ...
charlene's user avatar
0 votes
1 answer
57 views

dynamic transportation value in cart app laravel

I want to get the transportation cost from the database in the card.php but now its write statically 25000 .this cost must be dynamic that owner of site can be change it. in photo transportation ...
user avatar
0 votes
1 answer
58 views

I have a problem with updating the product quantity

I have a problem in updating the quantity of the product when I press the button 'plus', the quantity is not updated <i class="fas fa-plus plus " id="<?php echo $product_id; ?>&...
mehdi ouatmane's user avatar
0 votes
0 answers
4k views

SQL: shopping cart design for a marketplace

I'm working on a marketplace that requires the user to be logged in to add items to the shopping cart. In most online examples, I can't see the benefits of creating a separate cart and cart_item ...
Yousif's user avatar
  • 559
-1 votes
1 answer
406 views

Get quantity of certain product from database instead of session - Shopping Cart (PHP & MySQL)

I have been trying to create a persistent MySQL-based shopping cart application starting from a session-based php shopping cart. The cart table has the structure userid | productid | quantity | ...
Chiara's user avatar
  • 45
0 votes
0 answers
196 views

how to properly sort product item on a single page

so i'm new to developing an eCommerce site in general, trying this out for a personal project. so i have my products displayed on the home page under category "all products". i have it &...
NOOB's user avatar
  • 63
1 vote
0 answers
716 views

shopping cart in local storage connecting with mysql

I am currently working on building an E-commerce website and I am using HTML, CSS, Javascript, PHP and SQL. I have created my database for each product(ID, price, image, name). I defined my shopping ...
taikikun's user avatar
0 votes
1 answer
249 views

Payment with Saferpay, whats the correct Success url?

In my online shop, I'm using Saferpay as a Payment Gateway. When the customer clicks the "Pay" button, his order will be stored in my MySQL table called orders, and the customer will be ...
Ahmad Mardini's user avatar
-3 votes
1 answer
331 views

Symfony for PHP: inserting multiple rows to table from session using foreach

I'm writing a function to insert a new order with order items in it. Those items are stored in session. I need to insert all the items to order items table using Symfony for PHP. Here what I tried: $...
Silentcow's user avatar
1 vote
1 answer
490 views

How to decrement a column value in Laravel

This is the query i am using: $number = DB::table('products')->where('id', '=', $product->id)->update(['quantity' => 'quantity', '-', 1 ]); Please help me with the right syntax. I want to ...
Abdul Wadood's user avatar
0 votes
1 answer
986 views

PHP MYSQL Clear cart data from database if checkout is successful

i am trying to clear/delete the cart data from my database if the checkout is successful. this is the form on my website and this is the process of the CONTINUE TO CHECKOUT BUTTON <?php ...
olegnaopmaco's user avatar
0 votes
3 answers
53 views

Inventory count of my database keeps starting at 28?

I am new to coding and in my code and i am having trouble updating my database. I am using mysql and php to create a shopping cart that updates inventory when an item is purchased. The cart takes ...
harrison's user avatar
0 votes
2 answers
3k views

Adding Cart Items to the Database and retrieving

I have three tables in mySQL namely user, restaurants, cartlist. here user table is for saving the user details. restaurant table is for saving the meal details, price and quantity. cartlist is to ...
venu's user avatar
  • 13

15 30 50 per page
1
2 3 4 5
8