Our official guide(JA) for EC-Cube integration.
Before getting started with the following steps, please make sure you have met all the requirements provided by the official documentation.
Note: if you are on MacOS, most requirements are usually met by default. However, you might need to install PHP yourself instead of using the one that comes with the OS.
If you use Homebrew:
brew install php@7.4
brew link php@7.4
Once the requirements are met, clone this repo and follow the steps below from the root directory of this project.
Follow the Composer official document to install composer.phar
locally:
php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');"
php -r "if (hash_file('sha384', 'composer-setup.php') === '55ce33d7678c5a611085589f1f3ddf8b3c52d662cd01d4ba75c0ee0459970c2200a51f492d557530c71c15d8dba01eae') { echo 'Installer verified'; } else { echo 'Installer corrupt'; unlink('composer-setup.php'); } echo PHP_EOL;"
php composer-setup.php
php -r "unlink('composer-setup.php');"
php composer.phar create-project ec-cube/ec-cube ec-cube "4.2.1" --keep-vcs
If you plan to use EC-Cube 4.0, please use the following command to install it instead:
php composer.phar create-project ec-cube/ec-cube ec-cube "4.0.6" --keep-vcs
Then the next step is to install the Smartpay plugin. There are two ways to do it. The first is via the admin panel. If you choose this way, please skip to the Run the built-in web server section.
The second is to clone the repo into the EC-Cube folder:
cd ec-cube
git clone https://github.com/smartpay-co/ec-cube app/Plugin/Smartpay
./bin/console eccube:plugin:install --code=Smartpay
./bin/console eccube:plugin:enable --code=Smartpay
php -S 127.0.0.1:8000
Open the admin panel with the URL:
http://localhost:8000/admin
The default credential is: admin/password
If you have installed the Smartpay plugin already. Please skip this step.
To install the Smartpay plugin via the admin panel, you must download and upload the release package to the EC-Cube platform. The released packages are available at:
- For EC-Cube 4.0 https://github.com/smartpay-co/ec-cube/releases
- For EC-Cube 4.2 https://github.com/smartpay-co/smartpay-ec-cube42/releases
Download the latest version of the plugin package, then follow the installation section in the doccument(JA) to upload and install it.
Then follow the configuration section in the document (JA) to complete the configuration.