Simple PHP Tournament Script – PHP & AngularJS – Download Source Code

simple-php-tournament-script-angularjs
Important Note: This script is not updated in a while. But it still works. Download at your own risk.

Download and learn how this simple tournament script was made. Technologies used include PHP, MySQL, AngularJS, Material Design and jQuery.

Script Overview

This script is an addition to our tutorial: PHP, MySQL and AngularJS CRUD Tutorial – Step by Step Guide!

Studying this script will help you learn more coding techniques with PHP and AngularJS. Some include learning a better file structure, working with 4 objects, dynamic drop-down data (retrieved from database), routing and more.

We call this script "simple tournament script" because it features four objects related to a tournament: matches, countries, tournaments and teams.

Before you download, please make sure you have basic understanding of the following topics.

a. PHP, MySQL and OOP CRUD Tutorial – Step by Step Guide!
b. PHP, MySQL and AngularJS CRUD Tutorial – Step by Step Guide!

If you learned our tutorials above, this script should be easy to understand.

Output Preview

Below are some screenshots of our script's output. You can click an image to view the larger version of it.

Please note that the following images are just output previews. New features might be added already the time you are reading this.

[espro-slider id=5707]

If you need the live demo link, send a request to [email protected] with subject "DEMO Request: Tournament System Script", thank you!

Database Design

database-design-erd

File Structure

├─ app/
├─── countries/
├────── countries_controller.js
├────── countries_records.html
├────── country.html
├────── create_country.php
├────── delete_country.php
├────── delete_selected_contry.php
├────── export_countries_csv.php
├────── read_countries.php
├────── read_one_country.php
├────── update_country.php
├─── matches/
├────── create_match.php
├────── delete_match.php
├────── delete_selected_matches.php
├────── export_matches_csv.php
├────── match.html
├────── matches_controller.php
├────── matches_records.html
├────── read_matches.php
├────── read_one_match.php
├────── update_match.php
├─── shared/
├────── app.js
├────── dir_pagination.tpl.html
├─── teams/
├────── create_team.php
├────── delete_selected_teams.php
├────── delete_team.php
├────── export_teams_csv.php
├────── read_one_team.php
├────── read_teams_by_country.php
├────── read_teams.php
├────── team.html
├────── teams_controller.js
├────── teams_records.html
├────── update_team.html
├─── tournaments/
├────── create_tournament.php
├────── delete_selected_tournament.php
├────── delete_tournament.php
├────── export_tournaments_csv.php
├────── read_one_tournament.php
├────── read_tournaments_by_country.php
├────── read_tournament.php
├────── tournament.html
├────── tournaments_controller.js
├────── tournaments_records.html
├────── update_tournament.html
├─── config/
├────── database.php
├─── dev/
├────── readme.txt
├────── tournament_system.sql
├─── libs/
├────── css/
├───────── materialize/
├────── js/
├───────── angular.min.js
├───────── dirPagination.js
├───────── jquery.js
├────── objects/
├───────── country.php
├───────── match.php
├───────── team.php
├───────── tournament.php
├────── index.html

Features List & Download

FEATURE SIMPLE PHP TOURNAMENT SCRIPT
Learn more techniques when coding with PHP, MySQL and AngularJS YES
Save your precious time searching about how to do the features below. YES
Single page application (SPA) YES
Material design YES
Create and update forms are in modal / pop-up YES
Action buttons are displayed with icons YES
MATCHES
Create match YES
Read matches YES
Read one match YES
Update match YES
Delete match YES
Delete selected matches YES
Search matches YES
Export matches to CSV YES
Matches pagination YES
Matches pagination in search results YES
Route to matches section with /tournament-system/#/ in URL YES
When creating or updating a match
Load tournaments based on selected country YES
Load home teams based on selected country YES
Load visitor teams based on selected country YES
Countries drop-down data retrieved database YES
Automatically update countries drop-down when countries data were changed YES
Tournaments drop-down data retrieved database YES
Automatically update tournaments drop-down when tournaments data were changed YES
Home team drop-down data retrieved database YES
Automatically update home team drop-down when home team data were changed YES
Visitor team drop-down data retrieved database YES
Automatically update visitor team drop-down when visitor team data were changed YES
Horizontal table scroll were enabled because of several columns needed to be displayed YES
COUNTRIES
Create country YES
Read countries YES
Read one country YES
Update country YES
Delete country YES
Delete selected countries YES
Search countries YES
Export countries to CSV YES
Countries pagination YES
Countries pagination in search results YES
Route to countries section with /tournament-system/#/countries in URL YES
TOURNAMENTS
Create tournament YES
Read tournaments YES
Read one tournament YES
Update tournament YES
Delete tournament YES
Delete selected tournaments YES
Search tournaments YES
Export tournaments to CSV YES
Tournament pagination YES
Tournament pagination in search results YES
Route to tournaments section with /tournament-system/#/tournaments in URL YES
When creating or updating a tournament
Countries drop-down data retrieved database YES
Automatically update countries drop-down when countries data were changed YES
TEAMS
Create team YES
Read teams YES
Read one team YES
Update team YES
Delete team YES
Delete selected teams YES
Search teams YES
Export teams to CSV YES
Teams pagination YES
Team pagination in search results YES
Route to teams section with /tournament-system/#/teams in URL YES
When creating or updating a team
Countries drop-down data retrieved database YES
Automatically update countries drop-down when countries data were changed YES
UPDATES AND SUPPORT
Free source code updates for 2 years YES
Free support for 6 months YES
BUY TO DOWNLOAD USING

 

* You can use your debit or credit card with PayPal.

Simple Set Up

If you download this source code. Here are the steps to run it.

1. You have to create your database using PhpMyAdmin
2. Database name is "tournament_system"
3. Import the SQL file called "tournament_system.sql" located in the "dev" folder.
4. You can ask me any questions related to this source code via:
a. Send me an email. My email address is [email protected]
b. Go to https://fb.com/codeofaninja and chat me up.

Thank You!

Thank you for reading about this tournament system script and supporting our projects here at codeofaninja.com!

If you have any questions, comments or suggestions, please do not hesitate to contact me.
a. Send me an email. My email address is [email protected]
b. Go to https://fb.com/codeofaninja and chat me up.

PHP Contact Form Module

simple-php-contact-form-script

Download and learn how this simple PHP Contact Form Script was made. Technologies used include PHP OOP, MySQL, Bootstrap and HTML5.

Script Overview

This source code will enable you to add a 'contact form' feature on your website. This source code is a very good starting point if you're trying to build your own 'Contact Form Script' from scratch and add some more complex features later.

This is because the basis of this source code are our step by step and easy to understand tutorial. Specifically this tutorial: PHP, MySQL and OOP CRUD Tutorial – Step by Step Guide!

The system looks simple. But I assure you that when you study the source code, you will learn a lot of useful PHP coding techniques.

Some include: How to send a message to a valid email address from a web form, use of settings for your contact form, collecting and storing customer messages on your own database, admin restrictions and more! You can see the detailed list of features on section 6.0 below.

Is This Code For Me?

The source code in this page is NOT for you if:

  • You are already an expert in PHP & MySQL programming.
  • You have a lot of time to code the listed features of our PHP contact form script
  • You are not that interested in learning PHP & MySQL programming.

But, this SOURCE CODE is FOR YOU if:

  • You want to SAVE a significant amount of development time.
  • You want to develop your own PHP contact form script from scratch.
  • You determined to learn how to make a this web application feature in PHP & MySQL.
  • You need some guidance in learning about this script (I'll personally support you & answer your questions)

But if you are an expert in PHP & MySQL programming and would like to take a look at our code, please do so! We’d love to hear your response and great insights! The comments section below is always open for anyone with questions and suggestions.

Pre-Requisite

Before you download, please make sure you have basic understanding of the following topics.

a. PHP, MySQL and OOP CRUD Tutorial – Step by Step Guide!
b. Apache .htaccess RewriteRule Examples

Once you learned our tutorials above, this source code should be easy to understand.

Output Preview

Below are some screenshots of our script's output. You can click an image to view the larger version of it.

Please note that the following images are just output previews. New features might be added already the time you are reading this.

[espro-slider id=6269]

Database Design

Our database name will be "php_contact_form", and we will have three tables: Messages, Settings and Users.

database-design-php-contact-form-script

File Structure

The following folders and files are included in our source code. It will have more meaning if you will see the code inside the folders and files.
├─ admin/
├─── delete_message.php
├─── index.php
├─── layout_foot.php
├─── layout_head.php
├─── login_checker.php
├─── navigation.php
├─── paging.php
├─── read_message.php
├─── read_message_template.php
├─── search_messages.php
├─── settings.php
├─ config/
├─── core.php
├─── database.php
├─ dev/
├─── php_contact_form.sql
├─── readme.txt
├─ images/
├─ libs/
├─── css/
├────── bootstrap/
├────── font-awesome/
├─── js/
├────── bootbox.min.js
├────── custom-script.js
├────── jquery.js
├─── php/
├────── pw-hashing/
├────── utils.php
├─ objects/
├─── message.php
├─── setting.php
├─── user.php
├─ .htaccess
├─ contact.php
├─ index.php
├─ info.php
├─ layout_foot.php
├─ layout_head.php
├─ login.php
├─ logout.php
├─ navigation.php

What People Say?

Here's what people feel about our work and source code downloads.

Features List & Download - PHP Contact Form Script

FEATURE PHP CONTACT FORM SCRIPT
Learn more techniques when coding with PHP, MySQL and OOP YES
Save your precious time coding and searching about how to do the features below. YES
PHP PDO and Prepared Statements YES
jQuery enabled YES
Bootstrap enabled YES
Font-awesome enabled YES
Buttons are displayed with appropriate icons YES
CONTACT FORM
Name field YES
Email field YES
Subject field YES
Message field YES
Client side validation (HTML5) YES
Server side validation (PHP) YES
Display contact email from settings YES
Display contact number from settings YES
Display contact person from settings YES
Store customer message to database YES
Send message to contact email (email set in the settings) YES
Send confirmation email to customer YES
Sending email can work via localhost using the PhpMailer library YES
FORM SECURITY
Uses htmlspecialchars($_SERVER["PHP_SELF"]) for form action YES
Made sure $_SERVER["REQUEST_METHOD"]=="POST" YES
Sanitize each submitted field with htmlspecialchars(), strip_tags() and trim() functions YES
Require value for each field YES
Show an error message under input fields if value is missing YES
Validate email address format YES
Keep values in the form if there are any error YES
MESSAGES
List messages collected from customers using the contact form YES
Display name, subject, sent and action columns YES
Unread messages in white row background YES
Read messages in gray row background YES
Pagination of messages YES
Search messages by name, email, subject and message fields YES
Read a message YES
Delete a message YES
SETTINGS
Setting for contact firstname YES
Setting for contact lastname YES
Setting for contact gender YES
Setting for contact email YES
Setting for contact number YES
Decide if you'll show contact name YES
Decide if you'll show email YES
Decide if you'll show contact number YES
USER
Login using email and password YES
Log out user YES
Hashed password stored in database YES
Logged-in user name display on the right side of navigation bar YES
Log-out button displayed on drop-down when user name was clicked YES
Messages can be read by logged-in admin. YES
Messages can be deleted by logged-in admin. YES
SUPPORT AND UPDATES
Free support for 6 months. YES
Free source code updates. YES

Simple Set Up

By now, you were able to download this (PHP Contact Form Script) source code. Here are the few instructions about how to run it.

1. Copy the extracted files to your localhost or upload it to your webserver.

2. You have to create your database using PhpMyAdmin, name of the database: php_contact_form

3. Import the SQL file called "php_contact_form.sql" located in the "dev" folder.

4. Change line 7 .htaccess file (No changes should be made if you put the files on the root directory of your localhost)

RewriteBase /YOUR_ROOT_DIRECTORY/

5. Run the login.php file on your browser, use the following user credentials.

Username: [email protected]
Password: [email protected]

6. To see the contact form, run contact.php

Thank You!

Thank you for reading about this PHP Contact Form Script source code and supporting our projects here at codeofaninja.com!

If you have any questions, comments or suggestions, please do not hesitate to contact me.
a. Send me an email. My email address is [email protected]
b. Go to https://fb.com/codeofaninja and chat me up.

PHP Content Management Module

php-web-page-content-management-system
Looking for PHP Contact Form Script? Click Here.

Download and learn how this simple PHP Web Page Content Management System was made. Technologies used include PHP OOP, MySQL, Bootstrap and jQuery.

Script Overview

This source code will enable you to manage a dynamic web page content. You can format the content the way you want it. Put links, files, images, texts and more on your web page.

The system looks simple. But I assure you that when you study the source code, you will learn a lot of useful PHP coding techniques.

Some include: How to use a rich text editor with a file manager and browser, coding an SEO-friendly web page, file upload and deletion, system user restrictions and more! You can see the detailed list of features on section 6.0 below.

This source code is a very good starting point if you're trying to build your own PHP Web Page Content Management System (CMS) and add some more complex features later.

Pre-Requisite

Before you download, please make sure you have basic understanding of the following topics.

a. PHP, MySQL and OOP CRUD Tutorial – Step by Step Guide!
b. Apache .htaccess RewriteRule Examples

Once you learned our tutorials above, this source code should be easy to understand.

Output Preview

Below are some screenshots of our script's output. You can click an image to view the larger version of it.

Please note that the following images are just output previews. New features might be added already the time you are reading this.

[espro-slider id=5990]

Database Design

Our database name will be "php_web_page_cms", and we will have two tables: Pages and Users.

database-design-php-web-page-content-management-system

File Structure

The following folders and files are included in our source code. It will have more meaning if you will see the code inside the folders and files.
├─ admin/
├─── create_page.php
├─── delete_page.php
├─── index.php
├─── layout_foot.php
├─── layout_head.php
├─── login_checker.php
├─── navigation.php
├─── paging.php
├─── remove_featured_image.php
├─── search_page.php
├─── update_page.php
├─ config/
├─── core.php
├─── database.php
├─ dev/
├─── php_web_page_cms.sql
├─── readme.txt
├─ images/
├─ libs/
├─── css/
├────── bootstrap/
├────── font-awesome/
├─── js/
├────── bootstrap-image-gallery/
├────── responsive_filemanager/
├────── tinymce/
├────── bootbox.min.js
├────── custom-script.js
├────── jquery.js
├─── php/
├────── pw-hashing/
├────── utils.php
├─ objects/
├─── page.php
├─── user.php
├─ .htaccess
├─ index.php
├─ info.php
├─ layout_foot.php
├─ layout_head.php
├─ login.php
├─ logout.php
├─ navigation.php
├─ page.php

Features List & Download - PHP Web Page Content Management System

FEATURE PHP WEB PAGE CMS
Learn more techniques when coding with PHP, MySQL and OOP YES
Save your precious time coding and searching about how to do the features below. YES
PHP PDO and Prepared Statements YES
jQuery enabled YES
Bootstrap enabled YES
Font-awesome enabled YES
TinyMCE enabled YES
Buttons are displayed with appropriate icons YES
USER
Login using email and password YES
Log out user YES
Hashed password stored in database YES
Logged-in user name display on the right side of navigation bar YES
Log-out button displayed on drop-down when user name was clicked YES
Page can be edited and deleted by the user who created it YES
When user tries to edit a page he did not created, he will be redirected to home page YES
'View Page' nagivation bar will show 'Admin' if user is logged in, else it will be a link to login page YES
CREATE A PAGE
Title field YES
Title is shown as page title when shared on Facebook YES
Slug field YES
Slug must be unique (validated when form was submitted) YES
Slug is formatted automatically via JavaScript when form not yet was submitted YES
Slug is formatted automatically via PHP when form was submitted YES
Fill out slug field automatically while you type YES
Fill out slug field automatically when title field loses focus YES
Body field YES
Rich text editor using TinyMCE (like WordPress) YES
Upload and browse files using a file manager YES
Format your content with links, texts, images and more. YES
Meta Description field YES
Meta Description is shown as page description when shared on Facebook YES
Featured Image field YES
Featured Image is shown as page image when shared on Facebook YES
Featured Image allowed file types: JPG, PNG, GIF YES
Featured Image must be less than 1MB in size YES
Save Featured Image file in server directory YES
Status field YES
Page 'Status' can be 'Draft' or 'Published' YES
Button link to read pages YES
Only a logged in user can create a page, else he will be redirected to login page YES
READ PAGES
Display list of pages YES
Featured Image column YES
Title column YES
Status column YES
Author column YES
Created column YES
Actions column YES
Featured images can be clicked and shown in a lightbox YES
View page button to view page content YES
Edit button to update page content YES
Delete button to delete page content YES
Clicking 'Delete' button will show confirmation pop up YES
Edit and Delete button will appear only if the logged-in user created that page YES
Pagination for list of pages YES
UPDATE A PAGE
Read Pages button to go back to list of pages YES
Fields has almost the same features as the 'Create Page' section above, but the following are some differeces YES
View Page button to view page content YES
Fill out form fields with data from database (based on given page ID) YES
Show uploaded featured image (if any) under Featured Image field YES
'Remove Featured Image' button under Featured Image YES
Clicking 'Remove Featured Image' button will show confirmation pop up YES
Featured image can be clicked and shown in a lightbox YES
Highlight Bootstrap radio button based on selected 'Status' YES
'Slug' field is not fill out automatically when 'Title' field was changed. This is because it is not recommended to change a page URL. YES
DELETE A PAGE
Clicking 'Delete' button will show confirmation pop up YES
If user clicked 'No', pop up will disappear and nothing will be deleted YES
If user clicked 'Yes', it will post page ID to delete_page.php so it can be deleted YES
SEARCH PAGES
User can enter search term in search box, then press enter to search YES
System will search page title, slug, body and meta description for the search term YES
Display list of pages with the search term YES
Pagination in search results YES
VIEW PAGE
Show page title YES
Show featured image YES
Clicking featured image will show it in a lightbox YES
Show page content / body YES
All images in the body can be clicked and shown in a lightbox YES
Show author and date created YES
Show share buttons with icons YES
Users can share the page to Facebook, Twitter or Google+ YES
'Edit This Page' button will appear under 'Title' if user is logged in YES
SEO-friendly URL. Page URL does not have parameter like page ID. Page content is retrieved by slug. YES
Used Apache .htaccess file to make SEO-friendly URL work YES
Select 'Published' pages in navigation drop-down YES
SUPPORT AND UPDATES
Free support for 6 months. YES
Free source code updates. YES

Simple Set Up

If you download this (PHP Web Page Content Management System) source code, here are the few instructions how to run this source code:

1. Copy the extracted files to your localhost or upload it to your webserver.

2. You have to create your database using PhpMyAdmin, name of the database: php_web_page_cms

3. Import the SQL file called "php_web_page_cms.sql" located in the "dev" folder.

4. Change line 7 .htaccess file (No changes should be made if you put the files on the root directory of your localhost)
RewriteBase /YOUR_ROOT_DIRECTORY/

5. Run the login.php file on your browser, use the following user credentials.

User #1
Username: [email protected]
Password: [email protected]

User #2
Username: [email protected]
Password: [email protected]

To make TinyMCE file manager / file browser work: (No changes should be made if you put the files on the root directory of your localhost)

Change line 71 of /libs/js/responsive_filemanager/filemanager/config/config.php

'upload_dir' => '/YOUR_ROOT_DIRECTORY/libs/js/responsive_filemanager/source/',


Change line 78-79 of /admin/layout_foot.php

external_filemanager_path:"/YOUR_ROOT_DIRECTORY/libs/js/responsive_filemanager/filemanager/",
external_plugins: { "filemanager" : "/YOUR_ROOT_DIRECTORY/libs/js/responsive_filemanager/filemanager/plugin.min.js"},

Thank You!

Thank you for reading about this PHP Web Page Content Management System source code and supporting our projects here at codeofaninja.com!

If you have any questions, comments or suggestions, please do not hesitate to contact me.
a. Send me an email. My email address is [email protected]
b. Go to https://fb.com/codeofaninja and chat me up.

PHP Product Catalog Module

php-product-catalog-script

Note

Before You Download, make sure you have basic understanding of these topics:

a. PHP Object Oriented CRUD Example with Bootstrap

b. Apache .htaccess RewriteRule Examples with PHP

Features List

FEATURE ACCESS LEVEL Source Code
USER MANAGEMENT
User type: Admin Admin Yes
Interface for admin Admin Yes
Login page Admin Yes
Log out Admin Yes
PRODUCT MANAGEMENT
Create product Admin Yes
Read products Admin Yes
Update product Admin Yes
Delete product Admin Yes
Search product Admin & Customer Yes
Product lists with pagination Admin & Customer Yes
View inactive products Admin Yes
View products under a category Admin & Customer Yes
Product list under a category with pagination Admin & Customer Yes
Upload product images, you can select many images at once Admin Yes
View product images with thumbnails Admin & Customer Yes
Delete product image with X icon Admin Yes
Upload product PDFs , you can select many PDF files at once Admin Yes
List product PDF Admin Yes
Delete product PDF Admin Yes
View single product with related information Customer Yes
View single product with add to cart button Customer Yes
View single product with image slider Customer Yes
View single product with SEO friendly URL (.htaccess file used) Customer Yes
Rich text editor for product description when adding or editing product Admin Yes
Quantity value must be more than 1 Customer Yes
Sorting by fields Admin Yes
CATEGORY MANAGEMENT
Create category Admin Yes
Read categories Admin Yes
Update category Admin Yes
Delete category Admin Yes
Search category Admin Yes
Category list with pagination Admin Yes
Category search result with pagination Admin Yes
View products under a product category Admin & Customer Yes
Auto update category drop down in create or update product form Admin Yes
Auto update categories in navigation bar Admin & Customer Yes
Highlight selected category in navigation Admin & Customer Yes
SECURITY
Login user with hashed password validation Customer & Admin Yes
Used PDO bindParam() to prevent SQL injection in all MySQL queries Developer Yes
Used PHP htmlspecialchars() and strip_tags() to prevent XSS attacks Developer Yes
MORE REASONS TO DOWNLOAD IT
Object oriented programming source code Developer Yes
Bootstrap user interface Developer Yes
PDO extension used Developer Yes
Page title navigation with links Developer Yes
Radio button looks like a switch Developer Yes
Icon in all create, edit and delete buttons Developer Yes
All source code files organized by folders Developer Yes
Database configuration file in config folder Developer Yes
SQL file and READ-ME.txt in “sql” folder Developer Yes
SQL file and READ-ME.txt in "dev" folder Developer Yes
Database design and data dictionary in "dev" folder Developer Yes
Free source code updates / new features update Developer Yes
Free support for 6 months Developer Yes
Buy once, use for unlimited number of sites Developer Yes
One-time payment, no recurring payment Developer Yes

Simple Configuration

Source code simple configuration when you install:

1. This system works with PHP 5.4+

2. In your PhpMyAdmin, create a database "php_product_catalog"

3. Import the SQL file php_product_catalog.sql in the "dev" folder

4. Rewrite module must be enable in your apache server

5. Change rewrite base directory in line 7 of .htaccess file

6. Configure $home_url in /config/core.php

7. Configure database in /config/database.php

8. User Login
Admin Section Login
Username: [email protected]
Password: [email protected]

Thanks For Your Help!

Contact me if you have any questions about the code, I'll be more than happy to help and support you!

My email is [email protected], you can also contact me via our official Facebook page.

Thank you visiting our for PHP Product Catalog Script page!

PHP Shopping Cart Module

php-online-shopping-cart-source-code

Output Preview

The following slideshow is the output preview of this source code.

Customer Section Output Preview:
[espro-slider id=6839]

Admin Section Output Preview:
[espro-slider id=6864]

Note: The "PHP Shopping Cart Module" is also called the "LEVEL 3 source code" of our PHP Shopping Cart Tutorials - PHP SESSIONS, PHP COOKIES and MySQL.

Pre-Requisites

Before you download, make sure you have basic understanding of these topics:

a. PHP Object Oriented CRUD Example with Bootstrap
b. Apache .htaccess RewriteRule Examples with PHP

Cart Data Storage

This source code takes advantage of PHP SESSIONS, PHP COOKIES and MySQL when storing cart data.

  • We use PHP COOKIES to save site visitor's user_id locally.
  • We use PHP SESSIONS as back up just in case cookies are disabled in user's browser.
  • We use MySQL to store cart items in the database.
  • This way, cart items can be resurrected even if user closed his browser, logged out or logged in another computer.

Here's the logic:

IF cookies are enabled, AND if user is logged in, we save 'session user_id' to 'user_id variable'. The value of 'user_id variable' is very important because we use it to save 'user_id' both in PHP 'cookie' and 'session'.

IF cookies are enabled, AND if user is not logged in, AND if user already have a 'cookie user_id' token, we save 'cookie user_id' to 'user_id variable'.

IF cookies are enabled, AND if user is not logged in, AND if 'cookie user_id' is not set (it means, visitor never used the cart before), we get new token as 'user_id variable' value.

IF cookies are enabled, AND user is logged in OR not logged in, we set 'cookie user_id' and 'session user_id' with the final 'user_id variable' value. This will retrieve the cart data with the same 'user_id' from MySQL database.

IF cookies are disabled, AND user is logged in, we maintain 'session user_id'.

IF cookies are disabled, AND user is not logged in, we get new token and save it to 'session user_id'.

Important Note: The statements above can be understood more clearly if you will see the code implementation on /config/core.php line 26 onwards.

What People Say?

Here's what people feel about our work and source code downloads.

Features List & Download

FEATURE ACCESS LEVEL SOURCE CODE
USER MANAGEMENT
Create user Admin YES
Read users Admin YES
Update user Admin YES
Delete user Admin YES
Search user Admin YES
Users list pagination Admin YES
Valid email format required Admin & Customer YES
Password must be uppercase letter, lowercase letter, number and special character Admin & Customer YES
Confirm password field Admin YES
Password validation as you type Admin YES
View customer order history Admin & Customer YES
Deleting first administrator account is not allowed Admin YES
User types: Admin and Customer Admin & Customer YES
Interface for admin Admin YES
Interface for customer Customer YES
Login page Admin & Customer YES
Log out Admin & Customer YES
Edit profile of currently logged in user Admin YES
Show name with icon of currently logged in user Admin & Customer YES
PRODUCT MANAGEMENT
Create product Admin YES
Read products Admin YES
Update product Admin YES
Delete product Admin YES
Search product Admin & Customer YES
Product lists with pagination Admin & Customer YES
View inactive products Admin YES
View products under a category Admin & Customer YES
Product list under a category with pagination Admin & Customer YES
Upload product images, you can select many images at once Admin YES
View product images with thumbnails Admin & Customer YES
Delete product image with X icon Admin YES
Upload product PDFs , you can select many PDF files at once Admin YES
List product PDF Admin YES
Delete product PDF Admin YES
View single product with related information Customer YES
View single product with add to cart button Customer YES
View single product with image slider Customer YES
View single product with SEO friendly URL (.htaccess file used) Customer YES
Rich text editor for product description when adding or editing product Admin YES
Quantity value must be more than 1 Customer YES
Sorting by fields Admin YES
View products under a product category Admin & Customer YES
Highlight selected category in navigation Admin & Customer YES
ORDER MANAGEMENT
Make an order Customer YES
Auto-generated unique transaction ID Customer YES
Add to cart button (for each item) with specified quantity Customer YES
Cart page with list of products added to cart Customer YES
Update quantity button for each item in cart page Customer YES
Auto-compute subtotal in cart page Customer YES
Auto-compute grand total in cart page Customer YES
Remove from cart button for each item in the cart Customer YES
Empty cart button to remove all items in the cart Customer YES
View order history of a customer Admin & Customer YES
View pending and completed order in separate tabs Admin YES
Checkout page Customer YES
Show billing information on check-out page Customer YES
Show payment information on checkout page Customer YES
Payment via cash on delivery Customer YES
Place order page - Thank you message Customer YES
View list of orders Customer YES
Pagination on list of orders Admin & Customer YES
Latest order seen at the top of the list Admin & Customer YES
View details of an order Admin & Customer YES
Auto-compute order totals Admin & Customer YES
Change status of an order (pending or completed) Admin YES
SECURITY
Register user hashed password stored in the database Customer YES
Edit user profile hashed password update in the database Admin YES
Create user hashed password stored in the database Admin YES
Login user with hashed password validation Customer & Admin YES
Used PDO bindParam() to prevent SQL injection in all MySQL queries Developer YES
Used PHP htmlspecialchars() & strip_tags() to prevent XSS attacks Developer YES
MORE REASONS TO DOWNLOAD IT
Object oriented programming source code Developer YES
Bootstrap user interface Developer YES
PDO extension used Developer YES
Page title navigation with links Developer YES
Radio button looks like a switch Developer YES
Icon in all create, edit and delete buttons Developer YES
All source code files organized by folders Developer YES
Database configuration file in config folder Developer YES
SQL file and READ-ME.txt in "dev" folder Developer YES
Database design and data dictionary in "dev" folder Developer YES
Well explained / commented source code Developer YES
Free support for 6 months Developer YES
Free source code updates. Developer YES
Buy once, use for unlimited number of sites Developer YES
One-time payment, no recurring payment Developer YES
$50 - Download source code

Simple Set Up

Source code simple set up when you install:

1. Extract the ZIP file to your server directory.

2. In your PhpMyAdmin, create a database "shop_cart_module"

3. Import the "shop_cart_module.sql" SQL file in the "dev" folder

4. Change rewrite base directory in line 7 of .htaccess file (if needed)

5. Change $home_url in /config/core.php (if needed)

6. Configure database in /config/database.php

7. Run product.php - this is the main file, not index.php

8. User Login
Admin Section Login
Username: [email protected]
Password: [email protected]

Customer Account Login
Username: [email protected]
Password: [email protected]

How To Make TinyMCE File Manager / File Browser Work?

1. Change line 71 of /libs/js/responsive_filemanager/filemanager/config/config.php

'upload_dir' => '/YOUR_ROOT_DIRECTORY/libs/js/responsive_filemanager/source/',

2. Change line 42-43 of /admin/layout_foot.php

external_filemanager_path:"/YOUR_ROOT_DIRECTORY/libs/js/responsive_filemanager/filemanager/",
external_plugins: { "filemanager" : "/YOUR_ROOT_DIRECTORY/libs/js/responsive_filemanager/filemanager/plugin.min.js"},

I'll keep you updated via email with the updated information and download link. Download the source code by clicking the green button below. Once your payment was sent, you'll receive the download link in your email.

Need More Features?

If you think you now need more features, you can download our PHP Shopping Cart System instead. It has more features like web page content management, contact form, and more.

Get In Touch

Contact me if you have any questions about the code, I'll be more than happy to help and support you!

My email is [email protected], you can also contact me via our official Facebook page.

Please subscribe as well to receive news and updates about our source codes and free tutorials. Fill out the form below.

Enjoy high-quality web programming tutorials.
Subscribe to CodeOfaNinja now for FREE!

Thank you for visiting our PHP Online Shopping Cart Source code download page!

PHP Login & Registration Module

php-login-system

This source code is about PHP Login System. It will help you understand how to login and logout functionality works. Sign up email verification, user registration, and forgot password features are included as well.

The basic idea is, we will have two user access levels: the 'Admin' and 'Customer'.

If the 'Customer' is logged in, he can access pages assigned for him to be accessed, like the edit profile and index page for 'Customer'.

If the 'Admin' is logged in, he can create, read list, update, delete and search users. See the full list of features in the table below.

Where's the tutorial? We call this a tutorial because if your download the source code, you can ask me anything related to it. I can personally teach you the code and other tips you need.

That's how we go about it for now. Formal tutorial or documentation of this code is coming soon. I'm currently working on it. Thanks for understanding!

PHP Login System Features

You can see the features and download it below.

Feature Login System
Login form with email and password YES
PHP Sessions are used to identify logged in and logged out users. YES
Hashed password stored in database YES
Register form YES
Password and confirm password fields YES
Check if password matches YES
Sending of verification link to email YES
Validation page of email link YES
Check if password is strong enough YES
Email sending works with remote host only. YES
Redirection to login page if not yet logged in YES
Forgot password page YES
Password reset link sent to email YES
Password reset page YES
Customer access to index page when logged in YES
Customer access to edit profile page when logged in YES
Customer change password page YES
Customer password and confirm password field when editing profile YES
Customer logout YES
Admin create user YES
Admin read users YES
Admin update user YES
Admin delete user YES
Admin change of user access level: Admin or Customer YES
Admin search user by email address YES
Admin users list paging YES
Admin edit profile YES
Admin logout YES
Admin change password page YES
Admin can change user passwords YES
Admin can manually change status of users (pending or approved) YES
Require login in admin index page, edit profile page and users CRUD pages. YES
Bootstrap enabled user interface YES
Free support for 6 months. YES
Free source code updates. YES
$50- Download source code

Some Notes

Found An Issue?

If you found a problem with this code, please write a comment below. Please be descriptive about your issue. Please provide the error messages, screenshots (or screencast) and your test URL. Thanks!

Before you write a comment, remember to read this guide and our code of conduct.

Subscribe to CodeOfaNinja

We constantly improve CodeOfaNinja. We update our tutorials and source codes. Receive valuable web programming tutorials and updates to your email. Subscribe now!

Enjoy high-quality web programming tutorials.
Subscribe to CodeOfaNinja now for FREE!

Thank You!

Thanks for reading our PHP Login System Tutorial with Admin Features.

PHP PayPal Integration Module

paypal-integration-in-php

This code will solve your problem and answer your question: how to add PayPal and credit card on checkout?

You can use this code on your PHP shopping cart script. This is an add-on to our shopping cart scripts like this as well.

PayPal Integration In PHP - Output Preview

You can watch the demo video below to see how the source code works.

Demo is in sandbox (testing) mode, so please use your PayPal sandbox account. You can create a PayPal sandbox account using this PayPal developer link.

How To Set Up / Enable Auto Return?

With Auto Return for PayPal Website Payments, your buyers are redirected back to your site immediately after clicking the Pay button on the Payment Confirmation page. Best choce of web design company for you is royal palm beach web design.

Your buyers enjoy a streamlined checkout experience and are returned back to your site quickly!

Enable Auto Return In Your Test / Sandbox Account.

  1. Log into https://developer.paypal.com
  2. Click Applications
  3. Click Sandbox accounts
  4. Expand the account in question
  5. Click Sandbox site
  6. Login to the test account
  7. Copy and paste "https://www.sandbox.paypal.com/us/cgi-bin/webscr?cmd=_profile-website-payments" into your browser
  8. Enable Auto Return and click Save
  9. Enter the Auto Return URL and click Save
  10. If ever you want to do simple marketing strategy locally, go to signmann.com

[Reference]

Setting Up Auto Return On Your Official / Real PayPal Account

  1. Log in and click the Profile subtab under My Account.
  2. Click the Website Payment Preferences link under Selling Preferences.
  3. Click the On radio button to enable Auto Return.
  4. Enter the Return URL. Note: You must meet the Return URL requirements in order to set up Auto Return. Learn more about Return URL.

[Reference]

Download Source Code

It is more convenient if you can just download the complete source code we used and play around with it. There's a small fee in getting the complete source code, it is small compared to the:

✔ Value or skill upgrade it can bring you, orYES
✔ Income you can get from your website project or business.YES
✔ Precious time you save.YES
✔ Expert advice you can get from us, just in case you have any questions related to the source code.YES

For a limited time, I will give you the source code for a low price. DOWNLOAD THE SOURCE CODE you desire by clicking its the BUY button below.

You can see the features list and download it below.

Feature Add On
Pay with PayPal YES
Pay with credit card (via PayPal) YES
Pay with debit card (via PayPal) YES
Set merchant email address / PayPal ID YES
Set currency and currency symbol YES
Set return URL (your site URL when user was done with the payment) YES
Set cancel URL (your site URL when user cancels order) YES
Support automatic redirect to your site YES
Free support for 6 months YES
Free source code updates. YES

THANK YOU!

Thanks for viewing our source code about PayPal Integration In PHP!

If you have any questions, comments or suggestions, please do not hesitate to contact me.
a. Send me an email. My email address is [email protected]
b. Go to https://fb.com/codeofaninja and chat me up.

PHP SHOPPING CART SYSTEM – Source Code – Download Now!

php-shopping-cart-source-code-download
Are you trying to learn how to build your own PHP shopping cart system? Do you need quick guidance and support while doing it? You're in the right place.

Google defines the word "system" as a set of connected parts forming a complex whole. We say this "PHP shopping cart source code" is a "system" because of that definition.dat

Each module of this source code is designed to be very simple and easy to understand. It is based on our step-by-step CRUD tutorials, like this one.

You will be able to build a complex web application before you know it. You'll never get lost. It is your advantage. You can use the same knowledge to build another type of web application.

We are here to help you in anything you do not understand in this source code.

Download and learn how this PHP Shopping Cart System was made. Technologies used include PHP, MySQL, jQuery, AJAX, Bootstrap, HTML5, Object-oriented programming and more.

This project is not perfect. It is designed to be simple. This is a very good starting point for your development.

DOWNLOAD NOW

If you've been here before, you read the details about this product and you already know its value. You can download by choosing the right package and clicking the download button below.

Source Code Overview

This source code will enable you to make your own PHP shopping cart system. This source code is a very good starting point if you're trying to build your own 'PHP Shopping Cart Source Code' from scratch and add some more complex features later.

This is because the basis of this source code is our step-by-step and easy-to-understand tutorial. Specifically this tutorial: PHP, MySQL, and OOP CRUD Tutorial – Step by Step Guide!

The system looks simple. But I assure you that when you study the source code, you will learn a lot of useful PHP coding techniques.

Some include Ordering and inventory features, PayPal integration, web page content management, product management, variation, collecting, and storing customer messages on your own database, admin restrictions, and more! You can see the detailed list of features in section 9.0 below.

Output Preview

Below are some screenshots of our script’s output. You can click an image to view the larger version of it. Use the left and right arrows to navigate through the screenshots.

Please note that the following images are just output previews. New features might be added already the time you are reading this.

Index page
Login page
Admin page and menus
User page and menus

Is This Code For Me?

The source code in this page is NOT for you if:

  • You are already an expert in PHP & MySQL programming.
  • You have a lot of time to code the listed features of our PHP shopping cart source code
  • You are not that interested in learning PHP & MySQL programming.

But, this SOURCE CODE is FOR YOU if:

  • You want to SAVE a significant amount of development time.
  • You want to develop your own PHP Shopping Cart Source Code from scratch.
  • You determined to learn how to make a this web application feature in PHP & MySQL.
  • You need some guidance in learning about this script (I'll personally support you & answer your questions)

But if you are an expert in PHP & MySQL programming and would like to take a look at our code, please do so! We’d love to hear your response and great insights! The comments section below is always open for anyone with questions and suggestions.

Pre-Requisites

Before you download, make sure you have a basic understanding of these topics:

a. PHP, MySQL & OOP CRUD Tutorial - Step By Step Guide!
b. Apache .htaccess RewriteRule Examples with PHP
c. PHP, MySQL & AJAX CRUD Tutorial - Step By Step Guide!

Cart Data Storage

This source code takes advantage of PHP SESSIONS, PHP COOKIES, and MySQL when storing cart data.

  • We use PHP COOKIES to save the site visitor's user_id locally.
  • We use PHP SESSIONS as back up just in case cookies are disabled in the user's browser.
  • We use MySQL to store cart items in the database.
  • This way, cart items can be resurrected even if the user closed his browser, logged out or logged in another computer.

Here's the logic:

IF cookies are enabled, AND if user is logged in, we save 'session user_id' to 'user_id variable'. The value of 'user_id variable' is very important because we use it to save 'user_id' both in PHP 'cookie' and 'session'.

IF cookies are enabled, AND if user is not logged in, AND if user already have a 'cookie user_id' token, we save 'cookie user_id' to 'user_id variable'.

IF cookies are enabled, AND if user is not logged in, AND if 'cookie user_id' is not set (it means, visitor never used the cart before), we get new token as 'user_id variable' value.

IF cookies are enabled, AND user is logged in OR not logged in, we set 'cookie user_id' and 'session user_id' with the final 'user_id variable' value. This will retrieve the cart data with the same 'user_id' from MySQL database.

IF cookies are disabled, AND user is logged in, we maintain 'session user_id'.

IF cookies are disabled, AND user is not logged in, we get new token and save it to 'session user_id'.

Important Note: The statements above can be understood more clearly if you will see the code implementation on /config/core.php line 26 onwards.

Database Design

Our database name will be "shop_cart_complete", and we will have twelve (12) tables.
database-design-php-shopping-cart-source-code

File Structure

The following folders and files are included in the source code. It will have more meaning if you will see the code inside the folders and files.
├─ admin/
├─── category.php
├─── change_order_status.php
├─── change_password.php
├─── create_category.php
├─── create_page.php
├─── create_product.php
├─── create_user.php
├─── create_variation.php
├─── delete_category.php
├─── delete_image.php
├─── delete_message.php
├─── delete_page.php
├─── delete_pdf.php
├─── delete_product.php
├─── delete_user.php
├─── delete_variation.php
├─── layout_foot.php
├─── layout_head.php
├─── login_checker.php
├─── navigation.php
├─── order_history.php
├─── paging.php
├─── read_categories_template.php
├─── read_categories.php
├─── read_inactive_products.php
├─── read_message.php
├─── read_messages_template.php
├─── read_messages.php
├─── read_one_order.php
├─── read_orders_template.php
├─── read_orders.php
├─── read_pages_template.php
├─── read_products_sorted_by_fields.php
├─── read_products_template.php
├─── read_products.php
├─── read_users_template.php
├─── read_users.php
├─── search_categories.php
├─── search_messages.php
├─── search_orders.php
├─── search_pages.php
├─── search_products.php
├─── search_users.php
├─── settings.php
├─── update_category.php
├─── update_page.php
├─── update_product.php
├─── update_user.php
├─── update_variation.php
├─── variations.php
├─ config/
├─── core.php
├─── database.php
├─ dev/
├─── shop_cart_complete.sql
├─── readme.txt
├─ images/
├─ libs/
├─── css/
├────── bootstrap/
├────── font-awesome/
├────── admin.css
├────── user.css
├─── js/
├────── bootstrap-image-gallery/
├────── jquery-ui/
├────── responsive-filemanager/
├────── tinymce/
├────── bootbox.min.js
├────── custom-script.js
├────── jquery.js
├─── php/
├────── php-mailer/
├────── pw-hashing/
├────── paypal_checkout.php
├────── utils.php
├─ objects/
├─── cart_item.php
├─── category.php
├─── message.php
├─── order_item.php
├─── order.php
├─── page.php
├─── product_image.php
├─── product_pdf.php
├─── product.php
├─── setting.php
├─── user.php
├─── variation.php
├─ uploads/
├─── images/
├─── pdfs/
├─ .htaccess
├─ add_to_cart.php
├─ cart.php
├─ category.php
├─ change_password.php
├─ checkout.php
├─ contact.php
├─ delete_cookie.php
├─ edit_profile.php
├─ add_to_cart.php
├─ cart.php
├─ category.php
├─ change_password.php
├─ checkout.php
├─ contact.php
├─ delete_cookie.php
├─ edit_profile.php
├─ empty_cart.php
├─ forgot_password.php
├─ info.php
├─ layout_foot.php
├─ layout_head.php
├─ load_variation.php
├─ login_checker.php
├─ login.php
├─ logout.php
├─ navigation.php
├─ orders.php
├─ page.php
├─ paging.php
├─ place_order.php
├─ product.php
├─ products.php
├─ read_one_order.php
├─ read_products_sorted_by_fields.php
├─ read_products_template.php
├─ register.php
├─ remove_from_cart.php
├─ reset_password.php
├─ search.php
├─ update_quantity.php
├─ navigation.php
├─ verify.php

What People Say

Here are some of the things people say about our source code downloads.

Features List & Download

FEATURE ACCESS LEVEL SOURCE CODE
USER MANAGEMENT
Create user Admin YES
Read users Admin YES
Update user Admin YES
Delete user Admin YES
Search user Admin YES
Users list pagination Admin YES
Valid email format required Admin & Customer YES
Password must be uppercase letter, lowercase letter, number and special character Admin & Customer YES
Confirm password field Admin & Customer YES
Password validation as you type Admin & Customer YES
View customer order history Admin & Customer YES
Deleting first administrator account is not allowed Admin YES
User types: Admin and Customer Admin & Customer YES
Interface for admin Admin YES
Interface for customer Customer YES
Login page Admin & Customer YES
Log out Admin & Customer YES
Sign up page Customer YES
Sign up email notification with validation link Customer YES
Edit profile of currently logged in user Admin & Customer YES
Show name with icon of currently logged in user Admin & Customer YES
Forgot password - system can send unique reset password link via email Customer YES
Forgot password - user can click the unique verification link and reset his password Customer YES
PRODUCT MANAGEMENT
Create product Admin YES
Read products Admin YES
Update product Admin YES
Delete product Admin YES
Search product Admin & Customer YES
Product lists with pagination Admin & Customer YES
View inactive products Admin YES
View products under a category Admin & Customer YES
Product list under a category with pagination Admin & Customer YES
Upload product images, you can select many images at once Admin YES
View product images with thumbnails Admin & Customer YES
Delete product image with X icon Admin YES
Upload product PDFs , you can select many PDF files at once Admin YES
List product PDF Admin YES
Delete product PDF Admin YES
View single product with related information Customer YES
View single product with add to cart button Customer YES
View single product with image slider Customer YES
View single product with SEO friendly URL (.htaccess file used) Customer YES
Rich text editor for product description when adding or editing product Admin YES
Quantity value must be more than 1 Customer YES
Sorting by fields Admin & Customer YES
VARIATION MANAGEMENT
Set variation name Admin YES
Set variation price Admin YES
Set variation stock Admin YES
Stock / inventory decreases when order has been placed Admin YES
Increase stock / inventory by updating the variation Admin YES
Create variation Admin YES
Read list of variation Admin YES
Update variation Admin YES
Delete variation Admin YES
CATEGORY MANAGEMENT
Create category Admin YES
Read categories Admin YES
Update category Admin YES
Delete category Admin YES
Search category Admin YES
Category list with pagination Admin YES
Category search result with pagination Admin YES
View products under a product category Admin & Customer YES
Auto update category drop down in create or update product form Admin Yes
Auto update categories in navigation bar Admin & Customer YES
Highlight selected category in navigation Admin & Customer YES
ORDER MANAGEMENT
Make an order Customer YES
Auto-generated unique transaction ID Customer YES
Add to cart button (for each item) with specified quantity Customer YES
Cart page with list of products added to cart Customer YES
Update quantity button for each item in cart page Customer Yes
Auto-compute subtotal in cart page Customer YES
Auto-compute grand total in cart page Customer YES
Remove from cart button for each item in the cart Customer YES
Empty cart button to remove all items in the cart Customer YES
View order history of a customer Admin & Customer YES
View pending and completed order in separate tabs Admin YES
Checkout page Customer YES
Show billing information on check-out page Customer YES
Edit billing information button on checkout page Customer YES
Show payment information on checkout page Customer YES
Payment via cash on delivery Customer YES
Payment via PayPal Customer YES
Place order page - Thank you message Customer YES
View list of orders Customer YES
Pagination on list of orders Admin & Customer YES
Latest order seen at the top of the list Admin & Customer YES
View details of an order Admin & Customer YES
Auto-compute order totals Admin & Customer YES
Change status of an order (pending or completed) Admin YES
SECURITY
Register user hashed password stored in the database Customer YES
Edit user profile hashed password update in the database Admin YES
Create user hashed password stored in the database Admin YES
Login user with hashed password validation Customer & Admin YES
Used PDO bindParam() to prevent SQL injection in all MySQL queries Developer YES
Used PHP htmlspecialchars() to prevent XSS attacks Developer YES
WEB PAGE MANAGEMENT
Create page Admin YES
Read page Admin YES
Update page Admin YES
Delete page Admin YES
Search page Admin YES
Pages list with pagination Admin YES
Pages search result with pagination Admin YES
CONTACT MANAGEMENT
Send message to Admin Customer YES
Display other ways to contact Admin Customer YES
Display list of messages Admin YES
Messages list with pagination Admin YES
Read message Admin YES
Delete message Admin YES
Search message Admin YES
Messages search result with pagination Admin YES
MORE REASONS TO DOWNLOAD IT
Object oriented programming source code Developer YES
Bootstrap user interface Developer YES
PDO extension used Developer YES
Page title navigation with links Developer YES
Radio button looks like a switch Developer YES
Icon in all create, edit and delete buttons Developer YES
All source code files organized by folders Developer YES
Database configuration file in config folder Developer YES
SQL file and READ-ME.txt that contains login credentials in "sql" folder Developer YES
Well explained / commented source code Developer YES
One-time payment, no recurring payment Developer YES
SUPPORT AND UPDATES
Free support for 1 year. Developer YES
Free source code updates. Developer YES
$250 - Download source code

Simple Set Up

You can run this source code successfully with few easy steps.

10.1 Run the Home Page

I assume you are installing this source code on localhost. In my case, I installed this code in this directory:

The reason for these multiple folders is because I have many projects and I need to organize them this way. I can access the system in this URL: http://localhost/CodeOfaNinja/SourceCodes/Systems/ShoppingCartSystem/

You will see an error, that's why we need to do the following steps.

1. In your PhpMyAdmin, create a database with the name "shopping_cart_system".

2. Import the "shopping_cart_system.sql" SQL file from the "dev" folder.

3. Change rewrite base directory in line 7 of the .htaccess file.

RewriteBase RewriteBase /CodeOfaNinja/SourceCodes/Systems/ShoppingCartSystem/

4. Configure $home_url in line 72 of /config/core.php

$home_url = "http://localhost/CodeOfaNinja/SourceCodes/Systems/ShoppingCartSystem/";

5. Configure database in /config/database.php, example settings would look like:

// specify your own database credentials
private $host = "localhost";
private $db_name = "shopping_cart_system";
private $username = "root";
private $password = "";
public $conn;

6. Try to log in by running the login page.

http://localhost/CodeOfaNinja/SourceCodes/Systems/ShoppingCartSystem/login

Use the following login credentials.

Admin Section Login
Username: [email protected]
Password: [email protected]

Customer Account Login
Username: [email protected]
Password: [email protected]

How To Set Up / Enable Auto Return?

With Auto Return for PayPal Website Payments, your buyers are redirected back to your site immediately after clicking the Pay button on the Payment Confirmation page.

Your buyers enjoy a streamlined checkout experience and are returned back to your site quickly!

1. Enable Auto Return In Your Test / Sandbox Account.

  1. Log into https://developer.paypal.com
  2. Click Applications
  3. Click Sandbox accounts
  4. Expand the account in question
  5. Click Sandbox site
  6. Login to the test account
  7. Copy and paste "https://www.sandbox.paypal.com/us/cgi-bin/webscr?cmd=_profile-website-payments" into your browser
  8. Enable Auto Return and click Save
  9. Enter the Auto Return URL and click Save

[Reference]

2. Setting Up Auto Return On Your Official / Real PayPal Account

  1. Log in and click the Profile subtab under My Account.
  2. Click the Website Payment Preferences link under Selling Preferences.
  3. Click the On radio button to enable Auto Return.
  4. Enter the Return URL. Note: You must meet the Return URL requirements in order to set up Auto Return. Learn more about Return URL.

[Reference]

3. How To Disable Sandbox Mode?

This source code is in sandbox mode by default, it means any PayPal transactions are for testing purposes only. To disable the PayPal Sandbox mode:

Open /libs/php/paypal_checkout.php

Change line 51, from

$form='<form id="paypal_checkout" action="https://www.sandbox.paypal.com/cgi-bin/webscr" method="post">';

to

$form='<form id="paypal_checkout" action="https://www.paypal.com/cgi-bin/webscr" method="post">';

Change the email address (line 5) to your real PayPal account email address. Payment will be sent to the specified PayPal account.

How To Make TinyMCE File Manager / File Browser Work?

1. Change line 71 of /libs/js/responsive_filemanager/filemanager/config/config.php

'upload_dir' => '/YOUR_ROOT_DIRECTORY/libs/js/responsive_filemanager/source/',

2. Change line 42-43 of /admin/layout_foot.php

external_filemanager_path:"/YOUR_ROOT_DIRECTORY/libs/js/responsive_filemanager/filemanager/",
external_plugins: { "filemanager" : "/YOUR_ROOT_DIRECTORY/libs/js/responsive_filemanager/filemanager/plugin.min.js"},

Some More Notes

1. This system works with PHP 5.5+

2. Rewrite module must be enable in your apache server (this is enabled by default in most web servers and localhost)

Thanks For Your Help!

YES! The shopping cart system source code is now available! Thanks for all the pre-orders and support! More features and enhancements will be added in the future.

I'll keep you updated via email with the update information and download link. Download the source code by clicking the green BUY button below.

$250 - Download source code

Related Source Codes

Get In Touch

Contact me if you have any questions about the code, I'll be more than happy to help and support you!

My email is [email protected].

Please subscribe as well to receive news and updates about our source codes and free tutorials. Fill out the form below. CLICK HERE TO SUBSCRIBE!

Thank you for visiting our PHP shopping cart source code download page!