PHP code example of mosaxiv / cakephp-mix
1. Go to this page and download the library: Download mosaxiv/cakephp-mix library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
mosaxiv / cakephp-mix example snippets
// src/View/AppView.php
namespace App\View;
use Cake\View\View;
class AppView extends View
{
public function initialize()
{
$this->loadHelper('CakeMix.Mix');
}
}
// /js/app.js
$this->Mix->script('app');
// <script src="/js/app.js"></script>
$this->Mix->htmlScript('app');
// /css/app.css
$this->Mix->css('app');
// <script src="/css/app.css"></script>
$this->Mix->htmlCss('app');