Download the PHP package php-forge/html-helper without Composer

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

Awesome HTML Helpers Code Generator for PHP.


PHPUnit Codecov Infection Psalm Psalm Coverage Style ci

HTML Helper is a PHP library that simplifies the creation of HTML elements. It provides a set of classes to generate HTML attributes, encode content, sanitize HTML content, and more.

Installation

The preferred way to install this extension is through composer.

Either run

or add

to the require section of your composer.json file.

Usage

Add CSS classes

The CssClasses::class helper can be used to add CSS classes to an HTML element.

The method accepts three parameters:

Overwriting the class attribute:

Convert regular expression to pattern

The Utils::class helper can be used to normalize a regular expression.

The method accepts one parameter:

Encode content

The Encode::class helper can be used to encode HTML content.

The method accepts tree parameters:

Encode value

The Encode::class helper can be used to encode HTML value.

The method accepts tree parameters:

Get short class name

The Utils::class helper can be used to get the short class name.

The method accepts one parameter:

Generate arrayable name

The ArrayableName::class helper can be used to generate an arrayable name.

The method accepts one parameter:

Generate input id

The Utils::class helper can be used to generate an input id.

The method accepts tree parameters:

Generate input name

The Utils::class helper can be used to generate an input name.

The method accepts tree parameters:

Sanitize content

The Sanitize::class helper can be used to sanitize HTML content.

The method accepts one parameter:

Render HTML attributes

The Attributes::class helper can be used to render HTML attributes in a programmatic way.

Render Template

The Template::class helper can be used to render a template.

The method accepts two parameters:

\n is a new line character, and it is used to separate the tokens in the template.

Validate value in list

The Validator::class helper can be used to validate a value in a list.

The method accepts tree parameters:

Validate value iterable

The Validator::class helper can be used to validate an iterable value. If the value is not iterable or null, the method will throw an InvalidArgumentException.

The method accepts one parameter:

Validate value numeric

The Validator::class helper can be used to validate a numeric value. If the value is not numeric or null, the method will throw an InvalidArgumentException.

The method accepts one parameter:

Validate value scalar

The Validator::class helper can be used to validate a scalar value. If the value is not scalar or null, the method will throw an InvalidArgumentException.

The method accepts one parameter:

Validate value string

The Validator::class helper can be used to validate a string value. If the value is not a string or null, the method will throw an InvalidArgumentException.

The method accepts one parameter:

Testing

Check the documentation testing to learn about testing.

Support versions

PHP81

License

The MIT License (MIT). Please see License File for more information.

Our social networks

Twitter


All versions of html-helper with dependencies

PHP Build Version
Package Version
Requires php Version ^8.1
ext-mbstring Version *
php-forge/html-interop Version ^0.3
voku/anti-xss Version ^4.1
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 php-forge/html-helper contains the following files

Loading the files please wait ....