Next, you create the article detail page: article.php. This page displays the title, the short description, the body, and the publishing date for an article. You build the page in a similar manner to topic.php:
Create a filtered advanced recordset called rsArticle that must:
id_art
field, which must be equal to the value of the URL parameter, id_art
o
make an inner join
between the tables blg_topic_top
and blg_article_art
.
(INNER JOIN blg_topic_top ON idtop_art=id_top)
Figure 20 shows Advanced view of the rsArticle recordset:
(+) View larger
Display the dynamic data from the recordset in your page. This time, you won't need a dynamic table for that, since there is only one item in the recordset to display-the article ID that the URL parameter passed.
Figure 22 shows how the article.php page should look in Design view.
(+) View larger
You can see how easy it is to display dynamic information extracted from the database just by using drag and drop actions.
Save the file and put it to the server. Browse to the index.php page, click a topic to go to the topic page, and click an article title to display the article page with the detailed information for that article.
Now you have all the pages that display postings from the blog:
There is one issue left: how do you post an article? You will learn to do that in the next section.
|