第七色在线视频,2021少妇久久久久久久久久,亚洲欧洲精品成人久久av18,亚洲国产精品特色大片观看完整版,孙宇晨将参加特朗普的晚宴

為了賬號安全,請及時綁定郵箱和手機立即綁定
已解決430363個問題,去搜搜看,總會有你想問的

Laravel黑屏

Laravel黑屏

PHP
慕哥6287543 2019-11-23 10:56:57
我的laravel站點以前可以工作,最近我升級到Apache 2.4和PHP 5.5.7?,F(xiàn)在,當我進入laravel.mydomain.com時,我得到一個白色的空白屏幕,apache錯誤日志,路由等中的任何內(nèi)容都應(yīng)該像以前一樣正常。當我在/var/sites/laravel/public/.htaccess中插入無效行時,得到500,.htaccess正在加載。這是我的.htaccess文件:$ cat /var/sites/laravel/public/.htaccess<IfModule mod_rewrite.c>    <IfModule mod_negotiation.c>    Options -MultiViews</IfModule>RewriteEngine On# Redirect Trailing Slashes...RewriteRule ^(.*)/$ /$1 [L,R=301]# Handle Front Controller...RewriteCond %{REQUEST_FILENAME} !-dRewriteCond %{REQUEST_FILENAME} !-fRewriteRule ^ index.php [L]這是我的虛擬主機指令:DocumentRoot "/var/sites/laravel/public"ServerName laravel.mydomain.com<Directory "/var/sites/laravel/public">    AllowOverride All    allow from all    Options +Indexes    Require all granted</Directory>和apachectl -S$ /usr/local/apache2/bin/apachectl -SVirtualHost configuration:*:*                    is a NameVirtualHost     default server mydomain.com (/usr/local/apache2/conf/extra/httpd-vhosts.conf:25)     port * namevhost mydomain.com (/usr/local/apache2/conf/extra/httpd-vhosts.conf:25)     port * namevhost laravel.mydomain.com (/usr/local/apache2/conf/extra/httpd-     vhosts.conf:34)ServerRoot: "/usr/local/apache2"Main DocumentRoot: "/var/www"Main ErrorLog: "/usr/local/apache2/logs/error_log"Mutex rewrite-map: using_defaultsMutex default: dir="/usr/local/apache2/logs/" mechanism=defaultPidFile: "/usr/local/apache2/logs/httpd.pid"Define: DUMP_VHOSTSDefine: DUMP_RUN_CFGUser: name="daemon" id=1 not_usedGroup: name="daemon" id=1 not_used
查看完整描述

3 回答

?
HUWWW

TA貢獻1874條經(jīng)驗 獲得超12個贊

阿帕奇

這個答案是否描述或幫助了您的情況?升級到Apache 2.4會對Apache配置進行一些更改。


拉拉韋爾

您在查看Laravel的日志還是Apache的日志?


自從升級到Laravel 4.1之后,當應(yīng)用程序無法寫入日志位置時,我遇到了白屏“錯誤”(WSOD)。我總是通過使app / storage目錄可被Apache寫入(組可寫入“ www-data”,“ apache”或世界可寫入)來解決此問題,這取決于您的服務(wù)器設(shè)置。


Web服務(wù)器用戶

在Ubuntu / Debian服務(wù)器上,您的PHP可能以“ www-data”用戶身份運行。在CentOS / RedHat / Fedora服務(wù)器上,您的PHP可能以“ apache”用戶身份運行。


確保您的文件歸運行PHP的用戶所有:


# Debian/Ubuntu

$ sudo chown -R www-data /path/to/laravel/files


# CentOS/RedHat/Fedora

$ sudo chown -R apache /path/to/laravel/files

請注意,您可能未以用戶www-data或apache的身份運行。這取決于您的托管和設(shè)置!


Laravel 4

# Group Writable (Group, User Writable)

$ sudo chmod -R gu+w app/storage


# World-writable (Group, User, Other Writable)

$ sudo chmod -R guo+w app/storage

Laravel 5+(包括6)

# Group Writable (Group, User Writable)

$ sudo chmod -R gu+w storage


# World-writable (Group, User, Other Writable)

$ sudo chmod -R guo+w storage


#####

# The bootstrap/cache directory may need writing to also

##


# Group Writable (Group, User Writable)

$ sudo chmod -R gu+w bootstrap/cache


# World-writable (Group, User, Other Writable)

$ sudo chmod -R guo+w bootstrap/cache


查看完整回答
反對 回復(fù) 2019-11-23
?
jeck貓

TA貢獻1909條經(jīng)驗 獲得超7個贊

當我剛接觸Linux時,通常會在我的Laravel項目中發(fā)現(xiàn)此錯誤。白色錯誤表示錯誤,它可能存在某些權(quán)限問題或錯誤。


您只需要遵循兩個步驟,就能像冠軍般工作:)


(1)給予許可。從項目的根目錄運行這些命令


(a) sudo chmod 777 -R storage

(b) sudo chmod bootstrap/cache

(2)如果您克隆了項目或從github提取了項目,請運行


composer install

(3)正確配置.env文件,您的項目將運行。


查看完整回答
反對 回復(fù) 2019-11-23
  • 3 回答
  • 0 關(guān)注
  • 273 瀏覽

添加回答

舉報

0/150
提交
取消
微信客服

購課補貼
聯(lián)系客服咨詢優(yōu)惠詳情

幫助反饋 APP下載

慕課網(wǎng)APP
您的移動學(xué)習(xí)伙伴

公眾號

掃描二維碼
關(guān)注慕課網(wǎng)微信公眾號