1
0
Fork 0
mirror of https://github.com/Oreolek/ifhub.club.git synced 2024-07-02 22:45:02 +03:00

Merge pull request #326 from livestreet/new-struct

New struct
This commit is contained in:
Mzhelskiy Maxim 2013-08-13 00:43:02 -07:00
commit 2005ba552e
1576 changed files with 843 additions and 643 deletions

15
.gitignore vendored
View file

@ -1,8 +1,7 @@
config/config.local.php
config/config.test.php
logs/*
plugins/*
templates/cache/*
templates/compiled/*
tmp/*
uploads/*
/application/config/config.local.php
/application/config/config.test.php
/application/logs/*
/application/plugins/*
/application/tmp/*
/uploads/*
/.idea/

View file

@ -1608,7 +1608,7 @@ class ActionBlog extends Action {
)
);
require_once Config::Get('path.root.engine').'/lib/external/XXTEA/encrypt.php';
require_once Config::Get('path.framework.libs_vendor.server').'/XXTEA/encrypt.php';
/**
* Формируем код подтверждения в URL
*/
@ -1646,7 +1646,7 @@ class ActionBlog extends Action {
* Обработка отправленого пользователю приглашения вступить в блог
*/
protected function EventInviteBlog() {
require_once Config::Get('path.root.engine').'/lib/external/XXTEA/encrypt.php';
require_once Config::Get('path.framework.libs_vendor.server').'/XXTEA/encrypt.php';
/**
* Получаем код подтверждения из ревеста и дешефруем его
*/

View file

@ -692,7 +692,7 @@ class ActionProfile extends Action {
* Добавление пользователя в друзья, по отправленной заявке
*/
public function EventFriendOffer() {
require_once Config::Get('path.root.engine').'/lib/external/XXTEA/encrypt.php';
require_once Config::Get('path.framework.libs_vendor.server').'/XXTEA/encrypt.php';
/**
* Из реквеста дешефруем ID польователя
*/
@ -1074,7 +1074,7 @@ class ActionProfile extends Action {
)
);
require_once Config::Get('path.root.engine').'/lib/external/XXTEA/encrypt.php';
require_once Config::Get('path.framework.libs_vendor.server').'/XXTEA/encrypt.php';
$sCode=$this->oUserCurrent->getId().'_'.$oUser->getId();
$sCode=rawurlencode(base64_encode(xxtea_encrypt($sCode, Config::Get('module.talk.encrypt'))));

View file

@ -35,7 +35,7 @@ class HookMain extends Hook {
/**
* Проверяем наличие директории install
*/
if(is_dir(rtrim(Config::Get('path.root.server'),'/').'/install') && $_SERVER['HTTP_APP_ENV']!='test'){
if(is_dir(rtrim(Config::Get('path.root.server'),'/').'/install') && (!isset($_SERVER['HTTP_APP_ENV']) or $_SERVER['HTTP_APP_ENV']!='test')){
$this->Message_AddErrorSingle($this->Lang_Get('install_directory_exists'));
Router::Action('error');
}

View file

@ -178,7 +178,7 @@ class ModuleBlog_EntityBlog extends Entity {
if ($sPath=$this->getAvatar()) {
return preg_replace("#_\d{1,3}x\d{1,3}(\.\w{3,4})$#", ((($iSize==0)?"":"_{$iSize}x{$iSize}") . "\\1"),$sPath);
} else {
return Config::Get('path.static.assets').'/images/avatars/avatar_blog_'.$iSize.'x'.$iSize.'.png';
return Config::Get('path.skin.assets.web').'/images/avatars/avatar_blog_'.$iSize.'x'.$iSize.'.png';
}
}
/**

View file

@ -1,5 +1,5 @@
<?php
require_once(Config::Get('path.root.engine').'/lib/external/Sphinx/sphinxapi.php');
require_once(Config::Get('path.framework.libs_vendor.server').'/Sphinx/sphinxapi.php');
/**
* Модуль для работы с машиной полнотекстового поиска Sphinx

View file

@ -79,5 +79,24 @@ class ModuleTools extends Module {
unset($aTable['&']);
return strtr($sText,$aTable);
}
/**
* Обработка тега ls в тексте
* <pre>
* <ls user="admin" />
* </pre>
*
* @param string $sTag Тег на ктором сработал колбэк
* @param array $aParams Список параметров тега
* @return string
*/
public function CallbackParserTagLs($sTag,$aParams) {
$sText='';
if (isset($aParams['user'])) {
if ($oUser=$this->User_getUserByLogin($aParams['user'])) {
$sText.="<a href=\"{$oUser->getUserWebPath()}\" class=\"ls-user\">{$oUser->getLogin()}</a> ";
}
}
return $sText;
}
}
?>

View file

@ -366,7 +366,7 @@ class ModuleUser_EntityUser extends Entity {
if ($sPath=$this->getProfileAvatar()) {
return str_replace('_100x100',(($iSize==0)?"":"_{$iSize}x{$iSize}"),$sPath."?".date('His',strtotime($this->getProfileDate())));
} else {
return Config::Get('path.static.assets').'/images/avatars/avatar_'.($this->getProfileSex()=='woman' ? 'female' : 'male').'_'.$iSize.'x'.$iSize.'.png';
return Config::Get('path.skin.assets.web').'/images/avatars/avatar_'.($this->getProfileSex()=='woman' ? 'female' : 'male').'_'.$iSize.'x'.$iSize.'.png';
}
}
/**
@ -386,7 +386,7 @@ class ModuleUser_EntityUser extends Entity {
* @return string
*/
public function getProfileFotoDefault() {
return Config::Get('path.static.assets').'/images/avatars/user_photo_'.($this->getProfileSex()=='woman' ? 'female' : 'male').'.png';
return Config::Get('path.skin.assets.web').'/images/avatars/user_photo_'.($this->getProfileSex()=='woman' ? 'female' : 'male').'.png';
}
/**
* Возвращает объект голосования за пользователя текущего пользователя

Some files were not shown because too many files have changed in this diff Show more