Download the PHP package dynamic/silverstripe-shopify without Composer

On this page you can find all versions of the php package dynamic/silverstripe-shopify. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package silverstripe-shopify

SilverStripe Shopify

A Shopify Store module for Silverstripe.

CI codecov

Latest Stable Version Total Downloads Latest Unstable Version License

Requirements

Installation

note - due to an issue with v10.0.6 of osiset/basic-shopify-api, we recommend requiring version 10.0.5 of osiset/basic-shopify-api if you're running PHP 7.

License

See License

Overview

Silverstripe Shopify allows you to create a headless Shopify store using Silverstripe CMS. Products and collections are imported from Shopify, and created as pages in the CMS. The Shopify Buy Button is used to purchase products via the Shopify cart and checkout.

Setup

Create a private app

First, ensure that private apps are enabled in your Shopify Store (this is false by default).

In your Shopify Admin, click Apps from the left column navigation. Once the page loads, scroll to the bottom and click on the link in the following line:

Working with a developer on your shop? Manage private apps

If no private apps exist, click Create new private app. Otherwise, click on the link to the existing private app you'd like to use for your Silverstripe website.

Obtaining API Keys and Setting Permissions

Admin API

In the Admin API section, set the following permissions to Read Access

All other permissions are optional and are not required for Silverstripe Shopify.

Copy the following keys to the correspoding variables in your config:

Storefront API

In the Storefront API section, check

Check the following permission boxes to enable the access required by Silverstripe Shopify:

All other permissions are optional and are not required for Silverstripe Shopify.

Copy the following key to the corresponding variable in your config:

Basic configuration

Using Multipass

Importing products

Once the basic configuration above is setup, you can import Shopify products and collections via CLI using the ShopifyImportTask:

or by running the task in the browser at /dev/tasks/ShopifyImportTask

Usage

CMS

Products and collections are created as pages in the CMS. Products that belong to collections are automatically set as a child page of that collection in the site tree. If a product belongs to multiple collections, the ShopifyProduct page is created under the first listed collection, and subsequent collections will list a VirtualPage of the product.

All products and collections that are available in the private app sales channel will be imported.

Shopify related pages are set as draft or published based on the status set in Shopify. For products, if the product is set to Active in Shopify, it will be published in Silverstripe.

The module creates a CatalogPageAdmin to manage Shopify records via a ModelAdmin, rather than only in the site tree.

The ShopifyProduct page also implements product schema from schema.org. This provides more information to be displayed in search results for google and other search engines.

Theme

Cart Include

In your top-level Page.ss template, include the following just before the </body> tag:

Cart Configuration Options

To disable cart notes:

Setting notes character limit (when notes is enabled):

Note: For specific configuration by page type, you can set the showNote and noteLimit values per controller class.

You can also override the default cart settings via an Extension Hook updateCartOptions in the getCartOptions() function in ShopifyExtension.php.

Display Buy Button

Out of the box, there are 3 includes to display different variations of the Shopify Buy Button:

To display the Buy Button, just include one of the files above in your template.

Buy Button Configuration Options

The default settings for buy buttons in the module disables the iframe option, and strips out most of the buy button content and stylings. The includes above are instead intended to be used with the images and title imported from Shopify into the database, and with iframes disabled it enables complete control over the style of the buy button.

However, you can override the default settings for each Buy Button type above via Extension Hooks in ShopifyProduct.php.

Advanced

Product impression tracking

Product impressions can be tracked by adding data attributes to html tags rendered with products. data-sku is the only required data attribute, but data-title, data-category, and data-vendor can also be added.

Maintainers

Credits

Inspired by previous work done by xddesigners.

Bugtracker

Bugs are tracked in the issues section of this repository. Before submitting an issue please read over existing issues to ensure yours is unique.

If the issue does look like a new bug:

Please report security issues to the module maintainers directly. Please don't file security issues in the bugtracker.

Development and contribution

If you would like to make contributions to the module please ensure you raise a pull request and discuss with the module maintainers.


All versions of silverstripe-shopify with dependencies

PHP Build Version
Package Version
Requires php Version >=7.4 || >=8.0
bramdeleeuw/silverstripe-schema Version ^2.0.1
littlegiant/silverstripe-catalogmanager Version ^5.2
gnikyt/basic-shopify-api Version ^10.0
silverstripe/recipe-cms Version ^4.11
symbiote/silverstripe-gridfieldextensions Version ^3.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package dynamic/silverstripe-shopify contains the following files

Loading the files please wait ....