Article publié
--------------
L'article "2. One template, several articles" a été validé par George
Kandalaft.
** 2. One template, several articles **
par Paul Knight le vendredi 31 octobre 2003
The preceding lesson enabled us to extract the content of article no 1
from the database and build a web page from it. Let us generalize...
Our template is quite useless if it can only display article no 1. Lets
enhance it to display any article:
For that we will call our web page with a parameter, id_article=2. Type
the following into your web browser
http://yoursite.net/tutorial.php3?id_article=2.
And there it appears... still article 1. Let us modify the line in the
tutorial.html template that defines the "article loop":
<BOUCLE_article(ARTICLES)id_article>
(As you can see, you simply replace id_article=1 with (...)