运行 wordpress 站点不同的本地主机 [英] Running wordpress site different local host

查看:31
本文介绍了运行 wordpress 站点不同的本地主机的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我最近参加了我的第一个编程项目,它是使用 wordpress 进行的,我以前从未使用过它,因为我之前只做过硬编码 HTML/CSS.我的客户给了我她网站的所有文件,我如何在 wordpress 上运行它.我已经安装了 wordpress 并且可以运行 test123 站点,但是当我使用她给我的信息在本地服务器上做同样的事情时,我得到一个建立数据库连接时出错".这很奇怪,因为她给我的信息中的所有文件夹都与测试站点相同(显然内容不同).她是在 mac 上做的,我在 windows 上,但我认为这无关紧要.我该如何解决这个问题,以便我可以在 wordpress 上看到该网站并进行她想要的必要更改.

I have recently taken my first programming project and it is with word press, I have never used it before as I have only done hard coding HTML/CSS before. My client has given me all of the files of her site, how do I run this on wordpress. I have installed wordpress and can run the test123 site but when I do the same thing on the local server with the info she gave me then I get a "Error establishing a database connection". This is surprising because all of the file folders in the info she gave me is the same as the test site (obv the content is different). She was doing it on a mac and I am on windows but I assume that hsouldn't matter. How can I fix this so I can see the site on wordpress and make the required changes that she wanted.

谢谢!

我尝试更改配置文件,但这只是再次给我设置,而不是她已经创建的站点:(

I tried changing the config file but that just gives me the setup again and not the site she has already made :(

推荐答案

在wamp服务器上安装WordPress

installation WordPress in wamp server

首先启动wamp服务器

first, start wamp server

点击启动所有服务,当它工作时,图标会变成绿色

click to start all services when it will work the icon will be colored green

转到 C:\wamp\www 并将 WordPress 文件夹粘贴到那里.您可以将 WordPress 文件夹重命名为任何您想要的名称,例如 test123

Go to C:\wamp\www and paste WordPress folder there. You can rename the WordPress folder to anything you want for example test123

现在打开网络浏览器并转到:

Now open a web browser and go to:

http://localhost/test123/

它会问你数据库连接错误

it will ask you for database connection error

现在打开 phpmyadmin,如图所示进入创建一个数据库并导入数据库

now open the phpmyadmin as showing into create a database and import the database

然后转到您的 Wordpress 文件夹 test123 并找到 wp-config.php 文件并将您的用户名替换为您创建的root"数据库名称,密码为空.现在再次运行 http://localhost/test123/

then go to you Wordpress folder test123 and find the wp-config.php file and replace your username with "root" database name you created , and password blank . now run http://localhost/test123/ once again

如果没有工作,请来聊天室.

if not work then please come to chat box room.

这篇关于运行 wordpress 站点不同的本地主机的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆