It's like an effect of SF. We click on a heading in the Posts list page to enter the topic inside the topic after the submission of the post reply and then click the Browser Back button and then back to the Post list page, but I do this effect has a bug is that if you do not submit a reply point can be returned to the Post list page After submitting a reply, you need to click the two Return button to return to the Post list page if you submit two replies in this post, you need to click the three Return button to return to the Post list page.
This is the topic page of the post tieba3.php
; <title></title>
Prepare ("Select Id,title,content from topic where id=?"); $stmt->execute (Array ($title)); $res = $stmt->fetchall (PDO::FETCH_ASSOC); foreach ($res as $v) {echo '. $v [' content ']. '; }?>
Prepare ("Select id,reid,content from reply where reid=?"); $stmt->execute (Array ($id 2)); $res 1= $stmt->fetchall (PDO::FETCH_ASSOC); foreach ($res 1 as $v 2) {echo $v 2[' content ']; }?>
tieba4.php
prepare("insert into reply(reid,name,content)values(:reid,:name,:content)"); $stnt->execute($_POST);header("location:http://localhost/tieba3.php?id=".$_POST['reid']);}?>
Reply content:
It's like an effect of SF. We click on a heading in the Posts list page to enter the topic inside the topic after the submission of the post reply and then click the Browser Back button and then back to the Post list page, but I do this effect has a bug is that if you do not submit a reply point can be returned to the Post list page After submitting a reply, you need to click the two Return button to return to the Post list page if you submit two replies in this post, you need to click the three Return button to return to the Post list page.
This is the topic page of the post tieba3.php
; <title></title>
Prepare ("Select Id,title,content from topic where id=?"); $stmt->execute (Array ($title)); $res = $stmt->fetchall (PDO::FETCH_ASSOC); foreach ($res as $v) {echo '. $v [' content ']. '; }?>
Prepare ("Select id,reid,content from reply where reid=?"); $stmt->execute (Array ($id 2)); $res 1= $stmt->fetchall (PDO::FETCH_ASSOC); foreach ($res 1 as $v 2) {echo $v 2[' content ']; }?>
tieba4.php
prepare("insert into reply(reid,name,content)values(:reid,:name,:content)"); $stnt->execute($_POST);header("location:http://localhost/tieba3.php?id=".$_POST['reid']);}?>