Download the PHP package carbon/condition without Composer

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

Latest Stable Version Total Downloads GitHub forks GitHub stars GitHub watchers

Carbon.Condition Package for Neos CMS

This package provides some fusion helper for making writing conditions (@if) easier.
You can look at a real world example here

Installation

Carbon.Condition is available via packagist. Add "carbon/condition" : "^2.0" to the require section of your composer.json or run composer require carbon/condition.

Carbon.Condition:Case

Link to the fusion file
Return true if a content element or a node type definition is on a document.
Example usage:

In the example above the value FooBar gets only rendered if a content node type Foo.Bar:NodeType with the property row set not to one is on the current document.

In the example above the value FooBar gets only rendered if the document has the mixin Foo.Bar:MixinNodeType.

You can also mix the conditions:

In the example above the value FooBar gets only rendered if the document or a content element has the mixin Foo.Bar:MixinLightbox and the property lightbox set to true.

Default values

Overview of properties:

Property Description
node The node as starting point for the query
enabled If set to false, it return always false
content.nodeType Set the node type
content.propertyFilter This string gets appended to the content.filter. Example usage see above
content.collection The filter string for the content collection. Normally you don't need to change this property.
content.filter The filter string for the content element. Normally you don't need to change this property.
document.nodeType Set the node type
document.propertyFilter This string gets appended to the document.filter. Example usage see above
document.filter The filter string for the document element. Normally you don't need to change this property.
context.backend If set to true, the value is always return true in backend context
context.live If set to true, the value is always return true in live context

Carbon.Condition:Properties

Link to the fusion file
Helper for checking if the element should get rendered or not. Example usage:

In the example above the condition is only get true if the node has title and image set.

Default values

Overview of properties:

Property Default value Description
node ${node} The node as starting point for the query
properties false Set the needed properties as comma seperated string. You can mix string and object based properties.
operator 'AND' If set to 'AND' or '&&', all properties have to be set. If it set to 'OR' or '\|\|' only one property is needed
context.backend true If set to true, the value is always return true in backend context
context.live false If set to true, the value is always return true in live context

All versions of condition with dependencies

PHP Build Version
Package Version
Requires neos/neos Version ~9.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 carbon/condition contains the following files

Loading the files please wait ....