Smarty Forum Index Smarty
WARNING: All discussion is moving to https://reddit.com/r/smarty, please go there! This forum will be closing soon.

[résolu]{math equation} et {assign}

 
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    Smarty Forum Index -> Language: French
View previous topic :: View next topic  
Author Message
boup
Smarty Rookie


Joined: 25 Aug 2010
Posts: 5

PostPosted: Wed Sep 08, 2010 12:36 pm    Post subject: [résolu]{math equation} et {assign} Reply with quote

Bonjour,

Je souhaiterai savoir si il existe un moyen, quelconque, de mettre le résultat obtenu par {math equation='x-y' x=7 y=$smarty.foreach.count.iteration%7} dans {assign var='compteur' value='?'} ?

Pour obtenir un résultat comme ci-dessous. Cela ne fonctionne pas évidement:

{assign var='compteur' value="math equation='x-y' x=7 y=$smarty.foreach.count.iteration%7"}

Si vous avez, une idée sur la question je suis preneur Very Happy
Merci

boup


Last edited by boup on Mon Oct 04, 2010 1:45 pm; edited 1 time in total
Back to top
View user's profile Send private message
Gowser
Smarty Pro


Joined: 19 Feb 2008
Posts: 104
Location: Nantes (France)

PostPosted: Mon Oct 04, 2010 9:50 am    Post subject: Reply with quote

Bonjour,

Simplement faire un

Code:

{math assign="compteur" equation='x-y' x=7 y=$smarty.foreach.count.iteration%7}
Back to top
View user's profile Send private message Send e-mail
boup
Smarty Rookie


Joined: 25 Aug 2010
Posts: 5

PostPosted: Mon Oct 04, 2010 1:45 pm    Post subject: Reply with quote

Merci beaucoup =)
Back to top
View user's profile Send private message
Display posts from previous:   
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    Smarty Forum Index -> Language: French All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group
Protected by Anti-Spam ACP