Download the PHP package hsyir/laravel-adminlte without Composer

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

Easy AdminLTE integration with Laravel

Latest Version on Packagist Build Status Quality Score StyleCI Total Downloads

This package provides an easy way to quickly set up AdminLTE v3 with Laravel 6. It has no requirements and dependencies besides Laravel, so you can start building your admin panel immediately. The package just provides a Blade template that you can extend and advanced menu configuration possibilities. A replacement for the make:auth Artisan command that uses AdminLTE styled views instead of the default Laravel ones is also included.

If you want use the older versions, please use the following versions:

  1. Requirements
  2. Installation
  3. Updating
  4. Usage
  5. Artisan Console Commands
    1. The adminlte:install Command
      1. Options
    2. The adminlte:plugins Command
    3. The adminlte:update Command
    4. Authentication views
      1. Using the authentication views without the adminlte:install command
  6. Configuration
    1. Title
    2. Favicon
    3. Logo
    4. Layout
    5. Classes
    6. Sidebar
    7. Control Sidebar (Right Sidebar)
    8. URLs
    9. Laravel Mix
    10. Menu
      1. Adding a Search Input
      2. Custom Menu Filters
      3. Menu configuration at runtime
      4. Active menu items
    11. Menu Filters
    12. Plugins
      1. Pace Plugin Configuration
  7. Translations
    1. Menu Translations
  8. Customize views
  9. Issues, Questions and Pull Requests

1. Requirements

2. Installation

  1. Require the package using composer:

  2. Install the package using the command (For fresh laravel installations):

You can use --basic to avoid authentication scaffolding installation

You can use --force to overwrite any file

You can also use --interactive to be guided through the process and choose what you want to install

3. Updating

  1. To update this package, first update the composer package:

  2. Then, we need to update the assets

    If you using AdminLTE for Laravel 5.x and are upgrading Laravel 6 version, delete the folder adminlte inside your public/vendor folder.

    And then use this command to publish new assets

  3. If you have published and modified the default master, page views or login views, you will need to update them too.

    Option 1:

    • Make a copy of the views you modified.
    • Publish the views again, using

    • Redo the modifications you did.

    Option 2:

    • Modify in the css, js and other assets location in the master and page views.

4. Usage

To use the template, create a blade file and extend the layout with @extends('adminlte::page'). This template yields the following sections:

All sections are in fact optional. Your blade template could look like the following.

You now just return this view from your controller, as usual. Check out AdminLTE to find out how to build beautiful content for your admin panel.

5. Artisan Console Commands

5.1 The adminlte:install Command

You can install all required & additional resources with the adminlte:install command.

Without any option it will install AdminLTE assets, config & translations. You can also install the Authentication Views with adding --type=enhanced or additional to the Authentication Views also the Basic Views & Routes with adding --type=full to the adminlte:install command.

5.1.1 Options

5.2 The adminlte:plugins Command

If you won't use cdn for the plugins, you can manage the optional plugins assets with the adminlte:plugins command.

You can list all available plugins, install/update/remove all or specific plugins. Here are some examples for the command:

Install all plugin assets

Update all Plugin assets

Remove all Plugin assets

5.2.1 Options

5.3 The adminlte:update Command

This command is only a shortcut for adminlte:install --force --only=assets.

5.4 Authentication views

Note: only for Laravel 5.2 and higher

This package ships the following command to replaces the authentication views with AdminLTE style views.

5.4.1 Using the authentication views without the adminlte:install command

If you want to use the included authentication related views manually, you can create the following files and only add one line to each file:

By default, the login form contains a link to the registration form. If you don't want a registration form, set the register_url setting to null and the link will not be displayed.

6. Configuration

First, publish the configuration file:

Now, edit config/adminlte.php to configure the title, skin, menu, URLs etc. All configuration options are explained in the comments. However, I want to shed some light on the menu configuration.

6.1 Title

The default title of your admin panel, this goes into the title tag of your page. You can override it per page with the title section. You can optionally also specify a title prefix and/or postfix.

The following config options available:

6.2 Favicon

Favicons could be used easily. There are two different ways to do this. Please add all favicons in the dir public/favicons/.

If 'use_full_favicon' => true more favicon files in public/favicons/ will be used. The activated code is:

6.3 Logo

The logo is displayed at the upper left corner of your admin panel. You can use basic HTML here if you want for a simple text logo with a small image logo (e.g. 50 x 50 pixels), or you can use two images one big (e.g. 210 x 33 pixels) and one small (e.g. 50 x 50 pixels). You can also change the sizes of the images and the alt text for both logos.

6.4 Layout

It's possible change the layout, you can use a top navigation (navbar) only layout, a boxed layout with sidebar and you can enable fixed mode for sidebar, navbar and footer.

The following config options available:

Responsive Usage for layout_fixed_navbar & layout_fixed_footer

With responsive you can disable or enable the fixed navbar/footer for specific viewport sizes.

The array the following keys available, you can set them to true or false:

Examples

6.5 Classes

You can change the look and behavior of the admin panel, you can add extra classes to body, brand, sidebar, sidebar navigation, top navigation and top navigation container.

The following config options available:

6.6 Sidebar

You can modify the sidebar, you can disable the collapsed mini sidebar, start with collapsed sidebar, enable sidebar auto collapse on specific screen size, enable sidebar collapse remember, change the scrollbar theme or auto hide option, disable sidebar navigation accordion and sidebar navigation menu item animation speed.

The following config options available:

6.7 Control Sidebar (Right Sidebar)

Here you have the option to enable a right sidebar. When active, you can use @section('right-sidebar') The icon you configured will be displayed at the end of the top menu, and will show/hide the sidebar. The slide option will slide the sidebar over the content, while false will push the content, and have no animation. You can also choose the sidebar theme (dark or light).

The following config options available:

6.8 URLs

Here we have the url settings to setup the correct login/register link. Register here your dashboard, logout, login and register URLs.

6.9 Laravel Mix

If you want to use Laravel Mix instead of publishing the assets in your /public/vendor folder, start by installing the following NPM packages:

Add the following to your bootstrap.js file after window.$ = window.jQuery = require('jquery');:

Replace your app.scss content by the following:

After preparing the Laravel Mix vendor files, set enabled_laravel_mix to true to enable load app.css & app.js .

6.10 Menu

Specify your menu items to display in the left sidebar. Each menu item should have a text and a URL. You can also specify an icon from Font Awesome. A string instead of an array represents a header in sidebar layout. The 'can' is a filter on Laravel's built in Gate functionality.

You can configure your menu as follows:

With a single string, you specify a menu header item to separate the items. With an array, you specify a menu item. text and url or route are required attributes. The icon attribute is optional, you get an open circle if you leave it out. The available icons that you can use are those from Font Awesome. Just specify the name of the icon and it will appear in front of your menu item.

It's also possible to add menu items to the top navigation while sidebar is enabled, you just need to set the topnav attribute to true. This will ignored if the top navigation layout is enabled, all menu items will appear in top navigation.

Use the can attribute if you want conditionally show the menu item. This integrates with Laravel's Gate functionality. If you need to conditionally show headers as well, you need to wrap it in an array like other menu items, using the header attribute:

6.10.1 Adding a Search Input

It's possible to add a search input in your menu, using a menu item with the following configuration:

6.10.2 Custom Menu Filters

If you need custom filters, you can easily add your own menu filters to this package. This can be useful when you are using a third-party package for authorization (instead of Laravel's Gate functionality).

For example with Laratrust:

And then add to config/adminlte.php:

6.10.3 Menu configuration at runtime

It is also possible to configure the menu at runtime, e.g. in the boot of any service provider. Use this if your menu is not static, for example when it depends on your database or the locale. It is also possible to combine both approaches. The menus will simply be concatenated and the order of service providers determines the order in the menu.

To configure the menu at runtime, register a handler or callback for the MenuBuilding event, for example in the boot() method of a service provider:

The configuration options are the same as in the static configuration files.

A more practical example that actually uses translations and the database:

This event-based approach is used to make sure that your code that builds the menu runs only when the admin panel is actually displayed and not on every request.

6.10.4 Active menu items

By default, a menu item is considered active if any of the following holds:

To override this behavior, you can specify an active parameter with an array of active URLs, asterisks and regular expressions are supported.

To utilize regex, simply prefix your pattern with regex: and it will get evaluated automatically. The pattern will attempt to match the path of the URL, returned by request()->path(), which returns the current URL without the domain name. Example:

6.11 Menu Filters

Here we can set the filters you want to include for rendering the menu. You can add your own filters to this array after you've created them. You can comment out the GateFilter if you don't want to use Laravel's built in Gate functionality

Default menu filters:

6.12 Plugins

Configure which JavaScript plugins should be included. At this moment, DataTables, Select2, Chartjs and SweetAlert are added out-of-the-box, including the Javascript and CSS files from a CDN via script and link tag. Plugin Name, active status and files array (even empty) are required. Files, when added, need to have type (js or css), asset (true or false) and location (string). When asset is set to true, the location will be output using asset() function.

By default the DataTables, Select2, ChartJS, Pace and SweetAlert2 plugins are supported and but not active. You can activate them with changing the config file to load it on every page or add a section in specific blade files, this will automatically injecting their CDN files.

Section example: @section('plugins.Datatables', true)

You can use these plugins by default:

You can also add and configure new plugins, modifying the plugin variable using the example structure below:

With the name string you specify the plugin name, and the active value will enable/disable the plugin injection. Each plugin have a files array, with contain arrays with file type (js or css), and location.

If the asset value is true, the injection will use the asset() function.

6.12.1 Pace Plugin Configuration

You can change the Pace plugin appearence, when using the CDN injection modifying the css file location.

Color values: black, blue (default), green, orange, pink, purple, red, silver, white & yellow

Theme values: barber-shop, big-counter, bounce, center-atom, center-circle, center-radar (default), center-simple, corner-indicator, fill-left, flash, flat-top, loading-bar, mac-osx, minimal

7. Translations

At the moment, English, German, French, Dutch, Portuguese, Spanish and Turkish translations are available out of the box. Just specify the language in config/app.php. If you need to modify the texts or add other languages, you can publish the language files:

Now, you can edit translations or add languages in resources/lang/vendor/adminlte.

7.1. Menu Translations

This resource allow you to use lang files, and is active by default.

Configurating Menu Using Lang:

First, configure the menu using the key text as translation string. This is an example of configuration:

Lang Files

All the translation strings must be added in the menu.php file of each language needed. The translations files are located at resources/lang/vendor/adminlte/

This is an example of the menu.php lang file:

To translate the menu headers, just use the header param. Example:

8. Customize views

If you need full control over the provided views, you can publish them:

Now, you can edit the views in resources/views/vendor/adminlte.

9. Issues, Questions and Pull Requests

You can report issues and ask questions in the issues section. Please start your issue with ISSUE: and your question with QUESTION:

If you have a question, check the closed issues first. Over time, I've been able to answer quite a few.

To submit a Pull Request, please fork this repository, create a new branch and commit your new/updated code in there. Then open a Pull Request from your new branch. Refer to this guide for more info.


All versions of laravel-adminlte with dependencies

PHP Build Version
Package Version
Requires laravel/framework Version >=6.0
php Version >=7.2.0
almasaeed2010/adminlte Version ^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 hsyir/laravel-adminlte contains the following files

Loading the files please wait ....