salut je viens de débuter avec zend et je suis entrain de lister la liste de membre
dans le controlleur/membrecontroller:

Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
 public function indexAction()
    {
		$req = new Application_Model_Membre();
		$this->view->index = $req->fetchAll(); 
 
    }
et le view/membre/index:

Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
<p> <a href="<?php echo $this->url(array('controller' => 'membre', 'action' => 'ajouter'));?> "> ajouter nouveau membre</a></p> 
 
 
<table>
<tr>
	<th>nom</th>
    <th>prenom</th>
    <th>specialite</th>
    <th>C.I.N</th>
    <th>&nbsp;&nbsp;</th>
</tr><!-- lister les membres -->
<?php foreach ($this->req as $membre) : ?>
<tr>
	<td> <?php  echo $membre->nom ;?></td>
    <td>  <?php echo $membre->prenom ;?> </td>
    <td>  <?php echo $membre->spec;?> </td>
    <td>  <?php echo $membre->cin; ?> </td>
       <td> <a href="<?php  echo $this->url(array('controller' => 'membre','action'=>'modifier','id'=>$membre->cin));?>">modifier</a> <!--modifier membre-->    				&nbsp;&nbsp;
    		<a href="<?php echo $this->url(array('controller'=>'membre','action'=>'supprimer','id'=>$membre->cin));?>">supprimer</a></td> <!--supprimer membre -->
</tr>
<?php endforeach ;?>
</table>
il m'affiche seulement:
ajouter nouveau membre

nom prenom specialte cin

NB la connexion à la BD est bien regler


aider moi SVP!!