Download the PHP package katheroine/layin without Composer

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

Layin

General purpose web page layout.

See demo [https://katheroine.github.io/layin]

Prerequisites

  1. PHP: at least PHP 7.2.5
  2. Composer - dependency manager for PHP.
  3. A web server (Apache has been used in the example below).

Project set-up

  1. Create project directory and place composer.json - project configurtion file for Composer with appropriate content, eg.:

  2. Run in the console:

The vendor directory will be created and the dependencies will be placed there.

  1. If you're using Git, create .gitignore file with vendor directory and optionally composer.lock:

It will remove those files/directories from the Git tracking process, so that those ones won't be placed in the respository.

  1. Prepare project directories structure within the main project directory:

You can use the predefined Layin command:

  1. Choose concrete theme, e.g. Violet - currently the only available, and generate links to its files, which will be placed in the site directory. You can use the predefined Layin command:

  2. Copy and edit the configuration files from vendor/katheroine/layin/site/config to site/config directory and replace its content with the one appropriate to your site:
  1. Copy and edit the AbstractBasePreconfiguredPageRenderer.php file from vendor/katheroine/layin/site/preconfigurations/page_renderers to site/preconfigurations/page_renderers:

Copy and edit the IndexPreconfiguredPageRenderer.php file from vendor/katheroine/layin/site/preconfigurations/page_renderers to site/preconfigurations/page_renderers directory:

  1. Create custom Twig base template (needed for adding custom CSS stylesheets) base.awesomesite.twig.html

  2. Create Twig template for index page index.awesomesite.twig.html, based on base.awesomesite.twig.html

  3. Copy and edit the index.php file from vendor/katheroine/layin/site/public/pages to site/public/pages directory

  4. Generate Composer autoload files

  5. Set-up new Apache virtualhost besed on example with ServerName set to awesomesite.local.

  6. Add appropriate entry in the /etc/hosts file.

  7. Run http://awesomesite.local/ on the web browser. You should see the properly displayed page with the header title and subtitle previously configured by you, but with no graphics nor styles.

  8. If you need to use external fonts, create the fonts defining stylesheet in the site/public/assets/stylesheets directory and name them with the awesomesite phrase eg. fonts.awesomesite.css:

Choose and download the appropriate font files (like above LiberationSans-Regular.ttf). Place them in the appropriate public directory, eg. site/public/assets/font/liberation-sans/.

  1. Create the colors defining stylesheets in the site/public/assets/stylesheets directory and fill with the choosen colors (use the examples below):
  1. Complete the site/templates/base.awesomesite.twig.html template file with previously creates CSS stylesheets:

After refreshing the site in the web browser you should see the change in the colors.

  1. Prepare logo in the PNG format and save it as site/public/assets/images/logo.png. After refreshing the site in the web browser you should see the logo on the page.

  2. Prepare the background cover in the PNG format and save it as site/public/assets/images/cover.jpeg. After refreshing the site in the web browser you should see the cover on the page.

  3. Create the icons setting site/public/assets/stylesheets/link-icons.awesomesite.css stylesheet:

After refreshing the site in the web browser you should see the icons on the page.

  1. You can use the content theme, e.g. Swamp Violet - currently the only available, and generate links to its files, which will be placed in the site directory. That will provide you the CSS styles for the headers, paragraps, lists, tables, images, etc. in the articles placed in the main tag. You can use the predefined Layin command:

  2. You also need to provide the CSS files defining the used colors for the content, eg. colors-content.awesomesite.css:

  3. To handle accessibility feature you also need to provide colors-content-accessibility.awesomesite.css file:

  4. For the above example you need to extend the existing colors.awesomesite.css file with the new colors:

  5. Finally, you need to place the new CSS files into the template file base.awesomesite.twig.html:

All versions of layin with dependencies

PHP Build Version
Package Version
Requires php Version >=7.2.5
twig/twig Version ^3.0
symfony/yaml Version ^6.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 katheroine/layin contains the following files

Loading the files please wait ...