MAMP + Wordpress - 无法让本地站点正常运行
MAMP + Wordpress - Can't get local site to function
我已经安装了 MAMP 并正在尝试在我的计算机上获取 Wordpress 站点的本地开发版本 运行。
我已经阅读了很多教程,解释了我需要在 wp-config.php
和数据库中更改的内容,但我无法让页面正常运行。
数据库中的 siteurl
和 home
字段都已更新为 http://localhost/
并且我已将数据库用户名和密码的 wp-config.php
更新为 root
.
我设置了 WP_DEBUG: true
以便我得到一些关于可能导致错误的反馈,以下是我尝试转到 http://localhost/
时得到的信息:
Fatal error:
Uncaught Error:
Call to undefined function mysql_error() in /Users/oldo/Desktop/Website Development/Clean Cut Concrete/mirror/public_html/cleancutconcrete.com/wp-content/plugins/revslider/inc_php/framework/db.class.php:29
Stack trace:
#0 /Users/oldo/Desktop/Website Development/Clean Cut Concrete/mirror/public_html/cleancutconcrete.com/wp-content/plugins/revslider/inc_php/framework/db.class.php(127): UniteDBRev->checkForErrors('fetch')
#1 /Users/oldo/Desktop/Website Development/Clean Cut Concrete/mirror/public_html/cleancutconcrete.com/wp-content/plugins/revslider/inc_php/revslider_params.class.php(42): UniteDBRev->fetch('wp_revslider_se...')
#2 /Users/oldo/Desktop/Website Development/Clean Cut Concrete/mirror/public_html/cleancutconcrete.com/wp-content/plugins/revslider/inc_php/revslider_operations.class.php(1275): RevSliderParams->getFieldFromDB('general')
#3 /Users/oldo/Desktop/Website Development/Clean Cut Concrete/mirror/public_html/cleancutconcrete.com/wp-content/plugins/revslider/revslider_front.php(42) in /Users/oldo/Desktop/Website Development/Clean Cut Concrete/mirror/public_html/cleancutconcrete.com/wp-content/plugins/revslider/inc_php/framework/db.class.php on line 29
有人可以就如何解决这个问题提出建议吗?
Saqib Amin 在上面的评论中回答了这个问题,但我想我也会 post 在这里回答,这样就很明显了。正如我所指出的,mysql_*
函数已在 PHP 7 中删除,因此我将 MAMP 更改为使用 PHP 5.6.10,它现在可以使用了。
我已经安装了 MAMP 并正在尝试在我的计算机上获取 Wordpress 站点的本地开发版本 运行。
我已经阅读了很多教程,解释了我需要在 wp-config.php
和数据库中更改的内容,但我无法让页面正常运行。
数据库中的 siteurl
和 home
字段都已更新为 http://localhost/
并且我已将数据库用户名和密码的 wp-config.php
更新为 root
.
我设置了 WP_DEBUG: true
以便我得到一些关于可能导致错误的反馈,以下是我尝试转到 http://localhost/
时得到的信息:
Fatal error:
Uncaught Error:
Call to undefined function mysql_error() in /Users/oldo/Desktop/Website Development/Clean Cut Concrete/mirror/public_html/cleancutconcrete.com/wp-content/plugins/revslider/inc_php/framework/db.class.php:29
Stack trace:
#0 /Users/oldo/Desktop/Website Development/Clean Cut Concrete/mirror/public_html/cleancutconcrete.com/wp-content/plugins/revslider/inc_php/framework/db.class.php(127): UniteDBRev->checkForErrors('fetch')
#1 /Users/oldo/Desktop/Website Development/Clean Cut Concrete/mirror/public_html/cleancutconcrete.com/wp-content/plugins/revslider/inc_php/revslider_params.class.php(42): UniteDBRev->fetch('wp_revslider_se...')
#2 /Users/oldo/Desktop/Website Development/Clean Cut Concrete/mirror/public_html/cleancutconcrete.com/wp-content/plugins/revslider/inc_php/revslider_operations.class.php(1275): RevSliderParams->getFieldFromDB('general')
#3 /Users/oldo/Desktop/Website Development/Clean Cut Concrete/mirror/public_html/cleancutconcrete.com/wp-content/plugins/revslider/revslider_front.php(42) in /Users/oldo/Desktop/Website Development/Clean Cut Concrete/mirror/public_html/cleancutconcrete.com/wp-content/plugins/revslider/inc_php/framework/db.class.php on line 29
有人可以就如何解决这个问题提出建议吗?
Saqib Amin 在上面的评论中回答了这个问题,但我想我也会 post 在这里回答,这样就很明显了。正如我所指出的,mysql_*
函数已在 PHP 7 中删除,因此我将 MAMP 更改为使用 PHP 5.6.10,它现在可以使用了。