Download the PHP package grottopress/wordpress-suv without Composer

On this page you can find all versions of the php package grottopress/wordpress-suv. 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 wordpress-suv

WordPress SUV

SUV is our own architecture for building WordPress themes and plugins at GrottoPress. This package is a scaffold for implementing SUV.

SUV is short for Setups-Utilities-Views. It emphasises an object oriented approach to writing WordPress plugins and themes, and provides for a cleaner, more organised code base.

SUV employs object composition extensively, and makes full use of the express power of core WordPress' event-driven architecture.

Setups: Includes all objects with methods that interact directly with WordPress, usually by means of action and filter hooks.

Utilities: Utilities are objects with methods that are needed by setups and views to accomplish their goals.

Views: Views are templates and partials to be loaded by the theme/plugin or WordPress.

Requirements

Code style

Code should comply with PSR-1, PSR-2 and PSR-4, at least.

You are strongly encouraged to use strict typing in PHP 7, and specify types for function/method arguments and return values.

As much as possible:

Usage

Note: From here on, app refers to your theme or plugin.

Directory Structure

Set up your own app's directory structure as follows:

Not all directories/files may apply in your case. Remove whichever you do not need, and add whatever you require as necessary. Just keep the general concept in mind.

Autoloading

Your composer.json autoload config:

Require SUV

From the root of your app, run:

Sample WordPress plugin

Let's write a sample WordPress plugin using SUV, shall we?

You may file utility classes in app/MyPlugin/Utilities/. Utility classes do not interact directly with WordPress, but contain functionality that setup classes and views can use to accomplish their goal.

Since our plugin extends SUV's AbstractPlugin, it is essentially a singleton. The entire plugin (with all objects) can be retrieved with a call to Vendor\MyPlugin\MyPlugin::getInstance()

Let's create a helper to do this in app/helpers.php.

Other plugins and themes now have access to the singleton plugin instance, and can remove an action in our plugin thus:

Now, to conclude with our plugin's bootstrap:

Building a plugin?

We created a WordPress plugin scaffold that uses SUV. It sets up the most common stuff for you to dive straight into code.

You should check it out »

Building a theme?

If you're looking to build a theme using SUV, you should check out Jentil.

Jentil is a framework for rapid WordPress theme development, built using the SUV architecture.

It comes with numerous features, and includes a loader that loads templates (eg: page.php, index.php, single.php etc) only from the app/templates directory, and partials (eg: header.php, footer.php, sidebar.php) from the app/partials directory.

Check it out »

Development

Run tests with composer run test.

Contributing

  1. Fork it
  2. Switch to the master branch: git checkout master
  3. Create your feature branch: git checkout -b my-new-feature
  4. Make your changes, updating changelog and documentation as appropriate.
  5. Commit your changes: git commit
  6. Push to the branch: git push origin my-new-feature
  7. Submit a new Pull Request against the GrottoPress:master branch.

All versions of wordpress-suv with dependencies

PHP Build Version
Package Version
Requires php Version >=7.0
grottopress/getter Version ^1.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 grottopress/wordpress-suv contains the following files

Loading the files please wait ....