Русское сообщество разработки на PHP-фреймворке Laravel.
Ты не вошёл. Вход тут.
Сделал вот это все и все равно глухо
sudo chown -R root:www-data storage (ownership to members of..)
sudo chmod -R g+rwX storage (permissions recursively)
sudo chmod g+s storage (affect future sub-directories)
.env was misisng on the remote server (.gitignore)
Fatal error: Uncaught UnexpectedValueException: The stream or file "/var/www/clients/client1/web2/web/gincore/manage/../logs/app.log" could not be opened: failed to open stream: Permission denied in /var/www/clients/client1/web2/web/gincore/gincore/bootstrap/cache/compiled.php:13906 Stack trace: #0 /var/www/clients/client1/web2/web/gincore/gincore/bootstrap/cache/compiled.php(13836): Monolog\Handler\StreamHandler->write(Array) #1 /var/www/clients/client1/web2/web/gincore/gincore/bootstrap/cache/compiled.php(13596): Monolog\Handler\AbstractProcessingHandler->handle(Array) #2 /var/www/clients/client1/web2/web/gincore/gincore/bootstrap/cache/compiled.php(13694): Monolog\Logger->addRecord(400, '/var/www/client...', Array) #3 /var/www/clients/client1/web2/web/gincore/manage/Core/Log.php(36): Monolog\Logger->error('/var/www/client...') #4 /var/www/clients/client1/web2/web/gincore/manage/inc_config.php(55): Log::error('/var/www/client...', '/var/www/client...') #5 [internal function]: error_handler(2, 'session_start()...', '/var in /var/www/clients/client1/web2/web/gincore/gincore/bootstrap/cache/compiled.php on line 13906
Доступ к папке storage полный
делал
php artisan cache:clear
Как исправить эту ошибку?
Я запускаю команду php artisan migrate
хочу запустить все миграции в приложении
в ответ получаю вот это что мне делать я новичек
SQLSTATE[42S02]: Base table or view not found: 1146 Table 'gincore.restore4_warehouses' doesn't exist (SQL: alter ta
ble `
restore4_warehouses` add `is_system` tinyint not null default '0')
[PDOException]
SQLSTATE[42S02]: Base table or view not found: 1146 Table 'gincore.restore4_warehouses' doesn't exist
Объясните как из консоли это чинится
Да похоже что не могу правильно настроить виртуальные хосты, все дело в том что они у меня под управлением панели ISPConfig помоему
http://prntscr[dot]com/dkhpct
http://prntscr[dot]com/dkhpn2
Document root как видно настроен но все равно 403 ошибка
это при том что в /gincore/gincore/public лежит этот .htaccess
<IfModule mod_rewrite.c>
<IfModule mod_negotiation.c>
Options -MultiViews
</IfModule>
RewriteEngine On
# Redirect Trailing Slashes If Not A Folder...
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)/$ /$1 [L,R=301]
# Handle Front Controller...
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^ index.php [L]
# Handle Authorization Header
RewriteCond %{HTTP:Authorization} .
RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]
</IfModule>
у меня ларавель установлен тут
/var/www/gincore.imedia.in.ua/we b/gincore/gincore/public/index.p hp
вот мой .htaccess в корне /web
Options +FollowSymLinks
Options -Indexes
DirectoryIndex index.php
RewriteEngine on
RewriteCond %{HTTP_HOST} ^gincore.imedia.in.ua$ [NC,OR]
RewriteCond %{HTTP_HOST} ^www.gincore.imedia.in.ua$
RewriteCond %{REQUEST_URI} !gincore/gincore/public/
RewriteRule (.*) /gincore/gincore/public/index.ph p [L]
почему возникает и как удалить 403 ошибку?
В стандарте используется путь к папке видов
/resources/views
у меня сервис менеджер выглядит так
public function boot()
{
print('moduleservice provider');
//
$modules = config("module.modules");
while (list(,$module) = each($modules)) {
echo "<pre>";
if(file_exists(__DIR__.'/'.$module.'/routes.php')) {
include __DIR__.'/'.$module.'/routes.php';
}
if(is_dir(__DIR__.'/'.$module.'/Views')) {
echo __DIR__.'/'.$module.'/Views';
echo "</br>";
var_dump($module);
$this->loadViewsFrom( __DIR__.'/'.$module.'/Views', $module );
}
echo "</pre>";
}
}
используется эта строка include __DIR__.'/'.$module.'/routes.php';
чтобы получить роут,
вот этот роут
Route::group(array('module'=>'Admin','namespace' => 'Modules\Admin\Controllers'), function() {
Route::get('admin',function(){
return view("admin");
});
});
но так как сказано выше что виды ищутся /resources/views
, то я не могу открыть вид admin.blade.php находящийся в /modules/admin/views
Чтосделать чтобы его открыть
/resources/views
где можно поменять этот путь умолчанию?
Извините, вы слишком голословы, во первых есть модули а во вторых ?....
Я создал структуру
app/modules
/admin
/controller
/views
ServiceProvider.php
[php]
<?php namespace App\Modules;
class ServiceProvider extends \Illuminate\Support\ServiceProvider
{
public function boot()
{
$modules = config("module.modules");
while (list(,$module) = each($modules)) {
if(file_exists(__DIR__.'/'.$module.'/routes.php')) {
include __DIR__.'/'.$module.'/routes.php';
}
if(is_dir(__DIR__.'/'.$module.'/Views')) {
$this->loadViewsFrom(__DIR__.'/'.$module.'/Views', $module);
}
}
}
public function register(){}
}
[/php]
Как теперь происходит запуск домашнего контроллера,
и как совершить вызов админ контроллера, может быть должно быть еще что то,
и все ли правильно в этом сервис провайдере
такое впечатление что этот провайдер не включается и не регулирует ничего
вот ошибка при переходе к админ модулю
Извините но я уже все перепробовал не могу избавится от этой ошибки
я мало шарю что он хочет?
Как установить модульный ларавель
Я имею вот такую ошибку при запуске композера
Your requirements could not be resolved to an installable set of packages.
Problem 1
- laravel/framework v5.0.9 requires ext-mcrypt * -> the requested PHP extension mcrypt is missing from your system.
- laravel/framework v5.0.8 requires ext-mcrypt * -> the requested PHP extension mcrypt is missing from your system.
- laravel/framework v5.0.7 requires ext-mcrypt * -> the requested PHP extension mcrypt is missing from your system.
- laravel/framework v5.0.6 requires ext-mcrypt * -> the requested PHP extension mcrypt is missing from your system.
- laravel/framework v5.0.5 requires ext-mcrypt * -> the requested PHP extension mcrypt is missing from your system.
- laravel/framework v5.0.4 requires ext-mcrypt * -> the requested PHP extension mcrypt is missing from your system.
- laravel/framework v5.0.35 requires ext-mcrypt * -> the requested PHP extension mcrypt is missing from your system.
- laravel/framework v5.0.34 requires ext-mcrypt * -> the requested PHP extension mcrypt is missing from your system.
- laravel/framework v5.0.33 requires ext-mcrypt * -> the requested PHP extension mcrypt is missing from your system.
- laravel/framework v5.0.32 requires ext-mcrypt * -> the requested PHP extension mcrypt is missing from your system.
- laravel/framework v5.0.31 requires ext-mcrypt * -> the requested PHP extension mcrypt is missing from your system.
- laravel/framework v5.0.3 requires ext-mcrypt * -> the requested PHP extension mcrypt is missing from your system.
- laravel/framework v5.0.29 requires ext-mcrypt * -> the requested PHP extension mcrypt is missing from your system.
- laravel/framework v5.0.28 requires ext-mcrypt * -> the requested PHP extension mcrypt is missing from your system.
- laravel/framework v5.0.27 requires ext-mcrypt * -> the requested PHP extension mcrypt is missing from your system.
- laravel/framework v5.0.26 requires ext-mbstring * -> the requested PHP extension mbstring is missing from your system.
- laravel/framework v5.0.25 requires ext-mcrypt * -> the requested PHP extension mcrypt is missing from your system.
- laravel/framework v5.0.24 requires ext-mcrypt * -> the requested PHP extension mcrypt is missing from your system.
- laravel/framework v5.0.23 requires ext-mcrypt * -> the requested PHP extension mcrypt is missing from your system.
- laravel/framework v5.0.22 requires ext-mcrypt * -> the requested PHP extension mcrypt is missing from your system.
- laravel/framework v5.0.21 requires ext-mcrypt * -> the requested PHP extension mcrypt is missing from your system.
- laravel/framework v5.0.20 requires ext-mcrypt * -> the requested PHP extension mcrypt is missing from your system.
- laravel/framework v5.0.2 requires ext-mcrypt * -> the requested PHP extension mcrypt is missing from your system.
- laravel/framework v5.0.19 requires ext-mcrypt * -> the requested PHP extension mcrypt is missing from your system.
- laravel/framework v5.0.18 requires ext-mcrypt * -> the requested PHP extension mcrypt is missing from your system.
- laravel/framework v5.0.17 requires ext-mcrypt * -> the requested PHP extension mcrypt is missing from your system.
- laravel/framework v5.0.16 requires ext-mcrypt * -> the requested PHP extension mcrypt is missing from your system.
- laravel/framework v5.0.15 requires ext-mcrypt * -> the requested PHP extension mcrypt is missing from your system.
- laravel/framework v5.0.14 requires ext-mcrypt * -> the requested PHP extension mcrypt is missing from your system.
- laravel/framework v5.0.13 requires ext-mcrypt * -> the requested PHP extension mcrypt is missing from your system.
- laravel/framework v5.0.12 requires ext-mcrypt * -> the requested PHP extension mcrypt is missing from your system.
- laravel/framework v5.0.11 requires ext-mcrypt * -> the requested PHP extension mcrypt is missing from your system.
- laravel/framework v5.0.10 requires ext-mcrypt * -> the requested PHP extension mcrypt is missing from your system.
- laravel/framework v5.0.1 requires ext-mcrypt * -> the requested PHP extension mcrypt is missing from your system.
- laravel/framework v5.0.0 requires ext-mcrypt * -> the requested PHP extension mcrypt is missing from your system.
- laravel/framework 5.0.30 requires ext-mcrypt * -> the requested PHP extension mcrypt is missing from your system.
- Installation request for laravel/framework 5.0.* -> satisfiable by laravel/framework[5.0.30, v5.0.0, v5.0.1, v5.0.10, v5.0.11, v5.0.12, v5.0.13, v5.0.14, v5.0.15, v5.0.16, v5.0.17, v5.0.18, v5.0.19, v5.0.2, v5.0.20, v5.0.21, v5.0.22, v5.0.23, v5.0.24, v5.0.25, v5.0.26, v5.0.27, v5.0.28, v5.0.29, v5.0.3, v5.0.31, v5.0.32, v5.0.33, v5.0.34, v5.0.35, v5.0.4, v5.0.5, v5.0.6, v5.0.7, v5.0.8, v5.0.9].
To enable extensions, verify that they are enabled in those .ini files:
- /etc/php/7.0/cli/php.ini
- /etc/php/7.0/cli/conf.d/10-mysqlnd.ini
- /etc/php/7.0/cli/conf.d/10-opcache.ini
- /etc/php/7.0/cli/conf.d/10-pdo.ini
- /etc/php/7.0/cli/conf.d/15-xml.ini
- /etc/php/7.0/cli/conf.d/20-calendar.ini
- /etc/php/7.0/cli/conf.d/20-ctype.ini
- /etc/php/7.0/cli/conf.d/20-dom.ini
- /etc/php/7.0/cli/conf.d/20-exif.ini
- /etc/php/7.0/cli/conf.d/20-fileinfo.ini
- /etc/php/7.0/cli/conf.d/20-ftp.ini
- /etc/php/7.0/cli/conf.d/20-gettext.ini
- /etc/php/7.0/cli/conf.d/20-iconv.ini
- /etc/php/7.0/cli/conf.d/20-json.ini
- /etc/php/7.0/cli/conf.d/20-mysqli.ini
- /etc/php/7.0/cli/conf.d/20-pdo_mysql.ini
- /etc/php/7.0/cli/conf.d/20-phar.ini
- /etc/php/7.0/cli/conf.d/20-posix.ini
- /etc/php/7.0/cli/conf.d/20-readline.ini
- /etc/php/7.0/cli/conf.d/20-shmop.ini
- /etc/php/7.0/cli/conf.d/20-simplexml.ini
- /etc/php/7.0/cli/conf.d/20-sockets.ini
- /etc/php/7.0/cli/conf.d/20-sysvmsg.ini
- /etc/php/7.0/cli/conf.d/20-sysvsem.ini
- /etc/php/7.0/cli/conf.d/20-sysvshm.ini
- /etc/php/7.0/cli/conf.d/20-tokenizer.ini
- /etc/php/7.0/cli/conf.d/20-wddx.ini
- /etc/php/7.0/cli/conf.d/20-xmlreader.ini
- /etc/php/7.0/cli/conf.d/20-xmlwriter.ini
- /etc/php/7.0/cli/conf.d/20-xsl.ini
Что тут не так ?
Вот мой composer.json
{
"name": "laravel/laravel",
"description": "The Laravel Framework.",
"keywords": ["framework", "laravel"],
"license": "MIT",
"type": "project",
"require": {
"laravel/framework": "5.0.*"
},
"require-dev": {
"phpunit/phpunit": "~4.0",
"phpspec/phpspec": "~2.1"
},
"autoload": {
"classmap": [
"database"
],
"psr-4": {
"App\\": "app/",
"Modules\\": "app/modules"
}
},
"autoload-dev": {
"classmap": [
"tests/TestCase.php"
]
},
"scripts": {
"post-install-cmd": [
"php artisan clear-compiled",
"php artisan optimize"
],
"post-update-cmd": [
"php artisan clear-compiled",
"php artisan optimize"
],
"post-create-project-cmd": [
"php -r \"copy('.env.example', '.env');\"",
"php artisan key:generate"
]
},
"config": {
"preferred-install": "dist"
}
}
Warning: require(/var/www/clients/client1/web25/web/laravel/bootstrap/../vendor/autoload.php): failed to open stream: No such file or directory in /var/www/clients/client1/web25/web/laravel/bootstrap/autoload.php on line 17
Fatal error: require(): Failed opening required '/var/www/clients/client1/web25/web/laravel/bootstrap/../vendor/autoload.php' (include_path='.:/usr/share/php') in /var/www/clients/client1/web25/web/laravel/bootstrap/autoload.php on line 17
добре дякую
Скажите пожалуйста
Объясните как происходит в Ларавеле перенаправление на гектор
то есть к примеру вот ссылка
<li><a href="{{ url('/auth/register') }}">Register</a></li>
как найти метод register его попросту нет
требуется платная консультация php apache mod_cgi Ларавель skype imediasun срочно
достаточно убрать вот эту строку и грузится индекс
[PHP]
require __DIR__.'/../bootstrap/autoload.php';
[/PHP]
он на __DIR__ так реагирует что это может быть?
Очень прошу отозваться ставлю Ларавель 5.2
В логах вот такая штука
[Sat Mar 05 10:47:42.229681 2016] [fcgid:warn] [pid 44709] (104)Connection reset by peer: [client 91.192.136.218:13970] mod_fcgid: error reading data from FastCGI server
[Sat Mar 05 10:47:42.229745 2016] [core:error] [pid 44709] [client 91.192.136.218:13970] End of script output before headers: index.php
понимаю что тут конфигурация апача и я не имею соответствующего опыта, готов оплатить на карту за срочную помощь
короче ситуация такая что если вместо содержимого индекса я пишу php_info() все ок если индекс то 500 ошибка, как настроить хост и htaccess подскажите пожалуйста
[Fri Mar 04 20:47:58.583368 2016] [fcgid:warn] [pid 55153] (104)Connection reset by peer: [client 91.192.136.218:5140] mod_fcgid: error reading data from FastCGI server
[Fri Mar 04 20:47:58.583413 2016] [core:error] [pid 55153] [client 91.192.136.218:5140] End of script output before headers: index.php
а когда из индекса все удаляю и вставляю <?php phpinfo(); ?> все ок
Laravel на 5.5.9 не работает что ли?
тут вот какой лог голову морочит
[Fri Mar 04 16:19:39.864597 2016] [fcgid:warn] [pid 117672] (104)Connection reset by peer: [client 91.192.136.218:29219] mod_fcgid: error reading data from FastCGI server
[Fri Mar 04 16:19:39.864635 2016] [core:error] [pid 117672] [client 91.192.136.218:29219] End of script output before headers: index.php
и я не знаю что с ним делать
уже добавил в хост
вот это
<IfModule mod_fcgid.c>
# 5 minutes for IO timeout, default is 40 seconds
FcgidIOTimeout 300
</IfModule>
все равно та эе ошибка
Вот хост document root прописан
<Directory /var/www/laravel.lopushansky.com/web>
AllowOverride None
Require all denied
RewriteEngine On
RewriteBase "/directory/"
RewriteRule "^index\.html$" "welcome.html"
</Directory>
<VirtualHost 91.192.136.222:80>
DocumentRoot /var/www/laravel.lopushansky.com/web/{directory}/public
ServerName laravel.lopushansky.com
ServerAlias www.laravel.lopushansky.com
ServerAdmin webmaster@laravel.lopushansky.com
ErrorLog /var/log/ispconfig/httpd/laravel.lopushansky.com/error.log
Alias /error/ "/var/www/laravel.lopushansky.com/web/error/"
ErrorDocument 400 /error/400.html
ErrorDocument 401 /error/401.html
ErrorDocument 403 /error/403.html
ErrorDocument 404 /error/404.html
ErrorDocument 405 /error/405.html
ErrorDocument 500 /error/500.html
ErrorDocument 502 /error/502.html
ErrorDocument 503 /error/503.html
htaccess
Options +FollowSymLinks
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^ index.php [L]
[Fri Mar 04 11:06:35.926931 2016] [core:alert] [pid 107945] [client 91.192.136.218:51186] /var/www/laravel.lopushansky()com/web/{directory}/public/.htaccess: RewriteRule: bad flag delimiters
[Fri Mar 04 11:06:37.018225 2016] [core:alert] [pid 107946] [client 91.192.136.218:51187] /var/www/laravel.lopushansky()com/web/{directory}/public/.htaccess: RewriteRule: bad flag delimiters
[Fri Mar 04 11:06:40.527735 2016] [core:alert] [pid 107947] [client 91.192.136.218:51190] /var/www/laravel.lopushansky()com/web/{directory}/public/.htaccess: RewriteRule: bad flag delimiters
[Fri Mar 04 11:06:46.034058 2016] [core:alert] [pid 107944] [client 91.192.136.218:51201] /var/www/laravel.lopushansky()com/web/{directory}/public/.htaccess: RewriteRule: bad flag delimiters
[Fri Mar 04 11:07:54.151772 2016] [core:alert] [pid 107946] [client 91.192.136.218:51250] /var/www/laravel.lopushansky()com/web/{directory}/public/.htaccess: RewriteRule: bad flag delimiters
[Fri Mar 04 11:07:55.529942 2016] [core:alert] [pid 107943] [client 91.192.136.218:51259] /var/www/laravel.lopushansky()com/web/{directory}/public/.htaccess: RewriteRule: bad flag delimiters
[Fri Mar 04 11:08:14.094631 2016] [fcgid:warn] [pid 107947] (104)Connection reset by peer: [client 91.192.136.218:51280] mod_fcgid: error reading data from FastCGI server
[Fri Mar 04 11:08:14.094664 2016] [core:error] [pid 107947] [client 91.192.136.218:51280] End of script output before headers: index.php
[Fri Mar 04 11:08:55.244501 2016] [fcgid:warn] [pid 107945] (104)Connection reset by peer: [client 91.192.136.218:51331] mod_fcgid: error reading data from FastCGI server
[Fri Mar 04 11:08:55.244536 2016] [core:error] [pid 107945] [client 91.192.136.218:51331] End of script output before headers: index.php
[Fri Mar 04 11:09:40.263787 2016] [fcgid:warn] [pid 108069] (104)Connection reset by peer: [client 91.192.136.218:51371] mod_fcgid: error reading data from FastCGI server
[Fri Mar 04 11:09:40.263837 2016] [core:error] [pid 108069] [client 91.192.136.218:51371] End of script output before headers: index.php
[Fri Mar 04 11:15:00.521817 2016] [fcgid:warn] [pid 108233] (104)Connection reset by peer: [client 91.192.136.218:51623] mod_fcgid: error reading data from FastCGI server
[Fri Mar 04 11:15:00.521857 2016] [core:error] [pid 108233] [client 91.192.136.218:51623] End of script output before headers: index.php
[Fri Mar 04 11:16:02.114422 2016] [fcgid:warn] [pid 108354] (104)Connection reset by peer: [client 91.192.136.218:51672] mod_fcgid: error reading data from FastCGI server
[Fri Mar 04 11:16:02.114461 2016] [core:error] [pid 108354] [client 91.192.136.218:51672] End of script output before headers: index.php