Download the PHP package ttpryg/cart-engine without Composer
On this page you can find all versions of the php package ttpryg/cart-engine. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Table of contents
Download ttpryg/cart-engine
More information about ttpryg/cart-engine
Files in ttpryg/cart-engine
Download ttpryg/cart-engine
More information about ttpryg/cart-engine
Files in ttpryg/cart-engine
Vendor ttpryg
Package cart-engine
Short Description A framework-agnostic standalone item-agnostic cart engine library for shopping and booking systems.
License MIT
Package cart-engine
Short Description A framework-agnostic standalone item-agnostic cart engine library for shopping and booking systems.
License MIT
Please rate this library. Is it a good library?
Informations about the package cart-engine
CartEngine Library
ttpryg/cart-engine is a framework-agnostic standalone PHP library for item-agnostic shopping carts and booking/reservation systems. It is completely decoupled from any specific product schema or database table.
🌟 Key Features
- Framework Agnostic: Compatible with any PHP 8.1+ project (Vanilla PHP, Slim, Laravel, Symfony, CodeIgniter).
- Item-Agnostic / Polymorphic: Supports physical products, digital items, hotel room bookings, car rentals, service appointments, or event tickets without hardcoded database coupling.
- Decimal Quantities: Supports fractional or decimal quantities (e.g.
2.5hours,3nights,1.5kg). - Multiple Storage Drivers:
FileCartStorage: Local JSON cache files (storage/carts/or/tmp/carts/).PdoCartStorage: Relational database via PDO (MySQL, MariaDB, SQLite).MemoryCartStorage: In-memory storage for unit testing.SessionCartStorage: PHP$_SESSIONwrapper.
- Cart Conditions: Apply discounts (
-10%,-50000), taxes (+11%), shipping fees (+20000), or booking deposits to the cart. - Domain Events:
ItemAddedToCartEvent,ItemRemovedFromCartEvent,CartClearedEvent,ConditionAppliedEvent.
🗄️ Database Schema (Optional - for PDO Storage Driver)
Run the SQL script from database/schema.sql or use DatabaseMigrator:
🚀 Quick Usage Examples
1. E-Commerce Product Shopping Cart (File Cache Storage)
2. Hotel Room Booking Cart (PDO Storage)
📄 License
MIT License.
All versions of cart-engine with dependencies
PHP Build Version
Package Version
Requires
php Version
>=8.1
The package ttpryg/cart-engine contains the following files
Loading the files please wait ...