Download the PHP package esanj/public-pages without Composer

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

đŸ› ī¸ Esanj Public Pages for Laravel

esanj/public-pages is a Laravel package that gives your application a clean, ready-to-use home page and a complete set of HTTP error pages (400, 401, 403, 404, 419, 429, 500, 502, 503, 504), with bundled assets (CSS, background image), built-in English & Persian translations, and full control through a simple config file.

Everything works out of the box. You only publish files when you want to customize them.


✨ Features


📋 Requirements

Requirement Version
PHP 8.2, 8.3 or 8.4
Laravel 12.x or 13.x

đŸ“Ļ Installation

1. Install via Composer:

That's it — the package auto-registers itself. The home page and error pages are already active.

2. (Optional) Publish files you want to customize:

With no options, this publishes everything (views, assets, translations, and config). See Commands to publish only what you need.


đŸ—‚ī¸ What Gets Published

What Published to
Home view resources/views/vendor/publicpages/home.blade.php
Error views resources/views/errors/
Assets public/assets/vendor/public-pages/
Translations lang/{locale}/publicpages.php
Config config/esanj/public_pages.php

File tree after a full install:


🧩 Commands

Command What it does
php artisan publicpages:install Publishes everything (views, assets, lang, config)
php artisan publicpages:publish-views Publishes views and assets
php artisan publicpages:publish-lang Publishes translation files
php artisan publicpages:publish-config Publishes the config file

publicpages:install also accepts flags to publish only part of the package:

â„šī¸ publicpages:install always overwrites existing files, so you can re-run it any time to pull in updates.

You can also publish directly with Laravel's vendor:publish using the package tags:

Tag Includes
esanj-public-pages-views 🎨 Views
esanj-public-pages-assets 🧩 Public assets
esanj-public-pages-lang 🌐 Translations
esanj-public-pages-config âš™ī¸ Config

âš™ī¸ Configuration

Publish the config file:

This creates config/esanj/public_pages.php. The full default config:

Common tweaks

Disable the home route (you provide your own /):

Change the home page path:

Use Laravel's default error pages instead of the package's:

Change the app name shown on the pages:

Apply extra middleware to the home route — edit config/esanj/public_pages.php:

🔁 To reset the configuration, delete config/esanj/public_pages.php and run php artisan config:clear. The package falls back to its built-in defaults automatically.


🌐 Localization

Translations live in lang/{locale}/publicpages.php and ship with English (en) and Persian (fa). The error layout automatically switches to RTL when the app locale is fa.

Publish them to customize:

File structure:

Reference any string in Blade with the publicpages::publicpages.* key:

Add another locale by creating lang/{locale}/publicpages.php (e.g. lang/es/publicpages.php) with the same structure.


➕ Adding a New Error Page

Suppose you want to support 505 HTTP Version Not Supported.

1. Add the translations in lang/{locale}/publicpages.php under errors:

2. Create the view resources/views/errors/505.blade.php:

The shared errors::layout reads $code and pulls the matching title/message from your translation file — no other wiring needed.


🎨 Customizing the Look

📖 For a complete, beginner-friendly, step-by-step walkthrough, see docs/GUIDE.md.


📄 License

MIT © 2025 — Esanj Team


All versions of public-pages with dependencies

PHP Build Version
Package Version
Requires php Version ^8.2|^8.3|^8.4
illuminate/support Version ^12.0|^13.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 esanj/public-pages contains the following files

Loading the files please wait ...