Skip to content

Repository files navigation

Car Shop Demo

A full-featured car marketplace demo for browsing vehicles, managing accessories, and handling customer inquiries. The application includes a public storefront and an administration panel for managing the catalogue and site settings.

Built with CodeIgniter 3, Bootstrap 5, JavaScript, and MySQL.

This repository is intended as a demo and starting point for a car dealership marketplace. Review the configuration and security settings before deploying it to production.

Features

User Panel

  • Home Page: Car search, featured cars, latest cars, popular brands, accessories section
  • Car Listing: Advanced filters (brand, model, fuel, city, price, year), sorting
  • Car Details: Image gallery, specifications, seller info, WhatsApp inquiry
  • Accessories: Browse and filter car accessories, inquiry via WhatsApp
  • User Account: Login/Register, saved cars, inquiry history
  • WhatsApp: Sticky floating button on all pages, pre-filled inquiry messages

Admin Panel

  • Dashboard: Overview stats, recent inquiries
  • Car Management: Add/Edit/Delete cars, multi-image upload, approval system
  • Accessories Management: Add/Edit/Delete accessories
  • Inquiries: View all car/accessory inquiries with filters
  • Users: View and block/unblock users
  • Settings: WhatsApp number, logo, SEO meta tags, homepage banners

Tech Stack

  • Backend: PHP - CodeIgniter 3
  • Database: MySQL
  • Frontend: HTML5, CSS3, Bootstrap 5, JavaScript, jQuery

Installation

1. Requirements

  • PHP 7.4+ (with mysqli, gd, and mbstring extensions)
  • MySQL 5.7+ or MariaDB
  • Apache with mod_rewrite enabled, or an equivalent nginx configuration
  • Composer (optional; useful for managing CodeIgniter dependencies)

2. Get the project

Clone the repository into your web server's document root:

git clone https://github.com/pratikv1612/Car_Shop_demo.git
cd Car_Shop_demo

3. Database Setup

  1. Create database and import schema:
mysql -u root -p < database/vivek_carshop.sql

Or use phpMyAdmin:

  • Create database db_name
  • Import database/vivek_carshop.sql

4. Configuration

Copy the environment template and update the values for your machine or hosting provider:

copy .env.example .env

The application reads these environment variables:

APP_URL=http://localhost/VAutoSpare/
DB_HOST=localhost
DB_NAME=db_name
DB_USER=root
DB_PASSWORD=

If your server does not load .env files automatically, configure the same variables in Apache, nginx, or the hosting control panel. Never commit .env or real database credentials.

For an existing installation, the values can also be set directly in application/config/database.php:

'hostname' => 'localhost',
'username' => 'your_db_user',
'password' => 'your_db_password',
'database' => 'db_name',

The application URL can be set through APP_URL or directly in application/config/config.php:

$config['base_url'] = 'http://localhost/VAutoSpare/';
// For production: 'https://yourdomain.com/'

5. File Permissions

Ensure these directories are writable:

  • application/cache/
  • application/logs/
  • uploads/ (and subdirectories: cars, accessories, brands, banners)

6. Apache .htaccess

If using Apache, ensure mod_rewrite is enabled. The .htaccess file is included. For XAMPP, the RewriteBase in .htaccess is set to /VAutoSpare/. Adjust if your path differs.

7. Access the Application

First Login

Admin Login

  • Username: admin
  • Password: admin123

Change the default admin password immediately after the first login. Do not use the demo credentials in a production environment.

WhatsApp Configuration

  1. Log in to Admin Panel
  2. Go to Settings
  3. Enter your WhatsApp number (with country code, no + sign)
    • Example: 919876543210 for India
  4. Customize the default inquiry message template
  5. Save

The floating WhatsApp button and inquiry links will use this number.

Project Structure

Car_Shop_demo/
├── application/
│   ├── config/
│   ├── controllers/
│   │   └── admin/
│   ├── core/
│   ├── helpers/
│   ├── models/
│   └── views/
│       ├── admin/
│       ├── layout/
│       └── ...
├── assets/
├── database/
│   └── vivek_carshop.sql
├── uploads/
│   ├── cars/
│   ├── accessories/
│   └── banners/
├── system/
├── .htaccess
├── index.php
└── README.md

Security Notes

  • Enable HTTPS in production
  • Change default admin credentials
  • Set ENVIRONMENT to production in index.php
  • Keep CodeIgniter and PHP updated

License

MIT License. See license.txt for the full license text.

About

A CodeIgniter 3 car marketplace with vehicle listings, accessories, user accounts, WhatsApp inquiries, and an admin dashboard.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages