Toggle navigation
Toggle navigation
This project
Loading...
Sign in
fe
/
YOHOBUYWAP
·
Commits
Go to a project
GitLab
Go to group
Project
Activity
Files
Commits
Pipelines
0
Builds
0
Graphs
Milestones
Issues
0
Merge Requests
0
Members
Labels
Wiki
Forks
Network
Create a new issue
Download as
Email Patches
Plain Diff
Browse Files
Authored by
hf
10 years ago
Commit
a916f96741413e3aec9520354946d0ae43976d2c
1 parent
e46ac678
do add models to package template data clear controller
Hide whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
249 additions
and
207 deletions
library/Plugin/Cache.php
yohobuy/m.yohobuy.com/application/controllers/Boys.php
yohobuy/m.yohobuy.com/application/controllers/Girls.php
yohobuy/m.yohobuy.com/application/controllers/Index.php
yohobuy/m.yohobuy.com/application/controllers/Kids.php
yohobuy/m.yohobuy.com/application/controllers/Lifestyle.php
yohobuy/m.yohobuy.com/application/models/Index/Home.php
yohobuy/m.yohobuy.com/application/models/index/IndexModel.php
yohobuy/m.yohobuy.com/public/index-dev.php
yohobuy/m.yohobuy.com/public/index-test.php
yohobuy/m.yohobuy.com/public/index.php
library/Plugin/Cache.php
View file @
a916f96
...
...
@@ -33,7 +33,7 @@ class Cache
* @param int $expire 缓存有效期(单位秒, 0表示永久)
* @return void
*/
public
static
function
set
(
$key
,
$value
,
$expire
=
360
0
)
public
static
function
set
(
$key
,
$value
,
$expire
=
0
)
{
try
{
// WINDOWS
...
...
yohobuy/m.yohobuy.com/application/controllers/Boys.php
View file @
a916f96
<?php
use
Action\AbstractAction
;
use
LibModels\Wap\Home\IndexData
;
use
Plugin\DataProcess\FloorProcess
;
use
Configs\CacheConfig
;
/**
* 男生首页
...
...
@@ -11,13 +8,6 @@ use Configs\CacheConfig;
class
BoysController
extends
AbstractAction
{
// 数据缓存时间
const
DATA_EXPIRE
=
3600
;
// 楼层资源的位置码
const
CODE_FLOOR
=
'8512bf0755cc549ac323f852c9fd945d'
;
// 底部广告的位置码
const
CODE_BOTTOM_BANNER
=
'a2ec977c027d0cd9cdccb356ddf16b08'
;
/**
* 男生首页
*/
...
...
@@ -30,35 +20,13 @@ class BoysController extends AbstractAction
// 设置顶部信息(搜索)
$this
->
setHomeChannelHeader
();
$data
=
array
();
$data
[
'boysHomePage'
]
=
true
;
$data
[
'maybeLike'
]
=
true
;
do
{
// 先尝试获取一级缓存(master), 有数据则直接返回.
$data
[
'content'
]
=
$this
->
getCache
(
CacheConfig
::
KEY_ACTION_BOYS_INDEX
,
true
);
if
(
!
empty
(
$data
[
'content'
]))
{
break
;
}
// 调用接口获取楼层数据, 并封装成模板渲染需要的数据格式
$channelData
=
IndexData
::
getResourceData
(
'1,3'
,
self
::
CODE_FLOOR
);
if
(
isset
(
$channelData
[
'code'
])
&&
$channelData
[
'code'
]
==
200
)
{
$data
[
'content'
]
=
FloorProcess
::
getContent
(
$channelData
[
'data'
]);
}
// 接口调用正常,数据封装完成, 则设置一级(master)和二级(slave)数据缓存
if
(
!
empty
(
$data
[
'content'
]))
{
$this
->
setCache
(
CacheConfig
::
KEY_ACTION_BOYS_INDEX
,
$data
[
'content'
],
self
::
DATA_EXPIRE
);
// 缓存1小时
break
;
}
// 接口调用异常时, 不害怕,从我们的二级缓存(slave)里再取数据.
$data
[
'content'
]
=
$this
->
getCache
(
CacheConfig
::
KEY_ACTION_BOYS_INDEX
,
false
);
}
while
(
false
);
$this
->
_view
->
display
(
'index'
,
$data
);
// 渲染模板并输出
$this
->
_view
->
display
(
'index'
,
array
(
'boysHomePage'
=>
true
,
'maybeLike'
=>
true
,
'content'
=>
Index\HomeModel
::
getBoysFloor
()
));
}
}
...
...
yohobuy/m.yohobuy.com/application/controllers/Girls.php
View file @
a916f96
<?php
use
Action\AbstractAction
;
use
LibModels\Wap\Home\IndexData
;
use
Plugin\DataProcess\FloorProcess
;
use
Configs\CacheConfig
;
/**
* 女生首页
...
...
@@ -11,13 +8,6 @@ use Configs\CacheConfig;
class
GirlsController
extends
AbstractAction
{
// 数据缓存时间
const
DATA_EXPIRE
=
3600
;
// 楼层资源的位置码
const
CODE_FLOOR
=
'189b6686065dbd6755dd6906cf03c002'
;
// 底部广告的位置码
const
CODE_BOTTOM_BANNER
=
'8c8bd1b89a22e5895f05882e0825b493'
;
/**
* 女生首页
*/
...
...
@@ -30,35 +20,13 @@ class GirlsController extends AbstractAction
// 设置顶部信息(搜索)
$this
->
setHomeChannelHeader
();
$data
=
array
();
$data
[
'grilsHomePage'
]
=
true
;
$data
[
'maybeLike'
]
=
true
;
do
{
// 先尝试获取一级缓存(master), 有数据则直接返回.
$data
[
'content'
]
=
$this
->
getCache
(
CacheConfig
::
KEY_ACTION_GIRLS_INDEX
,
true
);
if
(
!
empty
(
$data
[
'content'
]))
{
break
;
}
// 调用接口获取楼层数据, 并封装成模板渲染需要的数据格式
$channelData
=
IndexData
::
getResourceData
(
'2,3'
,
self
::
CODE_FLOOR
);
if
(
isset
(
$channelData
[
'code'
])
&&
$channelData
[
'code'
]
==
200
)
{
$data
[
'content'
]
=
FloorProcess
::
getContent
(
$channelData
[
'data'
]);
}
// 接口调用正常,数据封装完成, 则设置一级(master)和二级(slave)数据缓存
if
(
!
empty
(
$data
[
'content'
]))
{
$this
->
setCache
(
CacheConfig
::
KEY_ACTION_GIRLS_INDEX
,
$data
[
'content'
],
self
::
DATA_EXPIRE
);
// 缓存1小时
break
;
}
// 接口调用异常时, 不害怕,从我们的二级缓存(slave)里再取数据.
$data
[
'content'
]
=
$this
->
getCache
(
CacheConfig
::
KEY_ACTION_GIRLS_INDEX
,
false
);
}
while
(
false
);
$this
->
_view
->
display
(
'index'
,
$data
);
// 渲染模板并输出
$this
->
_view
->
display
(
'index'
,
array
(
'grilsHomePage'
=>
true
,
'maybeLike'
=>
true
,
'content'
=>
Index\HomeModel
::
getGirlsFloor
()
));
}
}
...
...
yohobuy/m.yohobuy.com/application/controllers/Index.php
View file @
a916f96
<?php
use
Action\AbstractAction
;
use
LibModels\Wap\Home\IndexData
;
use
Plugin\Helpers
;
/**
* 频道选择
*/
class
IndexController
extends
AbstractAction
{
const
CODE_BANNER
=
'7ba9118028f9b22090b57341487567eb'
;
/**
*
启动首页频道选择
*
频道选择页
*/
public
function
indexAction
()
{
$data
=
array
(
'background'
=>
''
,
);
// 背景图获取
$banner
=
IndexData
::
getBannerStart
(
self
::
CODE_BANNER
);
if
(
isset
(
$banner
[
'data'
][
0
][
'data'
][
'list'
][
0
][
'src'
]))
{
$data
[
'background'
]
=
Helpers
::
getImageUrl
(
$banner
[
'data'
][
0
][
'data'
][
'list'
][
0
][
'src'
],
640
,
800
,
1
);
}
$banner
=
array
();
// 渲染模板
$this
->
_view
->
display
(
'index'
,
$data
);
$this
->
_view
->
display
(
'index'
,
array
(
'background'
=>
Index\HomeModel
::
getBgImage
()
));
}
}
...
...
yohobuy/m.yohobuy.com/application/controllers/Kids.php
View file @
a916f96
<?php
use
Action\AbstractAction
;
use
LibModels\Wap\Home\IndexData
;
use
Plugin\DataProcess\FloorProcess
;
use
Configs\CacheConfig
;
/**
* 儿童首页
*/
class
KidsController
extends
AbstractAction
{
// 数据缓存时间
const
DATA_EXPIRE
=
3600
;
// 楼层资源的位置码
const
CODE_FLOOR
=
'b8c1bff53d4ea60f978926d538620636'
;
// '66cad79d93e055ad6fc5c8744086066d';
/**
* 潮童首页
...
...
@@ -27,35 +20,13 @@ class KidsController extends AbstractAction
// 设置顶部信息(搜索)
$this
->
setHomeChannelHeader
();
$data
=
array
();
$data
[
'kidsHomePage'
]
=
true
;
$data
[
'maybeLike'
]
=
true
;
do
{
// 先尝试获取一级缓存(master), 有数据则直接返回.
$data
[
'content'
]
=
$this
->
getCache
(
CacheConfig
::
KEY_ACTION_KIDS_INDEX
,
true
);
if
(
!
empty
(
$data
[
'content'
]))
{
break
;
}
// 调用接口获取楼层数据, 并封装成模板渲染需要的数据格式
$channelData
=
IndexData
::
getResourceData
(
''
,
self
::
CODE_FLOOR
);
if
(
isset
(
$channelData
[
'code'
])
&&
$channelData
[
'code'
]
==
200
)
{
$data
[
'content'
]
=
FloorProcess
::
getContent
(
$channelData
[
'data'
],
3
);
}
// 接口调用正常,数据封装完成, 则设置一级(master)和二级(slave)数据缓存
if
(
!
empty
(
$data
[
'content'
]))
{
$this
->
setCache
(
CacheConfig
::
KEY_ACTION_KIDS_INDEX
,
$data
[
'content'
],
self
::
DATA_EXPIRE
);
// 缓存1小时
break
;
}
// 接口调用异常时, 不害怕,从我们的二级缓存(slave)里再取数据.
$data
[
'content'
]
=
$this
->
getCache
(
CacheConfig
::
KEY_ACTION_KIDS_INDEX
,
false
);
}
while
(
false
);
$this
->
_view
->
display
(
'index'
,
$data
);
// 渲染模板并输出
$this
->
_view
->
display
(
'index'
,
array
(
'kidsHomePage'
=>
true
,
'maybeLike'
=>
true
,
'content'
=>
Index\HomeModel
::
getKidsFloor
()
));
}
}
...
...
yohobuy/m.yohobuy.com/application/controllers/Lifestyle.php
View file @
a916f96
<?php
use
Action\AbstractAction
;
use
LibModels\Wap\Home\IndexData
;
use
Plugin\DataProcess\FloorProcess
;
use
Configs\CacheConfig
;
/**
* 创意生活首页
...
...
@@ -11,11 +8,6 @@ use Configs\CacheConfig;
class
LifestyleController
extends
AbstractAction
{
// 数据缓存时间
const
DATA_EXPIRE
=
3600
;
// 楼层资源的位置码
const
CODE_FLOOR
=
'61cd852c6afcf60660196154f66a3a62'
;
/**
* 创意生活首页
*/
...
...
@@ -28,35 +20,13 @@ class LifestyleController extends AbstractAction
// 设置顶部信息(搜索)
$this
->
setHomeChannelHeader
();
$data
=
array
();
$data
[
'lifestyleHomePage'
]
=
true
;
$data
[
'maybeLike'
]
=
true
;
do
{
// 先尝试获取一级缓存(master), 有数据则直接返回.
$data
[
'content'
]
=
$this
->
getCache
(
CacheConfig
::
KEY_ACTION_LIFESTYLE_INDEX
,
true
);
if
(
!
empty
(
$data
[
'content'
]))
{
break
;
}
// 调用接口获取楼层数据, 并封装成模板渲染需要的数据格式
$channelData
=
IndexData
::
getResourceData
(
''
,
'61cd852c6afcf60660196154f66a3a62'
);
if
(
isset
(
$channelData
[
'code'
])
&&
$channelData
[
'code'
]
==
200
)
{
$data
[
'content'
]
=
FloorProcess
::
getContent
(
$channelData
[
'data'
],
4
);
}
// 接口调用正常,数据封装完成, 则设置一级(master)和二级(slave)数据缓存
if
(
!
empty
(
$data
[
'content'
]))
{
$this
->
setCache
(
CacheConfig
::
KEY_ACTION_LIFESTYLE_INDEX
,
$data
[
'content'
],
self
::
DATA_EXPIRE
);
// 缓存1小时
break
;
}
// 接口调用异常时, 不害怕,从我们的二级缓存(slave)里再取数据.
$data
[
'content'
]
=
$this
->
getCache
(
CacheConfig
::
KEY_ACTION_LIFESTYLE_INDEX
,
false
);
}
while
(
false
);
$this
->
_view
->
display
(
'index'
,
$data
);
// 渲染模板并输出
$this
->
_view
->
display
(
'index'
,
array
(
'lifestyleHomePage'
=>
true
,
'maybeLike'
=>
true
,
'content'
=>
Index\HomeModel
::
getLifestyleFloor
()
));
}
}
...
...
yohobuy/m.yohobuy.com/application/models/Index/Home.php
0 → 100644
View file @
a916f96
<?php
namespace
Index
;
use
LibModels\Wap\Home\IndexData
;
use
Plugin\Helpers
;
use
Plugin\Cache
;
use
Plugin\DataProcess\FloorProcess
;
use
Configs\CacheConfig
;
/**
* 首页相关的模板数据模型
*
* @name HomeModel
* @package models
* @copyright yoho.inc
* @version 1.0 (2015-10-21 11:08:21)
* @author fei.hong <fei.hong@yoho.cn>
*/
class
HomeModel
{
/* 频道选择页取背景图片的位置码 */
const
CODE_BG
=
'7ba9118028f9b22090b57341487567eb'
;
/* 男生楼层资源的位置码 */
const
CODE_FLOOR_BOYS
=
'8512bf0755cc549ac323f852c9fd945d'
;
/* 女生楼层资源的位置码 */
const
CODE_FLOOR_GIRLS
=
'189b6686065dbd6755dd6906cf03c002'
;
/* 潮童楼层资源的位置码 */
const
CODE_FLOOR_KIDS
=
'66cad79d93e055ad6fc5c8744086066d'
;
// 'b8c1bff53d4ea60f978926d538620636';
/* 创意生活楼层资源的位置码 */
const
CODE_FLOOR_LIFESTYLE
=
'61cd852c6afcf60660196154f66a3a62'
;
/* 男生底部广告的位置码 */
const
CODE_BANNER_BOTTOM_BOYS
=
'a2ec977c027d0cd9cdccb356ddf16b08'
;
/* 女生底部广告的位置码 */
const
CODE_BANNER_BOTTOM_GIRLS
=
'8c8bd1b89a22e5895f05882e0825b493'
;
/**
* 获取频道选择页的背景图片
*
* @return string | false
*/
public
static
function
getBgImage
()
{
if
(
USE_CACHE
)
{
// 先尝试获取一级缓存(master), 有数据则直接返回.
$result
=
Cache
::
get
(
CacheConfig
::
KEY_ACTION_INDEX_INDEX
,
'master'
);
if
(
!
empty
(
$result
))
{
return
$result
;
}
}
// 调用接口获取数据
$banner
=
IndexData
::
getBannerStart
(
self
::
CODE_BG
);
if
(
isset
(
$banner
[
'data'
][
0
][
'data'
][
'list'
][
0
][
'src'
]))
{
$result
=
Helpers
::
getImageUrl
(
$banner
[
'data'
][
0
][
'data'
][
'list'
][
0
][
'src'
],
640
,
800
,
1
);
}
else
{
$result
=
false
;
}
if
(
USE_CACHE
)
{
// 接口调用异常时, 不害怕,从我们的二级缓存(slave)里再取数据.
if
(
empty
(
$result
))
{
$result
=
Cache
::
get
(
CacheConfig
::
KEY_ACTION_INDEX_INDEX
,
'slave'
);
}
// 接口调用正常,数据封装完成, 则设置一级(master)和二级(slave)数据缓存
else
{
Cache
::
set
(
CacheConfig
::
KEY_ACTION_INDEX_INDEX
,
$result
);
}
}
return
$result
;
}
/**
* 获取男生首页的楼层数据
*/
public
static
function
getBoysFloor
()
{
if
(
USE_CACHE
)
{
// 先尝试获取一级缓存(master), 有数据则直接返回.
$result
=
Cache
::
get
(
CacheConfig
::
KEY_ACTION_BOYS_INDEX
,
'master'
);
if
(
!
empty
(
$result
))
{
return
$result
;
}
}
// 调用接口获取楼层数据, 并封装成模板渲染需要的数据格式
$channelData
=
IndexData
::
getResourceData
(
'1,3'
,
self
::
CODE_FLOOR_BOYS
);
if
(
isset
(
$channelData
[
'code'
])
&&
$channelData
[
'code'
]
==
200
)
{
$result
=
FloorProcess
::
getContent
(
$channelData
[
'data'
]);
}
if
(
USE_CACHE
)
{
// 接口调用异常时, 不害怕,从我们的二级缓存(slave)里再取数据.
if
(
empty
(
$result
))
{
$result
=
Cache
::
get
(
CacheConfig
::
KEY_ACTION_BOYS_INDEX
,
'slave'
);
}
// 接口调用正常,数据封装完成, 则设置一级(master)和二级(slave)数据缓存
else
{
Cache
::
set
(
CacheConfig
::
KEY_ACTION_BOYS_INDEX
,
$result
);
}
}
return
$result
;
}
/**
* 获取女生首页的楼层数据
*/
public
static
function
getGirlsFloor
()
{
if
(
USE_CACHE
)
{
// 先尝试获取一级缓存(master), 有数据则直接返回.
$result
=
Cache
::
get
(
CacheConfig
::
KEY_ACTION_GIRLS_INDEX
,
'master'
);
if
(
!
empty
(
$result
))
{
return
$result
;
}
}
// 调用接口获取楼层数据, 并封装成模板渲染需要的数据格式
$channelData
=
IndexData
::
getResourceData
(
'2,3'
,
self
::
CODE_FLOOR_GIRLS
);
if
(
isset
(
$channelData
[
'code'
])
&&
$channelData
[
'code'
]
==
200
)
{
$result
=
FloorProcess
::
getContent
(
$channelData
[
'data'
]);
}
if
(
USE_CACHE
)
{
// 接口调用异常时, 不害怕,从我们的二级缓存(slave)里再取数据.
if
(
empty
(
$result
))
{
$result
=
Cache
::
get
(
CacheConfig
::
KEY_ACTION_GIRLS_INDEX
,
'slave'
);
}
// 接口调用正常,数据封装完成, 则设置一级(master)和二级(slave)数据缓存
else
{
Cache
::
set
(
CacheConfig
::
KEY_ACTION_GIRLS_INDEX
,
$result
);
}
}
return
$result
;
}
/**
* 获取潮童首页的楼层数据
*/
public
static
function
getKidsFloor
()
{
if
(
USE_CACHE
)
{
// 先尝试获取一级缓存(master), 有数据则直接返回.
$result
=
Cache
::
get
(
CacheConfig
::
KEY_ACTION_KIDS_INDEX
,
'master'
);
if
(
!
empty
(
$result
))
{
return
$result
;
}
}
// 调用接口获取楼层数据, 并封装成模板渲染需要的数据格式
$channelData
=
IndexData
::
getResourceData
(
''
,
self
::
CODE_FLOOR_KIDS
);
if
(
isset
(
$channelData
[
'code'
])
&&
$channelData
[
'code'
]
==
200
)
{
$result
=
FloorProcess
::
getContent
(
$channelData
[
'data'
],
3
);
}
if
(
USE_CACHE
)
{
// 接口调用异常时, 不害怕,从我们的二级缓存(slave)里再取数据.
if
(
empty
(
$result
))
{
$result
=
Cache
::
get
(
CacheConfig
::
KEY_ACTION_KIDS_INDEX
,
'slave'
);
}
// 接口调用正常,数据封装完成, 则设置一级(master)和二级(slave)数据缓存
else
{
Cache
::
set
(
CacheConfig
::
KEY_ACTION_KIDS_INDEX
,
$result
);
}
}
return
$result
;
}
/**
* 获取创意生活首页的楼层数据
*/
public
static
function
getLifestyleFloor
()
{
if
(
USE_CACHE
)
{
// 先尝试获取一级缓存(master), 有数据则直接返回.
$result
=
Cache
::
get
(
CacheConfig
::
KEY_ACTION_LIFESTYLE_INDEX
,
'master'
);
if
(
!
empty
(
$result
))
{
return
$result
;
}
}
// 调用接口获取楼层数据, 并封装成模板渲染需要的数据格式
$channelData
=
IndexData
::
getResourceData
(
''
,
self
::
CODE_FLOOR_LIFESTYLE
);
if
(
isset
(
$channelData
[
'code'
])
&&
$channelData
[
'code'
]
==
200
)
{
$result
=
FloorProcess
::
getContent
(
$channelData
[
'data'
],
4
);
}
if
(
USE_CACHE
)
{
// 接口调用异常时, 不害怕,从我们的二级缓存(slave)里再取数据.
if
(
empty
(
$result
))
{
$result
=
Cache
::
get
(
CacheConfig
::
KEY_ACTION_LIFESTYLE_INDEX
,
'slave'
);
}
// 接口调用正常,数据封装完成, 则设置一级(master)和二级(slave)数据缓存
else
{
Cache
::
set
(
CacheConfig
::
KEY_ACTION_LIFESTYLE_INDEX
,
$result
);
}
}
return
$result
;
}
}
...
...
yohobuy/m.yohobuy.com/application/models/index/IndexModel.php
deleted
100644 → 0
View file @
e46ac67
<?php
use
LibModels\Wap\Home\IndexData
;
use
Plugin\Helpers
;
/**
* 首页相关的模板数据模型
*
* @author fei.hong
*/
class
IndexModel
{
/* 频道选择页取背景图片的位置码 */
const
CODE_BG
=
'7ba9118028f9b22090b57341487567eb'
;
/**
* 获取频道选择页的背景图片
*
* @return string | false
*/
public
static
function
getBgImage
()
{
$banner
=
IndexData
::
getBannerStart
(
self
::
CODE_BG
);
if
(
isset
(
$banner
[
'data'
][
0
][
'data'
][
'list'
][
0
][
'src'
]))
{
$result
=
Helpers
::
getImageUrl
(
$banner
[
'data'
][
0
][
'data'
][
'list'
][
0
][
'src'
],
640
,
800
,
1
);
}
else
{
$result
=
false
;
}
return
$result
;
}
}
yohobuy/m.yohobuy.com/public/index-dev.php
View file @
a916f96
<?php
use
Yaf\Application
;
define
(
'DOMAIN'
,
'm.dev.yohobuy.com'
);
define
(
'SITE_DOMAIN'
,
'm.dev.yohobuy.com'
);
// 网站主域名
define
(
'USE_CACHE'
,
false
);
// 缓存的开关
define
(
'APPLICATION_PATH'
,
dirname
(
__DIR__
));
define
(
'ROOT_PATH'
,
dirname
(
dirname
(
APPLICATION_PATH
)));
defined
(
'APPLICATION_ENV'
)
||
define
(
'APPLICATION_ENV'
,
'developer'
);
...
...
yohobuy/m.yohobuy.com/public/index-test.php
View file @
a916f96
<?php
use
Yaf\Application
;
define
(
'DOMAIN'
,
'buy.test.yoho.cn'
);
define
(
'SITE_DOMAIN'
,
'buy.test.yoho.cn'
);
// 网站主域名
define
(
'USE_CACHE'
,
true
);
// 缓存的开关
define
(
'APPLICATION_PATH'
,
dirname
(
__DIR__
));
define
(
'ROOT_PATH'
,
dirname
(
dirname
(
APPLICATION_PATH
)));
defined
(
'APPLICATION_ENV'
)
||
define
(
'APPLICATION_ENV'
,
'testing'
);
...
...
yohobuy/m.yohobuy.com/public/index.php
View file @
a916f96
<?php
use
Yaf\Application
;
define
(
'DOMAIN'
,
'wap.yohobuy.com'
);
define
(
'SITE_DOMAIN'
,
'wap.yohobuy.com'
);
// 网站主域名
define
(
'USE_CACHE'
,
true
);
// 缓存的开关
define
(
'APPLICATION_PATH'
,
dirname
(
__DIR__
));
define
(
'ROOT_PATH'
,
dirname
(
dirname
(
APPLICATION_PATH
)));
defined
(
'APPLICATION_ENV'
)
||
define
(
'APPLICATION_ENV'
,
'production'
);
...
...
Please
register
or
login
to post a comment