ASISG
Gy - php framework/CMS
Gy – it is a small php framework that includes cms elements. Needed for creating small sites and web projects.
Basic goals:
- The main goal of the gy framework/cms project is to make a free, accessible to everyone, easy to learn, easy to implement and architecture tool for creating simple (small) sites.
- The created tool should be as simple as possible to learn and does not require any complex skills or knowledge from the developer using gy, just the basics of php are enough.
- The product should not be demanding on the platform (modules, dependencies, ideally without dependencies) and technical aspects of the server.
- The product should provide the easiest entry for a developer to the web, and ideally should allow ordinary people, with no development experience or with only little knowledge of php, to create sites.
- The product inside, the core (architecture, internal features) should be as simple as possible, and divided into simple parts, so that anyone can understand the architecture and make changes.
- The product should not restrict the developer by license or architecture, but should provide the ability to redefine/replace any part of the gy core, or override what is needed. Those. it should be possible to expand as simply as possible, up to a complete change without changing anything in the
/gy/section. - The product must include all the necessary components for creating a simple site, and also have the necessary settings in the administration panel to work with the site's content.
System requirements:
- php, you need to compile with the GD graphics library, tested on versions: 5.6, 7.0, 7.1, 7.2 .
-
Databases supported (tested):
- mySQL 5.6 ;
- MariaDB-10.3 ;
- PhpFileSql v0.2-alpha (https://github.com/ssv32/PhpFileSql) ;
- PostgreSQL 9.2 .
File weight: 350 Kb (with demo data).
Database weight: 208 Kb (with demo data).
Install gy php framework:
- You can install it with a php script from here - https://github.com/ssv32/install-gy-php-framework (there is a console and graphical script), or clone this repository;
- After installation, you need to configure the gy framework core, this can be done with a script
gy/install/consoleInstallOptions.php(or edited file/gy/config/gy_config.php); - Then you need to install the table into the database with a script
gy/install/installDataBaseTable.php(initial creation of the database and set access and its name in the step above); - Attention! When installing on linux, you need to set the rights to files and folders, so that the web user (apache or nginx) has the rights to execute php scripts, create files and folders in the project directory (this is necessary for the page constructor to work and switch the language in the admin panel, without rights it will not work).
After installation
- You can get to the admin panel from the browser like this
<домен вашего проекта>/gy/admin/(admin admin). - There is a demo site, you can install it with a console script
gy/install/installDemoSite1.php(Should be sent as the first parameterstart, examplephp -f gy/install/installDemoSite1.php start). - The demo site is needed for a small demonstration, it includes a directory
customDir, with an example of customizing a component template, sectionclasses(for custom classes or overriding classes gy), and the main page file index.php.
Documentation
There are wiki pages that show how to work with gy framework. (in terms of admin panel and explanation for developers) https://github.com/ssv32/gy/wiki or *documentation*
Features of the project
- Implemented / maintained standards PSR 0-4. (PSR-4 - not normal, read here https://github.com/ssv32/gy/wiki/16.-%D0%90%D0%B2%D1%82%D0%BE%D0%B7%D0%B0%D0%B3%D1%80%D1%83%D0%B7%D0%BA%D0%B0-%D0%BA%D0%BB%D0%B0%D1%81%D1%81%D0%BE%D0%B2-%7C-Class-autoloading) ;
- While project releases are marked as alpha versions, there is no backward support for framework gy (framework gy architecture is subject to change );
- TODO https://github.com/ssv32/gy/projects/1 ;
- Discussions - https://github.com/ssv32/gy/discussions ;
- Wiki description may be ahead of current release .
Example сonnection gy php framework
<?
include "./gy/gy.php"; // include core
Example of checking if the kernel is connected gy php framework
<?if ( !defined("GY_CORE") && (GY_CORE !== true) ) die( "gy: err include core" );?>
Example run component:
<?
include "./gy/gy.php"; // include core
// example run component
$app->component(
'form_auth',
'0',
array(
'test' => 'asd',
'idComponent' => 1,
),
);