Download the PHP package workofstan/mycms without Composer

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

MyCMS

Total Downloads Latest Stable Version Lint Code Base PHP Composer + PHPUnit + PHPStan

Brief MVC framework for interactive sites including general administration. This framework allows you to create an app just by simple configuration and keeping the framework up-to-date by composer while letting you use the vanilla PHP as much as possible. It works as a devstack which you install and then write your classes specific for your project. The boilerplate project is prepared in dist folder to be adapted as needed and it uses this WorkOfStan\MyCMS library out-of-the-box.

MyCMS is designed to be used with following technologies:

Installation

Apache modules mod_alias (for hiding non-public files) and mod_rewrite (for friendly URL features) are expected.

Once composer is installed, execute the following command in your project root to install this library:

Most of library's classes use prefix My. To develop your project, create your own classes as children inheriting MyCMS' classes in the ./classes/ directory and name them without the initial My in its name.

Files process.php and admin-process.php MUST exist as they process forms.

Note: $MyCMS name is expected by ProjectSpecific extends ProjectCommon class (@todo replace global $MyCMS by parameter handling)

Deployment

/dist

Folder /dist contains initial distribution files for a new project using MyCMS, therefore copy it to your new project folder in order to start easily. Replace the string MYCMSPROJECTNAMESPACE with your project namespace. (TODO: rector...) Replace the string MYCMSPROJECTSPECIFIC with other site specific information (Brand, Twitter address, phone number, database table_prefix in phinx.yml...). If you want to use your own table name prefix, please change the database related strings before first running ./build.sh.

To adapt the content and its structure either adapt migrations content_example before first running build or adapt the database content after running build or run build, see for yourself how it works, then adapt migrations, drop tables and run build again.

The table with users and hashed passwords is named TAB_PREFIX . 'admin'.

It is recommanded to adapt classes Contoller.php, FriendlyUrl.php and ProjectSpecific.php to your needs following the recommendations in comments. For deployment look also to Language management in dist/README.md.

MyCMS is used only as a library, so the project using it SHOULD implement RedirectMatch 404 vendor\/ statement as prepared in dist/.htaccess to keep the library hidden from web access.

Admin UI

Admin UI is displayed by MyAdmin::outputAdmin in this structure: Navigation Search
Agendas Main
Element overview: Navigation = SpecialMenuLinks + Media+User+Settings Search
Agendas (as in $AGENDAS in admin.php) Messages
Workspace: table/row/media/user/project-specific
Dashboard: List of tables

Navigation

Search

Agendas

Main

Admin notes

Database

Columns of tables displayed in admin can use various features set in the comment: comment feature
{"display":"html"} HTML editor Summernote
{"display":"layout-row"} ??
{"display":"option"} Existing values are offered in select box
{"display":"option","display-own":1} ... and an input box for adding previously unused values
{"display":"path"} ??
{"display":"texyla"} ?? Texyla editor
{"edit": "input"} zatím nic: todo: natáhnout string z prvního pole na stránce a webalize
{"edit":"json"} rozpadne interní json do příslušných polí --- ovšem pokud prázdné, je potřeba vložit JSON (proto je default '{}')
{"foreign-table":"category","foreign-column":"category_en"} odkaz do jiné tabulky ke snadnému výběru
{"foreign-table":"category","foreign-column":"category_en","foreign-path":"path"} ??
{"required":true} ??

TODO: active=0/1 display as on/off button

TODO: better explain.

clientSideResources

In class/Admin.php you can redefine the clientSideResources variable with resources to load to the admin. Its default is:

admin.css may be inherited to a child project, however as vendor folder SHOULD have denied access from browser, the content of that standard admin.css MUST be available through method MyAdmin::getAdminCss.

Testing

Run from a command line:

Note that dist folder contains the starting MyCMS based project deployment and testing runs through dist as well, so for development, the environment has to be set up for dist as well.

Note: running vendor/bin/phpunit from root will result in using MyCMS classes from the root Classes even from mycms/dist/Test. While running vendor/bin/phpunit from dist will result in using MyCMS classes from the dist/vendor/workofstan/mycms/classes.

GitHub actions' version of PHPUnit uses config file phpunit-github-actions.xml that ignores Distribution Test Suite because MySQLi environment isn't prepared (yet) and HTTP requests to self can't work in CLI only environment.

Reusing workflows

As dist/.github/workflows reuses some .github/workflows through workflow_call, it is imperative not to introduce ANY BREAKING CHANGES there. The reused workflow may be referenced by a branch, tag or commit and doesn't support Semantic Versioning.

Therefore, if a breaking change MUST be introduce, create another workflow to be reused instead of changing the existing one!

PHPStan

Till PHP<7.1 is supported, neither phpstan/phpstan-webmozart-assert nor rector/rector can't be required-dev in composer.json. Therefore, to properly take into account Assert statements by PHPStan (relevant for level>6), do a temporary (i.e. without commiting it to repository)

and use conf/phpstan.webmozart-assert.neon to allow for phpstan --configuration=conf/phpstan.webmozart-assert.neon analyse . --memory-limit 300M.

Prepared scripts ./phpstan.sh and ./phpstan-remove.sh can be used to start (or remove) the static analysis. (TODO: call the dist scripts from root to DRY.)

How does Friendly URL works within Controller

SEO settings details including language management in dist folder

TODO

TODO Administration

TODO Governance

TODO UI

TODO SECURITY


All versions of mycms with dependencies

PHP Build Version
Package Version
Requires php Version ^5.6 || ^7.0
latte/latte Version >=2.4.6 <2.11.3
tracy/tracy Version ^2.4.10
nette/utils Version ^2.4.8|^3.2.2
texy/texy Version ^2.7.1
godsdev/tools Version ^0.3.8
workofstan/backyard Version ^3.3.1
ext-session Version *
ext-mbstring Version *
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 workofstan/mycms contains the following files

Loading the files please wait ....