Skip to content
schmittjoh edited this page Sep 17, 2010 · 15 revisions

Getting Started / Set-Up

1. Checking Requirements

A PHP version of 5.3 or higher is required. You can check this by either creating a small script calling phpinfo(), or by running php -v on the command line.

2. Installing the plugin

SVN Checkout

You can checkout the entire source code into a local folder by executing the following command:

svn checkout http://svn.github.org/schmittjoh/jmsPaymentPlugin.git

SVN External

In case, your project is already under version control, it is recommended that you include jmsPaymentPlugin as an external with the following URL:

http://svn.github.org/schmittjoh/jmsPaymentPlugin.git

Pear Package

You can also use the Pear Installer that ships with symfony. Simply, run the following command inside your project root folder:

php symfony plugin:install jmsPaymentPlugin

3. Installing 3rd party API libraries

PayPal

In case, you want to use the PayPal payment method, you also need to download the “PayPal API: SOAP Interface” for PHP which you can find here: https://cms.paypal.com/us/cgi-bin/?cmd=_render-content&content_ID=developer/library_download_sdks

After extracting the archive, you need to copy the contents of its lib folder into your global “lib/vendor/PayPal/” directory (path is case-sensitive on unix).

In case, you want to use any of the Micropayment payment methods, you also need to download their Service Client and the respective service interface (PHP files) from http://techdoc.micropayment.de and place them in your global “lib/vendor/micropayment/” folder.

4. Configuring the plugin

Before you can use the built-in payment methods, you need to configure some credentials which are required by the payment service providers. You can do so in your global app.yml by copying over the respective parts from the plugin’s app.yml (do not directly edit the app.yml inside the plugin folder), e.g. for PayPal:

all:
  jmsPaymentPlugin:
    ###########################
    # PayPal related settings #
    ###########################
    paypal:
      # PayPal API credentials
      username: 'my username'
      signature: 'my signature'
      password: 'my password'

You can test your settings by opening up the demo module (e.g. frontend_dev.php/paymentDemo; don’t forget to add paymentDemo to your enabled_modules in your settings.yml).