Post Installation ...
This section describes what to do after you have installed the application on your web server. At this point the application should be working so that you can log on to the admin section and click through the displays.
The following is not meant to replace the full explanation of each administration display, but provides a quick test to check operation.
Basic set up
Log on to the administration displays of PHPKeyCodes and click on Site setup in the main menu which will take you to the global set up page.
The only required entries are :
- your PayPal email address - this should be the primary email address you have registered with PayPal
- your admin email address - this will be the email 'from' address and so should have the same domain as the site that the application is installed on, or otherwise customers may not receive their emails
- the installation url where phpkeycodes has been installed - for example http://www.yourservername.com/phpkeycodes/
Other entries can be left for now and filled in later.
Note that you do not have to make any changes to you PayPal account to identify the PayPal IPN or anything like that.
Create a product
To be able to test if the system is working, you need to create a new product :
Click on Product list in the main menu which will allow you to create a new product item.
Click on the Create button and fill in the required fields.
At this stage enter any test data into the fields.
In the key codes field, enter a series of pin codes. Enter say 10 lines.
Click on Save when finished.
The file name will be similar to : /home/user/files/test.doc when on a Unix system or something like c:\data\www\files\test.doc for a Windows ssytem.
Do not try to use a http: url web address as that will not work.
When you create your files, it is recommended that you use lower case letters for the filename and you do not use spaces within the filenames.
- lower case letters only (Unix type servers are case sensitive so using a mixture of lower / upper case letters can cause confusion)
- no spaces in filenames (Some browsers may not correctly recognize the file types if spaces are used)
- Only use letters and numbers for file names not quote marks etc
- Make sure that the filename has the correct extension for the file type, for example .mp3 or .pdf.
Perform a local test
Click on Testing in the main menu. This will display a list of products that you have created. To test a particular product, click on Select Local Test.
This will display a page with a number of entries. You only need to enter the payer email address as all other fields have been filled in by the system.
Enter a valid email address.
Press Perform Test and you should see a page which displays the details of the sent emails. If you go to your email accounts you should see these emails.
Go back to the product item and check that the top key code has gone from the key code list.
If this has been successful, it indicates that the application, emails and database are all working correctly. It does not check the operation with PayPal as this is a local test which by passes PayPal. To fully test the system with PayPal perform the following test.
Perform a PayPal test
The best method to do a test with PayPal is with a second PayPal account. You cannot make a purchase from your own account.
Create a product with a small value of say $0.01
In the list of products in the admin page you will see a link called 'buttons'. Click on this link and you will see a button for the product you have created.
Click on the button and it should take you to PayPal where you can purchase the item using your second PayPal account.
You should receive an email from PayPal detailing the payment and an email from PHPKeyCodes with your key code.
If you go back to the admin pages you should see that the key code has been removed from the list.
Correct completion of this test indicates the system is working correctly with your PayPal account.

