定制 mvccore/ext-router-media-localization 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

mvccore/ext-router-media-localization

Composer 安装命令:

composer require mvccore/ext-router-media-localization

包简介

MvcCore - Extension - Router - Media & Localization - extension to manage website media versions (full/tablet/mobile) for different templates/CSS/JS files rendering and to manage website localizations (language or language and locale), optionaly contained in url address in the beinning.

README 文档

README

Latest Stable Version License PHP Version

MvcCore Router extension to manage website media version (full/tablet/mobile) for different templates/css/js files rendering and to manage your website language (or language and locale) version optionaly contained in url address in the beinning.
This extension is mix of 2 extended router extensions:

This extension does the same things as extensions above together.

Installation

composer require mvccore/ext-router-media-localization

Features

Extension has the same features as extensions bellow together:

In URL addresses is always contained media site prefix first (before localization prefix) like this - example:

  • Full address for (default) locale en-US: `/en-US/any/path/with?query=string
  • Mobile address for different locale en-US: `/m/de-DE/ein/route/mit?abfragezeichen=folge

How It Works

Extension works in the same way as extensions named above, each task is executed
like for media extension first, then like for localization extension as second:

Only routing is implemented explicitly (it means method Route() in this router) and processing redirections and completing url addresses is implemented explicitly - to complete the proper URL string together with both query string values or with both prefixes.

Usage

Usage - Bootstrap Initialization

Add this to /App/Bootstrap.php or to very application beginning, before application routing or any other extension configuration using router for any purposes:

$app = \MvcCore\Application::GetInstance();
$app->SetRouterClass('\MvcCore\Ext\Routers\MediaAndLocalization');
...
// to get router instance for next configuration:
/** @var \MvcCore\Ext\Routers\MediaAndLocalization $router */
$router = \MvcCore\Router::GetInstance();

All other specific usage and advanced configuration is the same as extensions bellow together:

统计信息

  • 总下载量: 282
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 1
  • 点击次数: 1
  • 依赖项目数: 2
  • 推荐数: 0

GitHub 信息

  • Stars: 1
  • Watchers: 1
  • Forks: 1
  • 开发语言: PHP

其他信息

  • 授权协议: BSD-3-Clause
  • 更新时间: 2018-09-26

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固