好!欢迎访问迷津渡口 现在时间是: 天气 °C ~ °C

迷津渡口

越感到迷惑 越接近真理

emlog MVC解构18--Model模型之Plugin_Model

模型Plugin_Model是开发插件必须了解的一个模型。

属性表:

属性注释
private $db内部数据库连接对象,用于存取插件数据库数据
private $plugin从本插件根目录到入口文件的路径字符串

方法表:

方法注释
function __construct()构造方法,新建内部数据库连接对象
function activePlugin($plugin)激活插件,更新Option配置,若文件存在,引用插件里面的'插件名_callback.php'文件,调用callback_init()函数,$plugin为从本插件根目录到入口文件的路径字符串,返回是否激活成功
function inactivePlugin($plugin)禁用插件,更新Option配置,若文件存在,引用插件里面的'插件名_callback.php',调用callback_rm()函数
function getPlugins()

获取所有插件列表,未定义插件名称的插件将不予获取

注意:返回全局变量$emPlugins为包含插件相关数据的数组

function getPluginData($pluginFile)

获取插件信息,$pluginFile是从本插件根目录开始到入口文件的路径字符串,返回包含插件信息的数组:

array(

  'Name' => 自定义插件名,

  'Version' => 插件版本,

  'Description' => 插件描述,

  'Url' => 插件说明页面网址,

  'Author' => 开发者,

  'ForEmlog' => 适用emlog版本,

  'AuthorUrl' => 开发者个人网站网址,

  'Setting' => true/false是否存在'插件名_setting.php'插件配置文件,

  'Plugin' => 插件根目录名,

)

注意定义时得这么做:

/*

Plugin Name:自定义插件名

Version:插件版本

Plugin URL:插件说明页面网址

Description:插件说明

ForEmlog:使用emlog版本

Author:开发者

Author URL:开发者个人网站网址

*/

定义时左右的空格将在获取时自动删除


点赞0
 标签: emlog mvc model plugin_model
   支持一下
挤眼 亲亲 咆哮 开心 想想 可怜 糗大了 委屈 哈哈 小声点 右哼哼 左哼哼 疑问 坏笑 赚钱啦 悲伤 耍酷 勾引 厉害 握手 耶 嘻嘻 害羞 鼓掌 馋嘴 抓狂 抱抱 围观 威武 给力
 点赞
 签到
 表情
 图片
 代码
提交评论

清空信息
关闭评论
playglenlakes
 playglenlakes 2019-05-22 01:07回复
#222
<a href="http://www.anjouevents.com/nike-hypershift-sort-hvid-jordan-skoe">nike hypershift sort hvid jordan</a> <a href="http://www.mtmcareers.com/womens-nike-baltimore-ravens-5-game-pink-new-be-luvd-nfl-jersey-nflh">womens nike baltimore ravens 5 game pink new be luvd nfl jersey</a> <a href="http://www.anticlimaxes.com/mens-dallas-cowboys-dez-bryant-nike-color-rush-limited-jersey-nfli">mens dallas cowboys dez bryant nike color rush limited jersey</a> <a href="http://www.elazigled.com/justin-houston-elite-jersey-nflh">justin houston elite jersey</a> <a href="http://www.wavestarters.com/nike-dunk-ni%C3%B1os-zapatos-naranja-azul-shoese">nike dunk ni帽os zapatos naranja azul</a> <a href="http://www.neweghani.com/sweater-over-polo-shirt-poloh">sweater over polo shirt</a>
[url=http://www.playglenlakes.com/]playglenlakes[/url]
thebiarritz
 thebiarritz 2019-05-22 00:32回复
#221
<a href="http://www.thebiarritz.com/air-yeezy-ii-2-sp-max-90-womens-pink-orange-shoesk">air yeezy ii 2 sp max 90 womens pink orange</a> <a href="http://www.voydnet.com/kvinners-nike-zoom-structure-18-hvit-r%C3%B8d-obuvq">kvinners nike zoom structure 18 hvit r酶d</a> <a href="http://www.foneandlone.com/adidas-neo-campus-lilla-r%C3%B8d-skoj">adidas neo campus lilla r酶d</a> <a href="http://www.roomwhiz.com/nike-roshe-two-bianca-blu-scarpeq">nike roshe two bianca blu</a> <a href="http://www.riffsurfers.com/womens-nike-free-run-3-gold-black-shoesj">womens nike free run 3 gold black</a> <a href="http://www.davidmgaines.com/nike-flyknit-lunar-wolf-gr%C3%A5-laser-appelsin-skop">nike flyknit lunar wolf gr氓 laser appelsin</a>
thebiarritz http://www.thebiarritz.com/
stumptowninfo
 stumptowninfo 2019-05-21 18:51回复
#220
<a href="http://www.bluesophy.com/air-jordan-13-retro-low-blanc-mettoutic-argent-eyes-schuhee">air jordan 13 retro low blanc mettoutic argent eyes</a> <a href="http://www.stylehousestl.com/nike-air-max-90-gs-hyper-bl%C3%A5-foote">nike air max 90 gs hyper bl氓</a> <a href="http://www.byvergara.com/nike-air-pegasus-92-lyser%C3%B8d-s%C3%B8lv-skof">nike air pegasus 92 lyser酶d s酶lv</a> <a href="http://www.ruthlesscrew.com/kevin-love-sleeved-jersey-nflh">kevin love sleeved jersey</a> <a href="http://www.fullserviceap.com/buy-jj-watt-jersey-nfli">buy jj watt jersey</a> <a href="http://www.idealkizlar.com/mens-new-york-rangers-henrik-lundqvist-reebok-navy-blue-alternate-premier-jersey-nflh">mens new york rangers henrik lundqvist reebok navy blue alternate premier jersey</a>
stumptowninfo http://www.stumptowninfo.com/
egyptmaritime
 egyptmaritime 2019-05-21 18:36回复
#219
<a href="http://www.jupickuplines.com/ua-micro-g-torch-gull-oransje-obuvi">ua micro g torch gull oransje</a> <a href="http://www.saleuggboot.com/nike-lebron-ambassador-9-lilla-gull-obuvp">nike lebron ambassador 9 lilla gull</a> <a href="http://www.fragmanizletv.com/adidas-tubular-runner-gr%C3%B8nn-gull-obuvi">adidas tubular runner gr酶nn gull</a> <a href="http://www.swisshomeas.com/nike-shox-turbo-21-rojo-azul-zapatosp">nike shox turbo 21 rojo azul</a> <a href="http://www.marinersdiary.com/coach-poppy-phone-wristlet-available-at-nordstrom-coachh">coach poppy phone wristlet available at nordstrom</a> <a href="http://www.bourseasie.com/nike-kobe-6-silver-sky-blue-shoesj">nike kobe 6 silver sky blue</a>
egyptmaritime http://www.egyptmaritime.com/
flushandhunt
 flushandhunt 2019-05-21 12:34回复
#218
<a href="http://www.mwartsdrama.com/coach-logo-black-wedges-coachh">coach logo black wedges</a> <a href="http://www.meshmotors.com/mens-nike-roshe-run-slip-black-red-shoesj">mens nike roshe run slip black red</a> <a href="http://www.aspenmedisys.com/air-jordan-retro-7-lyser%C3%B8d-s%C3%B8lv-skol">air jordan retro 7 lyser酶d s酶lv</a> <a href="http://www.smartiesland.com/air-jordan-retro-9-bleu-violet-chaussuresq">air jordan retro 9 bleu violet</a> <a href="http://www.emcetolerie.com/kobe-11-4kb-noir-horse-chaussuresl">kobe 11 4kb noir horse</a> <a href="http://www.lapaktoko.com/dam%C3%A4nner-nike-air-max-95-blau-wei%C3%9F-schuhei">dam盲nner nike air max 95 blau wei脽</a>
flushandhunt http://www.flushandhunt.com/
hozloli
 hozloli 2019-05-21 04:50回复
#217
<a href="http://www.xescortx.com/nike-magista-onda-arancia-scarpej">nike magista onda arancia</a> <a href="http://www.naturabottega.com/femminile-nike-air-max-270-blu-scarpei">femminile nike air max 270 blu</a> <a href="http://www.peddlir.com/nikki-bella-wwe-classic-clean-up-cap-hath">nikki bella wwe classic clean up cap</a> <a href="http://www.snowdaydc.com/neon-rose-nike-air-max-chaussuresh">neon rose nike air max</a> <a href="http://www.alliesindex.com/nike-lunarglide-7-rouge-gris-chaussuresj">nike lunarglide 7 rouge gris</a> <a href="http://www.cafekem.com/converse-chuck-taylor-alle-star-classic-wei%C3%9F-schuhek">converse chuck taylor alle star classic wei脽</a>
hozloli http://www.hozloli.com/
justprogaming
 justprogaming 2019-05-20 13:25回复
#216
<a href="http://www.delicouncil.com/adidas-eqt-support-93-classic-noir-chaussuresj">adidas eqt support 93 classic noir</a> <a href="http://www.jeffaudette.com/m%C3%A4nner-kevin-durant-7-rot-grau-schwarz-schuhek">m盲nner kevin durant 7 rot grau schwarz</a> <a href="http://www.ezappspro.com/2014-world-cup-croatia-10-modric-away-soccer-shirt-kit-nflh">2014 world cup croatia 10 modric away soccer shirt kit</a> <a href="http://www.susannekober.com/adidas-ultra-boost-uncaged-hvit-mennns-obuvi">adidas ultra boost uncaged hvit mennns</a> <a href="http://www.kingsroomlv.com/nike-id-solar-red-air-max-90-hyperfuse-shoesj">nike id solar red air max 90 hyperfuse</a> <a href="http://www.sadecemerak.com/men-asics-gel-noosa-tri-8-gs-black-orange-confetti-shoesl">men asics gel noosa tri 8 gs black orange confetti</a>
justprogaming http://www.justprogaming.com/
coach mini wristlet
 coach mini wristlet 2019-05-19 18:00回复
#215
<a href="http://www.htpmimoza.com/san-jose-sharks-premier-jersey-nflh">san jose sharks premier jersey</a> <a href="http://www.ayakkabiyeri.com/kvinners-nike-tanjun-svart-and-hvit-obuvi">kvinners nike tanjun svart and hvit</a> <a href="http://www.sozoteki.com/nike-air-force-1-black-black-sail-820266-017-shoesj">nike air force 1 black black sail 820266 017</a> <a href="http://www.njforward.com/nike-tiempo-legend-v-green-shoesl">nike tiempo legend v green</a> <a href="http://www.crimediainc.com/ralph-lauren-crew-sweater-poloh">ralph lauren crew sweater</a> <a href="http://www.claybrookpenn.com/air-jordan-retro-13-hvid-gr%C3%A5-r%C3%B8d-skok">air jordan retro 13 hvid gr氓 r酶d</a>
coach mini wristlet http://www.claybrookpenn.com/coach-mini-wristlet-coachh
chatgroupies
 chatgroupies 2019-05-19 11:30回复
#214
<a href="http://www.htpmimoza.com/nike-free-run-2-frau-schwarz-rot-schuhek">nike free run 2 frau schwarz rot</a> <a href="http://www.ayakkabiyeri.com/toronto-raptors-white-jersey-nflh">toronto raptors white jersey</a> <a href="http://www.sozoteki.com/converse-sko-svart-l%C3%A6r-high-tops-obuvi">converse sko svart l忙r high tops</a> <a href="http://www.njforward.com/mens-adidas-stan-smith-white-shoesj">mens adidas stan smith white</a> <a href="http://www.crimediainc.com/nike-lunarglide-5-purple-shoesl">nike lunarglide 5 purple</a> <a href="http://www.claybrookpenn.com/royal-blue-polo-shirts-long-sleeve-poloh">royal blue polo shirts long sleeve</a>
chatgroupies http://www.chatgroupies.com/
nowaitnails
 nowaitnails 2019-05-18 08:41回复
#213
<a href="http://www.profancyshop.com/mennns-asics-gel-lyte-5-gr%C3%B8nn-rosa-obuvj">mennns asics gel lyte 5 gr酶nn rosa</a> <a href="http://www.lmcgroep.com/femminile-nike-roshe-run-floreale-gituttio-blu-scarpep">femminile nike roshe run floreale gituttio blu</a> <a href="http://www.nowaitnails.com/nike-kobe-11-femmes-rouge-bleu-ciel-chaussuresh">nike kobe 11 femmes rouge bleu ciel</a> <a href="http://www.xmrujo.com/prada-mini-saffiano-camera-crossbody-bag-pradah">prada mini saffiano camera crossbody bag</a> <a href="http://www.sevenguard.com/buster-posey-orange-jersey-nfli">buster posey orange jersey</a> <a href="http://www.escortsue.com/nike-air-max-ltd-wolf-gr%C3%A5-hvid-skoq">nike air max ltd wolf gr氓 hvid</a>
nowaitnails http://www.nowaitnails.com/
顶部留言底部
 00:00/00:00
我想和你虚度时光 - 花房姑娘(9)
  1. 我想和你虚度时光
  2. 花房姑娘
  3. 恋恋风尘
  4. 我喜爱一切不彻底的事物
  5. 我的心里是满的
  6. Long Way
  7. 给少年的歌
  8. 晴日共剪窗
  9. 天上的月你的脸