Home  >  Article  >  Backend Development  >  php解决办法

php解决办法

WBOY
WBOYOriginal
2016-06-13 12:48:59681browse

php
这个数据库连接的文件代码要怎么写啊?比如我要连接的数据库名是db,然后不要用类操作啊~看不懂,
还有就是首页的框架的main.php的框架是么样定义啊?


------解决方案--------------------
$con=mysql_connect('主机地址','用户名','密码');
mysql_select_db('db',$con);

这些都是最基本的,网上搜索下就有了,建议从头开始学起。
Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn