<?php error_reporting(0); header(“content-Type: text/html; charset=utf-8”); $con = mysql_connect(‘127.0.0.1:3306′,’root’,’password’);if (!$con) {die(‘Could not connect: ‘ . mysql_error()); } mysql_select_db(“sql_name”, $con); mysql_query(‘set names utf8’);echo “资讯<HR>”; $result = mysql_query(“SELECT * FROM thinkoao_article”);while($row = mysql_fetch_array($result)) {// echo ‘<a href=”https://www.xxx.com/home/article/zixun_news/id/’.$row[‘id’].’.html” target=”_blank”>’.$row[‘title’].'</a><BR>’;echo ‘https://www.xxx.com/home/article/zixun_news/id/’.$row[‘id’].’.html<BR>’;}echo “课程<HR>”; $result = “”; $result = mysql_query(“SELECT * FROM thinkoao_course”);while($row = mysql_fetch_array($result)) {//echo ‘<a href=”http://www.xxx.com/home/course/course/id/’.$row[‘id’].’.html” target=”_blank”>’.$row[‘course_name’].'</a><BR>’;echo ‘http://www.xxx.com/home/course/course/id/’.$row[‘id’].’.html<BR>’;} mysql_close($con);?>