Précédent   Forum des professionnels en informatique > PHP > Bibliothèques et frameworks > Templates > Smarty
Smarty Forum d'entraide sur le moteur de templates Smarty. Avant de poster -> FAQ Smarty et Cours Smarty
Partagez cette discussion sur d'autres réseaux sociaux : Viadeo Twitter Google Facebook Digg Delicious MySpace Yahoo
Réponse Proposer ce sujet en actualité
 
Outils de la discussion
Publicité
'
Vieux 06/01/2012, 16h15   #1
Invité de passage
 
Inscription : mars 2006
Messages : 10
Détails du profil
Informations forums :
Inscription : mars 2006
Messages : 10
Points : 1
Points : 1
Par défaut Formater une variable

Bonjour,

je rencontre un problème pour reformater une variable déjà formater dans un tableau html. je n'ai pas accès au php. J,aimerais reprendre la partie en bleu.

Je n'arrive pas à sortir les données de cette variable avec {foreach} ou {section}.

Savez-vous comment je pourrais y arriver?

La variable smarty $data contient déjà ce tableau comme cette exemple:

Code :
<table cellpadding="3" cellspacing="2" class="listing_results"> <tr class="results_column_header"> <td class="browse_table_column_image">Image</td> <td class="title"> <a class="title_column_header" href="index.php?a=5&amp;b=314&amp;c=5"> Titre <img src="geo_templates/hobby_fr/external/images/sort_arrow_down.gif" alt="Descending" height="10" width="7" /> </a> <br />Description </td> <td class="browse_table_column_header_price"> <a class="price_column_header" href="index.php?a=5&amp;b=314&amp;c=1"> Prix <img src="geo_templates/hobby_fr/external/images/sort_arrow_down.gif" alt="Descending" height="10" width="7" /> </a> </td> <!-- <td class="browse_table_column_header_1"> <a class="optional_field_header_1" href="index.php?a=5&amp;b=314&amp;c=15"> Prix par jour &nbsp <img src="geo_templates/hobby_fr/external/images/sort_arrow_down.gif" alt="" /> </a> </td> --> <td class="browse_table_column_header_city"> <a class="city_column_header" href="index.php?a=5&amp;b=314&amp;c=35"> Ville <img src="geo_templates/hobby_fr/external/images/sort_arrow_down.gif" alt="Descending" height="10" width="7" /> </a> </td> <td class="browse_table_column_header_entry_date"> <a class="price_column_header" href="index.php?a=5&amp;b=314&amp;c=68"> Ajouter le </a> </td> <td> Boutique </td> </tr> <tr class="browsing_result_table_body_even"> <td class="center"> <a href="get_image.php?id=3" class="lightUpLink" onclick="return false;"> <img src="user_images/1436706.jpg" width="100" height="76" alt="Le Titanic" /> </a> </td> <td style="width: 100%;"> <a href="index.php?a=2&amp;b=2" > Le Titanic </a> <img src="geo_templates/" alt="" /> <p class="listing_results_description">C'est une réplique du navire le Titanic avec tous les livres (fascicules) des plans et de l'histoire de ce fabuleux navire. Le navire est construit en bois et conserver de la poussières. Plus de 2 ans d'ouvrage à temps</p> </td> <td class="center nowrap price"> $2,500.00 CAD </td> <!-- <td class="center"> - </td> --> <td class="center"> - </td> <td class="center nowrap"> 12.12.2011 18:09 </td> <td class="center nowrap"> <div class='center'><a href="index.php?a=ap&amp;addon=storefront&amp;page=home&amp;store=50"><img alt="Classified" src="geo_templates/hobby_fr/external/images/icon_storefront.png" /></a></div> </td> </tr> </table>
Merci à l'avance
heldev est déconnecté   Envoyer un message privé Réponse avec citation 00
Réponse Proposer ce sujet en actualité
Outils de la discussion



Fuseau horaire GMT +2. Il est actuellement 04h24.


 
 
 
 
Partenaires

Hébergement Web