Download the PHP package mosaicora/plugin-core-php without Composer

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

mosaicora/plugin-core-php

Framework-agnostic PHP helpers for Mosaicora Open Graph image URLs and mosaicora:og JSON-LD v3 overrides.

Install

The package requires PHP 8.1 or newer and has no runtime dependencies.

Build an Open Graph image URL

The output is deterministic: it normalizes duplicate and trailing path slashes, keeps readable UTF-8 paths, ignores fragments, filters default tracking/control parameters, and percent-encodes the sorted remaining page query into the CDN path before .jpg. The CDN ignores query parameters after .jpg for source page lookup.

The home page produces https://cdn.mosaicora.io/s/{siteId}.jpg nested paths remain below /s/{siteId}. Pass baseOrigin to use a different CDN origin.

Refreshing social image URLs

Social networks can retain a link preview after their first crawl. A new image URL helps them retrieve a new asset when they re-scrape page metadata, but it does not force them to re-scrape.

Use an explicit release or content revision when one is available:

Or opt in to a UTC schedule with cacheBuster: daily, weekly, monthly, or a positive duration such as 15m, 6h, or 7d. cacheVersion takes precedence over cacheBuster and replaces any existing v parameter. Keep the default stable URL unless your content genuinely needs rotation. monthly is a good production default for most pages. The reserved v token remains after .jpg and is cache-only.

Add a v3 JSON-LD override

Keep existing Schema.org data and add only values Mosaicora should use exactly:

serialize() removes null values recursively and escapes <, making the result safe to embed in an HTML JSON-LD script element. The helper deliberately does not reject semantic role names or values at runtime, applications should use the documented v3 contract below.

Public API

See Mosaicora OG Overrides v3 for the semantic-role contract.

Development and releases

Pull requests and pushes run this validation on PHP 8.1 through 8.4. To release, create and push a semantic v{version} Git tag. The release workflow validates the package and creates a GitHub Release. Packagist resolves the installable version from that Git tag; register the repository there and enable its GitHub webhook so tags are synchronized automatically. Do not add a version field to composer.json for this VCS-distributed package.

Security

Please read SECURITY.md before reporting a vulnerability.

Licensed under the Apache License 2.0.


All versions of plugin-core-php with dependencies

PHP Build Version
Package Version
Requires php Version ^8.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 mosaicora/plugin-core-php contains the following files

Loading the files please wait ...