Download the PHP package husseinalhammad/fontawesome-svg without Composer

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

Font Awesome SVG - PHP

A PHP class that can be used to add Font Awesome 6+'s SVG icons inline without Javascript.

Installation

You can install it using Composer:

Or you can download the FontAwesomeSVG.php file and include it manually.

Usage

Files

Examples

Add custom classes:

Remove default class .svg-inline--fa:

Change <path> fill (default is currentColor):

Add <title></title>:

Multiple options at once:

Customise duotone icons:

Option What it means
class Adds classes to the SVG tag
default_class If set to false, the default CSS class won't be added to the SVG tag. Deafult: true.
inline_style Whether to add duotone styles as inline style to the <svg> tag. Deafult: true.
title Adds a <title> inside the SVG tag for semantic icons
title_id Adds an id attribute to <title> and adds aria-labelledby on the SVG tag with the same value
role The value of the role attribute in the SVG tag. Default: img
fill The value of the fill attribute in the <path> inside the SVG. Default: currentColor
primary Duotone primary options (see table below)
secondary Duotone secondary options (see table below)

Duotone

Requires v5.10.0 or greater, and a FontAwesome Pro license

Sharp

Requires v6.4.0 or greater, and a FontAwesome Pro license

options

If inline_style is enabled, the value of fill and opacity are also used in the inline style on <svg> tag.

Option What it means
fill The value of the fill attribute in the <path> inside the SVG. Default: currentColor
opacity The value of the opacity attribute in the <path> inside the SVG.

Examples:

Single colour:

Swapping Layer Opacity:

Single colour with custom opacity:

Custom colours and opacity:

Aliases

The short aliases from version 5 are still supported

Accessibility

The below is implemented based on:

role attribute

role="img" is added to the SVG tag by default:

<title>, aria-labelledby

You can set a <title>, an id for the <title> and the aria-labelledby attribute will be added automatically:

aria-* attributes

You can add any aria-* attribute to the SVG tag:

aria-hidden attribute

aria-hidden="true" is added to the SVG tag by default unless <title id=""> (and aria-labelledby) or aria-label is set.


All versions of fontawesome-svg with dependencies

PHP Build Version
Package Version
Requires php Version >=5.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 husseinalhammad/fontawesome-svg contains the following files

Loading the files please wait ....