Location and Naming Convention

For a new plugin, the following location conventions must be used:

  • Each plugin is deployed in its own folder in the document root. The document root path is /var/www/pa-payment-sdk.

  • Each folder must have the same name as the plug-in script name. For example, the PayPal plug-in path must be $(DOCUMENT_ROOT)/PayPal/PayPal.php.

  • The plug-in directory may contain an internationalization directory $(PLUGIN_NAME)/i18n that contains a set of files with language specific strings (case-sensitive):

    • The file name must be: <two-letter language code>.strings (for example, en.string for English, or ru.string for Russian).

    • The file must contain all language-specific strings for the given language; each string must start from the new line.

    • The structure of each string must be: "<key>" "<translation>" (for example, "unknown_error" "Unknown payment error. Check logs for more information.").

  • Any other files used by the plugin can be placed into the plug-in directory.

  • The plug-in script file must implement all methods using the following notation: $(PLUGIN_NAME)_$(METHOD_NAME). For example, the TestConnection method must have the following signature in the PayPal.php script file:

    Copy
    function PayPal_TestConnection($params)
CloudBlue, an Ingram Micro business, uses cookies to improve the usability of our site. By continuing to use this site and/or logging in you are accepting the use of these cookies. For more information, visit our Privacy Policy.