Download the PHP package pinkwhalenl/jellyfish without Composer
On this page you can find all versions of the php package pinkwhalenl/jellyfish. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Informations about the package jellyfish
JellyFish
Most easy and dynamic Laravel CMS with build-in Language, User & media management. With modules
you can build your own backend page witf pre-configured fields like eg. text
, textarea
, select
etc. All fields will be stored inside a JSON column of the jelly_types
table. Each page will be stored inside jelly_content
table. On the front-end you can query them by using the Jelly
static class like; Jelly::Module('categories')->get()
.
Overview:
- Requirements
- Installation
- Upgrade guide
- Dynamic Content
- Add Module
- Available fields
- Text field
- Markdown field
- Select field
- List document from Module field
- Picture field
- Attachment field
- Front-end Usage
- Get document from selected module
- Print Images
- Using Markdown field
- Using Markdown field
- Store your Forms
- Authentication
- Translations
- Development
Requirements
- Laravel 5.7.* (or higher)
- PHP 7.1 (or higher)
- Pre-configured DB (Supporting JSON columns)
Upgrade guide
No data()
needed anymore to get your field data from a document. Now you can do $result->data->title
. Also you can query inside the data
column of the jelly_content
table. Please update your code, in the next versions data()
function will be removed.
Installation
- Run
composer require pinkwhalenl/jellyfish
. - Be sure your
.env
file is configured (DB). - Publish the config, css,js & font files
php artisan vendor:publish
. - Run the new migrations
php artisan migrate
. - Go to
https://{YOURDOMAIN}}.com/backend
. - Sign-in with the default credentials;
[email protected]
&secret
.
Dynamic content
Modules are like MySQL database tables, you'll define columns inside modules
to structure you data and grouping them. On the Admin side of this platform you can add fields
into you JSON file, and by telling each field what to do you'll get a customer friendly form. When you finished you're module
you can start adding some documents from the navigation bar.
Add Module
- Click on the right top side on your username.
- Click on
admin - Modules
. - Click on
Create new Module
. - Add an
title
and also check some options who are needed in your case. -
Start clean and add the following code.
- Fill the fields parts with the fields below.
[Note] Default checkboxes while adding modules
you can check two checkboxes. sort
& published_at
those two are separated from the JSON data and have their own column inside the jelly_content
table. You can also query them by the standard eloquent way.
Available fields
In each field you can still manage your validation rules brought from Laravel with the key validation
. Also their are some functions to specify how the data will be stored inside your DB. Also has each field
his own Options. So please check the documentation below.
Text
When you'll using a text field for title purposes, you can als add "slug":true
. The system will automatically add the field {name}_slug
. Note; you cannot change this afterwards when a document is already saved!
Markdown
Select options
Item from other Module
This field will list other modules with a selected column. The document unique ID will be stored inside this field.
Picture
This field let you select an image from the Media library.
Attachment
This field let you select an file from the Media library.
Front-end usage
When you'll store a document eg. based on the selected module
. All content will be stored inside the data
column. This column is filled with the module's JSON values.
Get document from selected module
It's just Laravel, we did only the first few steps. So use the static function Jelly::Module('MODULENAME')->{Query}
. On the background we take the Content
model and query by type ->where('type','MODALNAME')
.
Print images
Jellyfish supports a wide range of supporting images and image-caching.
Using Markdown field
When using the markdown field add the Markdown::convertToHtml()
function to convert markdown into HTML format.
Store Forms
CMS stores and let you manage your form data. See example below;
Authentication
You can check if a user has signed in by typing JellyAuth::Check()
this functions returns true/false
. You can also get all user's information by using the User()
function like; JellyAuth::User()
. When you want to know if an user has admin-access
then type; JellyAuth::IsAdmin()
, this also returns true/false
.
Example
Translations
By default jellyfish will recognize laravel's running language. You can also force it to another language.
On development environments
When you want to change this package from the vendor
folder. composer require pinkwhalenl/jellyfish dev-master --prefer-source
All versions of jellyfish with dependencies
graham-campbell/markdown Version ^11.0
intervention/image Version ^2.5