Home  >  Article  >  Backend Development  >  基于mysql的论坛(4)_php基础

基于mysql的论坛(4)_php基础

WBOY
WBOYOriginal
2016-05-17 09:45:48644browse

## index.php


论坛



  
  
  

<br><br>

## left.php
$fp=fopen("file/counter.txt","r");
$counter=fgets($fp,8);
fclose($fp);
$counter=$counter+1;
$fp=fopen("file/counter.txt","w");
fputs($fp,$counter);
fclose($fp);
require("config.inc.php");
$sql="select * from boardinfo";
$sql_result=mysql_query($sql);
$sql_row=mysql_fetch_array($sql_result);
?>


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