最近刚开始学php,爬坑中。上午看了会儿书,下了个源码,把文件部署到www下之后,也导入了sql文件,但是进入之后显示 = = 一开始不知道是什么。后来百度之后发现是mysql的问题,应该是源码中password和我的wamp默认的空密码不一样,一找过去,果然如此: 自己
最近刚开始学php,爬坑中。上午看了会儿书,下了个源码,把文件部署到www下之后,也导入了sql文件,但是进入之后显示
= = 一开始不知道是什么。后来百度之后发现是mysql的问题,应该是源码中password和我的wamp默认的空密码不一样,一找过去,果然如此:
自己琢磨了一下改进办法:1.要不就直接把 $pwd='yanhui'; 改成 %pwd='';
2.改一下数据库mysql的默认空密码
怎么改呢?经过实践:用命令行来改!
1.打开wamp的mysql,进去后默认空密码,直接回车就行。
2.然后就是mysql语言了,先输入 use mysql ;
再输入: update user set password=PASSWORD('123456') where user='root';
123456就是你要改的密码,mysql操作语言其实跟英语都差不多了,直接就能看出来某句话是什么意思。现在这句话的意思就是更新user名是root的用户的密码为“123456”。
3.最后一步!别忘了输入 flush privileges;
这是因为mysql 新设置用户或更改密码后需用flush privileges刷新MySQL的系统权限相关表,否则会出现拒绝访问,还有一种方法,就是重新启动mysql服务器,来使新设置生效。
然后输入 quit; 退出就可以了。
现在我们在看一下之前的网站!
其实就是个mysql更改数据库密码,但是对于这种php新鲜菜鸟来说,也算是个小技术...
但是不知道怎么就乱码了,还不是全部乱码,是部分乱码,index里面引入了不少php文件,就乱了套了
对于编码这块一直犯糊涂,尤其是php里面,蛋疼,求指导求帮助!
之前也写过前端开发的文章,陆续更起。
跪求PHP大神指导。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。

Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

AI Hentai Generator
Generate AI Hentai for free.

Hot Article

Hot Tools

SecLists
SecLists is the ultimate security tester's companion. It is a collection of various types of lists that are frequently used during security assessments, all in one place. SecLists helps make security testing more efficient and productive by conveniently providing all the lists a security tester might need. List types include usernames, passwords, URLs, fuzzing payloads, sensitive data patterns, web shells, and more. The tester can simply pull this repository onto a new test machine and he will have access to every type of list he needs.

EditPlus Chinese cracked version
Small size, syntax highlighting, does not support code prompt function

Zend Studio 13.0.1
Powerful PHP integrated development environment

SublimeText3 English version
Recommended: Win version, supports code prompts!

PhpStorm Mac version
The latest (2018.2.1) professional PHP integrated development tool