Skip to content

CakePHP powered application using AJAX that allows users to login using OpenID, add items to sell, and buy items using PayPal.

Notifications You must be signed in to change notification settings

henkir/BuyAndSellOnline

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

35 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

BuyAndSellOnline
Authors: Robin Axelsson & Henrik Holmberg

# Description
BuyAndSellOnline is a web 2.0 site using AJAX to provide a rich user experience. Users can login and add items they want to sell, or they can purchase items other users have added. They can search, filter and order the items that are for sale. The JavaScript frameworks Prototype and Scriptaculous are used on the client side as well as the CSS framework Blueprint CSS. On the server side the CakePHP framework is used. PHP is obviously the server side language, and MySQL is used for the database.
User login is handled with the OpenID API providing good security, and payments are handled with the PayPal API.

# Installation
To get the website going, put the entire directory structure inside a directory that is accessible by the web server (probably www, www-pub or something like that). If you do not put it in the web root, but in a sub directory, you need to change the lines specifying the CSS files in BuyAndSellOnline/app/views/layouts/default.ctp to the appropriate paths. Then create a MySQL database and a user for the website to use. You can use these commands:

    cd to the BuyAndSellOnline/database directory.
    Enter: mysql -u root -p
    Then enter your password.
    Then enter "source init_db.sql".
    To create the MySQL user for CakePHP, enter "create_user.sql" without the quotes.

You need to make sure that the files have the correct permissions. To be sure it will work:
    Go to the BuyAndSellOnline directory.
    Type sudo chmod -R 777 app/

Then open BuyAndSellOnline/app/app_controller.php and locate this line in beforeFilter():
Configure::write('debug', 2);
Change it to:
Configure::write('debug', 0);
Then use your browser and go to the url http://example.com/BuyAndSellOnline/users/initDB if your server has the domain name example.com and you placed the entire directory in the webroot. This initializes the groups and builds the Acl.
Then change the line in app_controller.php back if you don't want debugging enabled.

In BuyAndSellOnline/app/app_controller.php there's a function _configure where you can configure how many items to show at once etc. You also set your IP address or domain name there. It's required for the OpenID authentication.

This will give the web server access to all the files it may need.

About

CakePHP powered application using AJAX that allows users to login using OpenID, add items to sell, and buy items using PayPal.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published