微擎框架模块加载

模块

数据库

modules_bindings  模块插件表
framework/model/wxapp.mod.php   wxapp_support_wxapp_modules()
MODULE_SUPPORT_WXAPP=2  不知道为啥

类路径:

weisrc_dish 

的控制器  和action 在

  D:php7wnmp ginxwwwwebyouzanaddonsweisrc_dishincweb里面;

如: http://www.timelyrains.com/web/index.php?c=site&a=entry&op=display&do=stores2&m=weisrc_dish

则:控制路径是: D:php7wnmp ginxwwwwebyouzanwebsourcesiteentry.ctrl.php 来判断是否有权限;

 配置文件位置  /data/config.php

url解析:

http://www.timelyrains.com/web/index.php?c=extension&a=module&do=designer

// extension 目录

// module.ctrl.php 文件

//designer 操作用      $do 因为:$do = $_GPC['do'];


url:生成

//http://we7.cc/web/index.php?c=site&a=entry&do=themeset&m=we7_demo
echo url(‘site/entry/themeset’, array(‘m’ => ‘we7_demo’));

此url不规范;

如模块中 主要识别是m参数

当传入 c=site a=entry时候 //http://we7.cc/web/index.php?c=site&a=entry&do=themeset&m=we7_demo

 路由到: /addons/we7_demo/site.php           D:php7wnmp ginxwwwwebyouzanwebsourcesite entry.ctrl.php   101行   $method = 'doWeb' . ucfirst($entry['do']);    

    文件的  doWebThemeset()

//http://we7.cc/web/index.php?i=1&j=2&do=list&m=we7_demo

  D:php7wnmp ginxwwwwebyouzanwebsourceentry site.ctrl.php

$site = WeUtility::createModuleSite($entry['module']);
if(!is_error($site)) {
$method = 'doMobile' . ucfirst($entry['do']);

路由到: /addons/we7_demo/site.php  文件的  doMobileList()

D:php7wnmp ginxwwwwebyouzanframeworkfunctionglobal.func.php 
function wurl()   function murl() 

模型即model类

    加载 用load() 函数

模板

  【web|app /themes/default/ 模板文件和controller,acton 对应】

原文地址:https://www.cnblogs.com/ldms/p/8309738.html